
Research
Two Malicious Rust Crates Impersonate Popular Logger to Steal Wallet Keys
Socket uncovers malicious Rust crates impersonating fast_log to steal Solana and Ethereum wallet keys from source code.
@kaliber/elasticsearch
Advanced tools
compiles .mapping.js to elasticsearch mappings and helps you query elasticsearch
This package contains a custom render and a set of functions that can be used with @kaliber/build to build mappings. It also holds a set of util functions to query elasticsearch into a more readable format.
yarn add @kaliber/elasticsearch
Note This library is precompiled using kaliberjs/pack. Compiling it a second time will cause this library to stop working. This means for example that you should not add it to the
compileWithBabel
array of @kaliber/build.
We like to write clean code. So whe made a set of util functions that help us create more readable mappings and write simple queries to send to the elasticsearch api.
The renderer is used for an internal plugin. So this is probably not that interesting for everybody. But the rest of the project can be used without it.
You can find more examples in the /examples
folder.
*.mapping.js
import { text, keyword, object } from '@kaliber/elasticsearch/mapping'
export default {
mappings: {
dynamic: 'strict',
properties: {
id: keyword(),
title: text(),
taxonomy: object({
title: text(),
slug: keyword(),
}),
}
}
}
example.js
import { filter, matchAll, term, search } from '@kaliber/elasticsearch/query'
const searchQuery = 'Waldo'
const taxonomy = 'books'
const query = and(
searchQuery
? search(['title'], searchQuery),
: matchAll(),
filter(
taxonomy && term('taxonomy.slug', taxonomy)
)
)
To configure @kaliber/build to use the custom renderer in this package, you have to update the config/default.js file:
kaliber: {
templateRenderers: {
mapping: '@kaliber/elasticsearch/mapping-to-php-renderer'
}
}
Because this library is used in both the node runtime and webpack environment, the library is precompiled using kaliberjs/pack. When releasing a new version, do not forget to execute yarn build
before running yarn publish
. This should be done because the yarn publish command uses your local files to upload to the npm registry.
This library is intended for internal use, we provide no support, use at your own risk.
FAQs
compiles .mapping.js to elasticsearch mappings and helps you query elasticsearch
We found that @kaliber/elasticsearch demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 8 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Socket uncovers malicious Rust crates impersonating fast_log to steal Solana and Ethereum wallet keys from source code.
Research
A malicious package uses a QR code as steganography in an innovative technique.
Research
/Security News
Socket identified 80 fake candidates targeting engineering roles, including suspected North Korean operators, exposing the new reality of hiring as a security function.