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.
h2. Work In Progress
This is currently a work in progress. The notes below are mostly for myself, and are what I am aiming for the library to do.
Mostly, this is a test repository for my other two repositories: "node-infuse":http://github.com/jhamlet/node-infuse and "sake-node":http://github.com/jhamlet/sake-node.
Eventually this will work; as a nodejs module or a browser loaded file...
h2. Expressions
{background:#ccc}. |. Expression |. Function |_. Explanation | | XdY | Standard | Roll X dice with Y faces and sum the results. | {background:#ccc}. | XdYlN | Low | Roll X dice with Y faces, keep N lowest | | XdYhN | High | Roll X dice with Y faces, keep N highest | {background:#ccc}. | XdYdN | Drop | Roll X dice with Y faces, drop N lowest, and sum the results. | | XdYkN | Keep | Roll X dice with Y faces, keep N highest, and sum the results. | {background:#ccc}. | XdYrN | Reroll | Roll X dice with Y faces, re-roll any dice lower than N, and sum the results | | XdYe | Explode | Roll X dice with Y faces, roll an additional dice with Y faces for each result that rolls Y. Sum the results. | {background:#ccc}. | XdYsN | Success | Roll X dice with Y faces, and count any results equal to or greater than N as a success. | | XdYo | Open | Rol X dice with Y faces, explode any dice that roll Y. Return highest result. | {background:#ccc}. | XdYgN | Glitch | Roll X dice with Y faces. Count the number of dice that came up equal to or lower than N. If the count is equal, or lower than, X display Glitch. If the count is more than half of X display Critical Glitch. |
Note: the expression letters are case in-sensitive. i.e: 3d6 is the same as 3D6, as is 5d6d2 equivalent to 5d6D2, etc...
You can combine the expressions to get different behaviors:
{background:#ccc}. |. Expression |. Function |_. Explanation | | XdYesN | Exploding Success | Combines Explode and Success. Additional dice from exploding can generate additional successes. |
h3. Examples
{background:#ccc}. |. Expression |. Result | | 3d6 | [4, 5, 3] = 12 | {background:#ccc}. | 5d6l2 | [4, 5, 3, 2, 1] = 2, 1 | | 5d6h2 | [3, 2, 4, 4, 1] = 3, 4 | {background:#ccc}. | 5d6d2 | [4, 5, 2, 3, 1] = 12 | | 5d6k3 | [1, 3, 4, 5, 5] = 14 | {background:#ccc}. | 3d10r1 | [7, 8, 4] = 19 | | 5d6e | [1, 3, 6, 2, 4, 3] = 19 | {background:#ccc}. | 5d6s5 | [1, 4, 5, 6, 3] = 2 | | 6d6es5 | [2, 3, 5, 6, 6, 4, 3, 5] = 4 | {background:#ccc}. | 3d10o | [7, 10, 6] = 10 | | [1d12 2d8 3d6]k2 | [7, 3, 1, 3, 5, 1] = 12 | {background:#ccc}. | [3d6 2d8]h2 | [3, 1, 5, 5, 7] = 5, 7 |
FAQs
Roll some dice.
The npm package dice-js receives a total of 0 weekly downloads. As such, dice-js popularity was classified as not popular.
We found that dice-js demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer 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
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.