Research
Security News
Malicious npm Package Targets Solana Developers and Hijacks Funds
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
github.com/xssed/owlcache
English | 中文简介
🦉owlcache is a lightweight, high-performance, non-centralized, distributed Key/Value in-memory Cache written in Go.It is an independent process and high-performance data middleware, and provides a variety of data get and import methods.You can query a node's key to get all the content with the same key in the node cluster(One Key to Many Values). After operating the Key of a node, the data will be automatically synchronized to all node clusters.
🦌 deerfs:Using it, you can build a simple decentralized file system. Project address: deerfs
Compilation environment requirements
Source download
go get -u github.com/xssed/owlcache
git clone https://github.com/xssed/owlcache.git
Command to download the source code.go build
Linux
./owlcache
Windows (DOS)
owlcache
Parameter help
owlcache -help
Welcome to use owlcache. Version:XXX
If you have any questions,Please contact us: xsser@xsser.cc
Project Home:https://github.com/xssed/owlcache
_ _
_____ _| | ___ __ _ ___| |__ ___
/ _ \ \ /\ / / |/ __/ _' |/ __| '_ \ / _ \
| (_) \ V V /| | (_| (_| | (__| | | | __/
\___/ \_/\_/ |_|\___\__,_|\___|_| |_|\___|
Usage of owlcache:
-config string
owlcache config file path.[demo:/var/home/owl.conf] (default "owlcache.conf")
-host string
binding local host ip address. (default "0.0.0.0")
-log string
owlcache log file path.[demo:/var/log/] (default "./log_file/")
-pass string
owlcache Http connection password. (default "")
Example with configuration parameter run
owlcache -config /var/home/owl.conf -host 127.0.0.1 -log /var/log/ -pass 1245!df2A
get <key>\n
get hello\n
Request parameter | Parameter value |
---|---|
cmd | get |
key | key name |
http://127.0.0.1:7721/data/?cmd=get&key=hello
get <key>
get hello
Response result example:
world
If it is an HTTP request, there will be Key details in the response message.
Key: hello
Keycreatetime: 2021-11-26 18:12:45.1932019 +0800 CST
Responsehost: 127.0.0.1:7721
get <key> info\n
get hello info\n
owlcache version >= 0.4.2, http no longer supports 'info'
http://127.0.0.1:7721/data/?cmd=get&key=hello&valuedata=info
get <key> info <Custom return string (not necessary, such as UUID)>
get hello info
or
get hello info 5c9eff00-3bed-4113-a095-2f3c771683d9
Response result example:
{
"Cmd": "get",
"Status": 200,
"Results": "SUCCESS",
"Key": "hello",
"Data": "d29ybGQ=",
"ResponseHost": "127.0.0.1:7721",
"KeyCreateTime": "2021-11-09T14:12:36.8431596+08:00"
}
Attention to the HTTP Status code returned by the HTTP Request. please refer to the "Protocol" chapter.
Request parameter | Parameter value |
---|---|
cmd | get |
key | key name |
http://127.0.0.1:7721/group_data/?cmd=get&key=hello
Response result example:
world
The result obtained is the latest value of the update time in the cluster query.
http://127.0.0.1:7721/group_data/?cmd=get&key=hello&valuedata=info
Response result example:
[
{
"Address": "127.0.0.1:7721",
"Data": "d29ybGQ=",
"Key": "hello",
"KeyCreateTime": "2021-11-26T18:12:45.1932019+08:00",
"Status": 200
},
{
"Address": "127.0.0.1:7723",
"Data": "d29ybGQ=",
"Key": "hello",
"KeyCreateTime": "2021-11-12T11:34:53.0952566+08:00",
"Status": 200
},
{
"Address": "127.0.0.1:7725",
"Data": "d29ybGQ=",
"Key": "hello",
"KeyCreateTime": "2021-11-11T11:34:53.0952522+08:00",
"Status": 200
}
]
The result is the information about which node in the cluster owns this Key.
The author believes that the master-slave mode will occupy a lot of server resources and cause excessive data redundancy(Exception: One Key maps multiple values). It is recommended that important keys can be written to more than two nodes at the same time when setting, so that the access to keys is almost unaffected in the relative case. If all nodes in the cluster are down, it is really impossible to access the key.
There are three clustering modes of owlcache, namely "Http" (short link), "Websocket" (long link) and "Gossip" (data is eventually consistent).
★If your business volume is small, you can choose the "Http" (short link) cluster method.
★If your business volume is large, you can choose the "Websocket" (long link) cluster method.
★The "Gossip" (data eventually consistent) clustering method does not conflict with the previous two clustering methods, and they can coexist. However, you need to pay attention to the configuration items and debug the complex server network environment. You can understand that the previous two methods are active clustering, and the latter is passive clustering,Used to synchronize data in the cluster.However, if you turn on "Gossip", the use case of your cluster having multiple values for one key will become meaningless.
FAQs
Unknown package
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
Security News
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
Security News
Research
Socket researchers have discovered malicious npm packages targeting crypto developers, stealing credentials and wallet data using spyware delivered through typosquats of popular cryptographic libraries.
Security News
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.