
Research
/Security News
Weaponizing Discord for Command and Control Across npm, PyPI, and RubyGems.org
Socket researchers uncover how threat actors weaponize Discord across the npm, PyPI, and RubyGems ecosystems to exfiltrate sensitive data.
@0to10/secure-profiles
Advanced tools
Typescript library for working with encrypted profiles
This repository provides structures to work with encrypted profiles.
Get started quickly by following the instructions below.
Use NPM to install this library into your project:
npm install --save @0to10/secure-profiles
All configuration must be done before using any other structures provided by this package, or risk ending with an unstable state and/or corrupted data.
Configure the available cryptography parameters. Example below:
import {CryptoVersions} from '@0to10/secure-profiles';
CryptoVersions.configure([
{
number: 1,
algorithm: {
name: 'AES-CTR',
iv_length: 64,
},
},
]);
Below is an example of how to create a new profile, using the ProfileFactory
class
and adding some data to it.
The Profile
instance created by the ProfileFactory
is a roaming profile, meaning
that it is unencrypted and mutable. A roaming profile may only be used locally on an
authorised device, and must never leave that device in its unencrypted form.
'use strict';
import {ProfileFactory, RoamingProfile} from '@0to10/secure-profiles';
const factory: ProfileFactory = new ProfileFactory();
const profile: RoamingProfile = factory.create();
profile.data.set('sensitive_information', 'I am using a Qwerty keyboard.');
Any required authentication information should be stored outside the profile, as this information is not accessible until the profile is decrypted.
Before transporting the profile, it must be encrypted. Classes that transport or store a profile instance must refuse storing any unsealed profiles.
'use strict';
import {EncryptedProfile, Profile, ProfileFactory} from '@0to10/secure-profiles';
const factory: ProfileFactory = new ProfileFactory();
const profile = factory.create();
// Modify the profile
const encryptedProfile: EncryptedProfile = profile.encrypt(
profile.deriveMasterKey('MyS3cretPassw0rd!')
);
// Store the profile
FAQs
Typescript library for working with encrypted profiles
We found that @0to10/secure-profiles 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
Socket researchers uncover how threat actors weaponize Discord across the npm, PyPI, and RubyGems ecosystems to exfiltrate sensitive data.
Security News
Socket now integrates with Bun 1.3’s Security Scanner API to block risky packages at install time and enforce your organization’s policies in local dev and CI.
Research
The Socket Threat Research Team is tracking weekly intrusions into the npm registry that follow a repeatable adversarial playbook used by North Korean state-sponsored actors.