Socket
Socket
Sign inDemoInstall

saslprep

Package Overview
Dependencies
2
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    saslprep

SASLprep: Stringprep Profile for User Names and Passwords, rfc4013.


Version published
Weekly downloads
1.5M
increased by0.14%
Maintainers
1
Install size
465 kB
Created
Weekly downloads
 

Package description

What is saslprep?

The saslprep npm package is used for preparing strings for use in Simple Authentication and Security Layer (SASL) mechanisms, particularly the SCRAM (Salted Challenge Response Authentication Mechanism) family. It implements the Stringprep protocol by providing a way to process user names and passwords before sending them over the network, ensuring that they conform to the requirements for internationalized strings as specified in RFC 4013.

What are saslprep's main functionalities?

String Preparation

This feature allows for the preparation of strings (e.g., user names and passwords) for use in SASL mechanisms. The code sample demonstrates how to use saslprep to process a string containing both ASCII and non-ASCII characters, making it suitable for SASL authentication mechanisms.

"use strict";
const saslprep = require('saslprep');
console.log(saslprep('I\u00ADX'));

Other packages similar to saslprep

Changelog

Source

[1.0.3] - 2019-05-01

  • Correctly get code points >U+FFFF (#5)
  • Fix perfomance downgrades from #5.

Readme

Source

saslprep

Build Status npm node license downloads

Stringprep Profile for User Names and Passwords, rfc4013

Usage

const saslprep = require('saslprep')

saslprep('password\u00AD') // password
saslprep('password\u0007') // Error: prohibited character

API

saslprep(input: String, opts: Options): String

Normalize user name or password.

Options.allowUnassigned: bool

A special behavior for unassigned code points, see https://tools.ietf.org/html/rfc4013#section-2.5. Disabled by default.

License

MIT, 2017-2019 (c) Dmitriy Tsvettsikh

Keywords

FAQs

Last updated on 01 May 2019

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.

Install

Related posts

SocketSocket SOC 2 Logo

Product

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc