Socket
Socket
Sign inDemoInstall

iconv-lite

Package Overview
Dependencies
0
Maintainers
1
Versions
51
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.4.3 to 0.4.4

encodings/utf7.js

5

Changelog.md
# 0.4.4 / 2014-07-16
* added encodings UTF-7 (RFC2152) and UTF-7-IMAP (RFC3501 Section 5.1.3)
* fixed streaming base64 encoding
# 0.4.3 / 2014-06-14

@@ -3,0 +8,0 @@

1

encodings/index.js

@@ -7,2 +7,3 @@

require("./utf16"),
require("./utf7"),
require("./sbcs-codec"),

@@ -9,0 +10,0 @@ require("./sbcs-data"),

@@ -23,3 +23,3 @@

return {
encoder: encoderInternal,
encoder: options.enc == "base64" ? encoderBase64 : encoderInternal,
decoder: decoderInternal,

@@ -43,2 +43,3 @@

// Encoder is mostly trivial

@@ -58,1 +59,26 @@ function encoderInternal() {

// Except base64 encoder, which must keep its state.
function encoderBase64() {
return {
write: encodeBase64Write,
end: encodeBase64End,
prevStr: '',
};
}
function encodeBase64Write(str) {
str = this.prevStr + str;
var completeQuads = str.length - (str.length % 4);
this.prevStr = str.slice(completeQuads);
str = str.slice(0, completeQuads);
return new Buffer(str, "base64");
}
function encodeBase64End() {
return new Buffer(this.prevStr, "base64");
}

2

package.json
{
"name": "iconv-lite",
"description": "Convert character encodings in pure javascript.",
"version": "0.4.3",
"version": "0.4.4",
"license": "MIT",

@@ -6,0 +6,0 @@

@@ -93,4 +93,4 @@ ## Pure JS character encoding conversion

* All node.js native encodings: utf8, ucs2 / utf16, ascii, binary, base64, hex.
* Additional unicode encodings: utf16, utf16-be.
* All node.js native encodings: utf8, ucs2 / utf16-le, ascii, binary, base64, hex.
* Additional unicode encodings: utf16, utf16-be, utf-7, utf-7-imap.
* All widespread singlebyte encodings: Windows 125x family, ISO-8859 family,

@@ -97,0 +97,0 @@ IBM/DOS codepages, Macintosh family, KOI8 family, all others supported by iconv library.

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