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

haraka-plugin-karma

Package Overview
Dependencies
Maintainers
3
Versions
26
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

haraka-plugin-karma - npm Package Compare versions

Comparing version 2.1.2 to 2.1.3

6

Changes.md
#### N.N.N - YYYY-MM-DD
### [2.1.3] - 2023-12-12
- ci: use shared configs
- style(es6): replace for..i with for...of
- deps(*): bump versions to latest
### [2.1.2] - 2023-12-11

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

29

index.js

@@ -172,4 +172,3 @@ 'use strict'

// do any award conditions match this result?
for (let i=0; i < pi_prop.length; i++) { // each award...
const thisAward = pi_prop[i]
for (const thisAward of pi_prop) { // each award...
// { id: '011', operator: 'equals', value: 'all_bad', award: '-2'}

@@ -227,4 +226,4 @@ const thisResArr = this.result_as_array(thisResult)

for (let j=0; j < thisResult.length; j++) {
const tr = parseFloat(thisResult[j])
for (const element of thisResult) {
const tr = parseFloat(element)
if (tr >= parseFloat(thisAward.value)) continue

@@ -240,4 +239,4 @@ if (conn.results.has('karma', 'awards', thisAward.id)) continue

for (let j=0; j < thisResult.length; j++) {
const tr = parseFloat(thisResult[j])
for (const element of thisResult) {
const tr = parseFloat(element)
if (tr <= parseFloat(thisAward.value)) continue

@@ -253,8 +252,8 @@ if (conn.results.has('karma', 'awards', thisAward.id)) continue

for (let j=0; j < thisResult.length; j++) {
for (const element of thisResult) {
if (thisAward.value === 'true') {
if (!thisResult[j]) continue
if (!element) continue
}
else {
if (thisResult[j] != thisAward.value) continue
if (element != thisAward.value) continue
}

@@ -274,4 +273,4 @@ if (!/auth/.test(thisAward.plugin)) {

for (let i=0; i < thisResult.length; i++) {
if (!re.test(thisResult[i])) continue
for (const element of thisResult) {
if (!re.test(element)) continue
if (conn.results.has('karma', 'awards', thisAward.id)) continue

@@ -286,3 +285,3 @@

for (let j=0; j < thisResult.length; j++) {
for (const element of thisResult) {
const [operator, qty] = thisAward.value.split(/\s+/) // requires node 6+

@@ -294,9 +293,9 @@

case 'equals':
if (parseInt(thisResult[j], 10) != parseInt(qty, 10)) continue
if (parseInt(element, 10) != parseInt(qty, 10)) continue
break
case 'gt':
if (parseInt(thisResult[j], 10) <= parseInt(qty, 10)) continue
if (parseInt(element, 10) <= parseInt(qty, 10)) continue
break
case 'lt':
if (parseInt(thisResult[j], 10) >= parseInt(qty, 10)) continue
if (parseInt(element, 10) >= parseInt(qty, 10)) continue
break

@@ -303,0 +302,0 @@ default:

{
"name": "haraka-plugin-karma",
"version": "2.1.2",
"version": "2.1.3",
"description": "A heuristics scoring and reputation engine for SMTP connections",

@@ -26,14 +26,14 @@ "main": "index.js",

"dependencies": {
"address-rfc2821": "*",
"haraka-constants": ">=1.0.2",
"haraka-utils": "*",
"haraka-plugin-redis": "2.0.5",
"redis": "4.6.11"
"address-rfc2821": "^2.1.1",
"haraka-constants": "^1.0.2",
"haraka-utils": "^1.0.3",
"haraka-plugin-redis": "^2.0.6",
"redis": "^4.6.11"
},
"devDependencies": {
"eslint": "8.55.0",
"eslint": "^8.55.0",
"eslint-plugin-haraka": "*",
"haraka-test-fixtures": "*",
"mocha": "10.2.0"
"mocha": "^10.2.0"
}
}

Sorry, the diff of this file is not supported yet

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