New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

advanced-random

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

advanced-random - npm Package Compare versions

Comparing version 1.0.0 to 1.0.1

2

package.json
{
"name": "advanced-random",
"version": "1.0.0",
"version": "1.0.1",
"description": "Module for getting random values from random.org",

@@ -5,0 +5,0 @@ "main": "advanced-random.js",

@@ -18,3 +18,2 @@ Technically it is just wrapper for random.org API service.

### Integer Generator
The Integer Generator will generate truly random integers in configurable intervals. It is pretty easy to write a client to access the integer generator. The integer generator accepts only HTTP GET requests, so parameters are passed via encoding in the URL.
```javascript

@@ -30,10 +29,4 @@ //...

```
num - [1,1e4] - The number of integers requested.
min - [-1e9,1e9] - The smallest value allowed for each integer.
max - [-1e9,1e9] - The largest value allowed for each integer.
base - 2 | 8 | 10 | 16 - The base that will be used to print the numbers, i.e., binary, octal, decimal or hexadecimal.
rnd - new | id.identifier | date.iso-date - Determines the randomization to use to generate the numbers. If new is specified, then a new randomization will created from the truly random bitstream at RANDOM.ORG. This is probably what you want in most cases. If id.identifier is specified, the identifier is used to determine the randomization in a deterministic fashion from a large pool of pregenerated random bits. Because the numbers are produced in a deterministic fashion, specifying an id basically uses RANDOM.ORG as a pseudo-random number generator. The third (date.iso-date) form is similar to the second; it allows the randomization to be based on one of the daily pregenerated files. This form must refer to one of the dates for which files exist, so it must be the current day (according to UTC) or a day in the past. The date must be in ISO 8601 format (i.e., YYYY-MM-DD) or one of the two shorthand strings 'today' or 'yesterday'.
### Sequence Generator
The Sequence Generator will randomize a given interval of integers, i.e., arrange them in random order. It is pretty easy to write a client to access the sequence generator. The sequence generator accepts only HTTP GET requests, so parameters are passed via encoding in the URL.
```javascript

@@ -47,8 +40,4 @@ //...

```
min - [-1e9,1e9] - The lower bound of the interval (inclusive).
max - [-1e9,1e9] - The upper bound of the interval (inclusive).
rnd - read above.
### String Generator
The String Generator will generate truly random strings of various length and character compositions. It is pretty easy to write a client to access the string generator. The string generator accepts only HTTP GET requests, so parameters are passed via encoding in the URL.
```javascript

@@ -65,12 +54,4 @@ random.stringGenerator({

```
num - [1,1e4] - The number of strings requested.
len - [1,20] - The length of the strings. All the strings produced will have the same length.
digits - on | off - Determines whether digits (0-9) are allowed to occur in the strings.
upperalpha - on | off - Determines whether uppercase alphabetic characters (A-Z) are allowed to occur in the strings.
loweralpha - on | off - Determines lowercase alphabetic characters (a-z) are allowed to occur in the strings.
unique - on | off - Determines whether the strings picked should be unique (as a series of raffle tickets drawn from a hat) or not (as a series of die rolls). If unique is set to on, then there is the additional constraint that the number of strings requested (num) must be less than or equal to the number of strings that exist with the selected length and characters.
rnd - read above.
### Quota Checker
The Quota Checker allows you to examine your quota at any point in time. The quota system works on the basis of IP addresses. Each IP address has a base quota of 1,000,000 bits. When your client makes a request for random numbers (or strings, etc.), the server deducts the number of bits it took to satisfy your request from the quota associated with your client's IP address.
```javascript

@@ -82,3 +63,2 @@ //...

```
ip - n.n.n.n
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc