npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@neurosell/securedts

v1.0.0

Published

A lightweight dependency-free library for secured types and local storage items. Compare field values and storage data using device fingerprinting

Readme

SecuredTS

SecuredTS - Lightweight secured types and storage

SecuredTS - A lightweight pure typescript and dependency-free library for protecting local storage, class fields, and cryptography in your client-side web applications. The library also includes a simple method for collecting the user's device fingerprint to generate secure storage keys.


Get Started | Other Libraries | Telegram | Contacts


Why SecuredTS? 🔹 Lightweight Library with zero dependencies; 🔹 Powerful secured fields with AES-encryption written in Typescript; 🔹 Simple encrypted local storage; 🔹 Device fingerprint based; 🔹 Cross-platform Support;


Table of Contents


Installation

The process of installing the NS Storage library for your web applications is quite simple.

Just import from npm:

npm install @neurosell/securedts

Or from CDN:

<script src="https://cdn.jsdelivr.net/npm/@neurosell/[email protected]/browser/securedts.global.js"></script>
<script type="text/javascript">
    // Will be connected as Global
    const { NStorage } = window.SecuredTS;
</script>

Or from GitHub (for developers):

git clone https://github.com/Neurosell/SecuredTS

Use Cases

You can use SecuredTS library in case of:

  • Secure your local storage data with device fingerprint key;
  • Store Secured (Encrypted) Fields into any objects;
  • Get Device fingerprinting;
  • Work with objects and text using different AES encryption;

Secured Storage Usage

The NS Storage Library may be used instead basic local storage with encrypted by device fingerprint keys and values. Use this to protect your local storage objects.

Usage Example:

// Create a storage instance
const exampleStorage = new NStorage();

// Save Item
exampleStorage.SetItem("exampleKey", "exampleValue"); // Will be saved in storage as "95ef95887680ac20b53f":"d2f28c846b9ca50e8627ddcc890f"

// Read Item
exampleStorage.GetItem("exampleKey"); // Returns Decrypted "exampleValue"

Secured Fields

The NS Storage Library has own Secured Fields implementation for any your objects. You can store secured values to protect memory hacking (for example with CheatEngine). This field is not store un-encrypted values.

Example Class with Secured Fields:

class MyClass {
    construtor(){
        this.unencryptedField = "My Unencrypted Field";                 // Raw value can be found and changed in memory
        this.securedField = new SecuredField("My Secured Field");       // Raw value can't be found and changed in memory
    }
}

Now you can use your Secured Fields:

// Create our Object Instance
const myObj = new MyClass();

// Get RAW Value
const rawValue = myObj.securedField.Value;

// Update Value (will be stored in memory with encryption)
myObj.securedField.Value = "new value to be encrypted";

Device Fingerprint Class

The NS Storage Library has own simple Device Fingerprint Class Implementation. Use this class to collect device information, UUID and device fingerprint by one line of code.

Example Usage:

// Get Device Data, Fingerprint and UUID
const fingerprintData = NDeviceFingerprint.GetDeviceFingerprint();
console.log(fingerprintData.Data, fingerprintData.Key, fingerprintData.UUID);

Collected Information:

  • User Agent;
  • Browser Information (Name and Version);
  • OS Information (Name and Version);
  • Sceen Information (Resolution and Color Depth);
  • Mobile Detection;
  • Cookie Support Detection;
  • HTML5 Features Detection;
  • Language;
  • Timezone Data;
  • Device Memory;
  • Do Not Track Flag;
  • Browser Mime Types and Plugins List;
  • WebGL Features List;
  • Canvas Fingerprint;

Crypto Classes

The NS Storage Library has own AES-Based Crypto Classes Implementation. You can use any of these classes for your projects or NEncryptor helper class.

Example Usage (with Encryptor):

// Create Encryptor Object
const myEncryptor = new NEncryptor("My Encryption Key", { Mode: NEncryptor.Mode.CTR });

// Get Encrypted HEX
const encryptedHEX = myEncryptor.Encrypt("My Decrypted Text");

// Get Decrypted Text
const decryptedText = myEncryptor.Decrypt(encryptedHEX);

Example Usage:

// Prepare AES Encryption Key
const key = "myencryptionkey";
const hashedKey = new NCryptoMD5(key).GetHEX();
const bytes = new Array(16);
for (var i = 0; i < hashedKey.length;) {
    var hexByte = hashedKey[i++] + hashedKey[i++];
    var byte = parseInt(hexByte, 16);
    bytes[i / 2 - 1] = byte;
}

// Create Your Encryptor with converted to bytes array Encryption Key
const encryptor = new NCryptoCTR(bytes, new NCryptoCounter(1));

// Encrypt Some Text
const decryptedText = "My Decrypted Text";                      // Here your Decrypted Text
const decryptedBytes = encryptor._textToBytes(decryptedText);   // Convert to Decrypted Bytes Array
const encryptedBytes = encryptor.Encrypt(decryptedBytes);       // Encrypt your Decrypted Bytes Array
const encryptedHEX = encryptor._bytesToHex(encryptedBytes);     // Convert Encrypted Bytes Array to HEX String

// Decrypt Some Text
const encryptedBytes = encryptor._hexToBytes(encryptedHEX);     // Convert Encrypted HEX String to Encrypted Bytes Array
const decryptedBytes = encryptor.Decrypt(encryptedBytes);       // Decrypt Bytes Array
console.log(encryptor._bytesToText(decryptedBytes));            // Convert Decrypted Bytes to Text

List of Available Classes:

  • NEncryptor - Multi-Method Encryption Helper;
  • NCrypto - Base class with Utils Methods;
  • NCryptoAES - Basic AES Implementation;
  • NCryptoECB - AES in ECB Mode Implementation;
  • NCryptoCBC - AES in CBC Mode Implementation;
  • NCryptoCFB - AES in CFB Mode Implementation;
  • NCryptoOFB - AES in OFB Mode Implementation;
  • NCryptoCTR (Recommended) - AES in CTR Mode Implementation;
  • NCryptoCounter - Util class for AES Counter;
  • NCryptoMD5 - MD5 Hash Implementation;

Encryption Classes Methods:

  • Name - Returns {string} Encryption Method Name;
  • Encrypt - Returns {bytes} Encrypted UTF8 Bytes Array;
  • Decrypt - Returns {bytes} Decrypted UTF8 Bytes Array;

Get Started | Other Libraries | Telegram | Contacts