Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

ldap-filters

Package Overview
Dependencies
Maintainers
1
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ldap-filters - npm Package Compare versions

Comparing version 1.1.0 to 1.2.0

filter_test.js

5

beautify.js
var Filter = require('./index');
var input = '(&(givenName=jenny)(sn=jensen)(|(c=us)(st=ontario)))';
var fs = require('fs');
input = fs.readFileSync('filter_test.txt','utf8');
var parsed = Filter.parse(input);

@@ -9,2 +12,2 @@

console.log(parsed + '');
console.log(parsed.toString(true,null,false));
console.log(parsed.toString(true));

8

lib/filter.js

@@ -58,2 +58,3 @@ var soundex = require('soundex');

Filter.indent_char = ' ';
Filter.collapse_not = true;

@@ -160,7 +161,12 @@ /* Escape a string value */

var id_str = this._indent(indent,level,id_char);
var id_str2 = id_str;
var nl = indent? '\n': '';
if (Filter.collapse_not && (this.comp == '!'))
nl = '', id_str2 = '', indent = 0;
return [
id_str, '(', this.comp, nl, this.filters.map(function(item){
return item.toString(indent,level+1,id_char)
}).join(nl), nl, id_str, ')'
}).join(nl), nl, id_str2, ')'
].join('');

@@ -167,0 +173,0 @@ };

{
"name": "ldap-filters",
"version": "1.1.0",
"version": "1.2.0",
"description": "Library for generating, parsing, and evaluating LDAP filters",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -59,3 +59,5 @@ var should = require('chai').should();

it('respects collapse_not setting');
});
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