{"id":22394165,"url":"https://github.com/atlantis-software/milterjs","last_synced_at":"2025-09-11T18:31:23.282Z","repository":{"id":57297224,"uuid":"94101522","full_name":"Atlantis-Software/milterjs","owner":"Atlantis-Software","description":"sendmail milter protocol javscript client library","archived":false,"fork":false,"pushed_at":"2023-03-07T13:44:29.000Z","size":20,"stargazers_count":8,"open_issues_count":3,"forks_count":5,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-08-28T21:50:16.486Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Atlantis-Software.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2017-06-12T13:51:45.000Z","updated_at":"2023-01-02T09:50:10.000Z","dependencies_parsed_at":"2025-07-21T22:35:15.939Z","dependency_job_id":"20b3964b-dc67-4e74-accc-417bcf1efcde","html_url":"https://github.com/Atlantis-Software/milterjs","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Atlantis-Software/milterjs","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Atlantis-Software%2Fmilterjs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Atlantis-Software%2Fmilterjs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Atlantis-Software%2Fmilterjs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Atlantis-Software%2Fmilterjs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Atlantis-Software","download_url":"https://codeload.github.com/Atlantis-Software/milterjs/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Atlantis-Software%2Fmilterjs/sbom","scorecard":{"id":17333,"data":{"date":"2025-08-11","repo":{"name":"github.com/Atlantis-Software/milterjs","commit":"aa5832fd0d781d21c4baa753215323b2befe9915"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":2.5,"checks":[{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Code-Review","score":1,"reason":"Found 2/16 approved changesets -- score normalized to 1","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"License","score":0,"reason":"license file not detected","details":["Warn: project does not have a license file"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: containerImage not pinned by hash: test/fixtures/Dockerfile:1: pin your Docker image by updating debian to debian@sha256:b6507e340c43553136f5078284c8c68d86ec8262b1724dde73c325e8d3dcdeba","Info:   0 out of   1 containerImage dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 5 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}}]},"last_synced_at":"2025-08-14T16:04:58.299Z","repository_id":57297224,"created_at":"2025-08-14T16:04:58.299Z","updated_at":"2025-08-14T16:04:58.299Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":274684486,"owners_count":25330799,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-09-11T02:00:13.660Z","response_time":74,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-12-05T05:09:13.727Z","updated_at":"2025-09-11T18:31:23.203Z","avatar_url":"https://github.com/Atlantis-Software.png","language":"JavaScript","readme":"# milterjs\n\n[![npm version](https://badge.fury.io/js/milterjs.svg)](https://www.npmjs.com/milterjs)\n[![Build Status](https://travis-ci.org/Atlantis-Software/milterjs.svg?branch=master)](https://travis-ci.org/Atlantis-Software/milterjs)\n[![Coverage Status](https://coveralls.io/repos/github/Atlantis-Software/milterjs/badge.svg?branch=master)](https://coveralls.io/github/Atlantis-Software/milterjs?branch=master)\n[![NSP Status](https://nodesecurity.io/orgs/atlantis/projects/513e7252-f706-4b97-992c-3328b4559391/badge)](https://nodesecurity.io/orgs/atlantis/projects/513e7252-f706-4b97-992c-3328b4559391)\n[![Dependencies Status](https://david-dm.org/Atlantis-Software/milterjs.svg)](https://david-dm.org/Atlantis-Software/milterjs)\n\nsendmail milter protocol javscript client library\n\nhelp you write a sendmail/postfix milter in javascript\n\n## EXEMPLE\n```javascript\nvar milterjs = require('milterjs');\n\nmilterjs.on('helo', function(ctx) {\n  console.log('helo event !');\n  ctx.continue();\n});\n\nmilterjs.listen(9568, '127.0.0.1');\n```\n\n## METHODS\n### on(eventName, listener)\nCall a function on a specified event.\n\n* eventName: The name of the event.\n* listener: The callback function called on event previously specified.\n### listen(port, [host])\nStart listening for sendmail/postfix connections on the given port and host.\n\n* port: number of port\n* host: ipv4 or ipv6 string address, default is `0.0.0.0`\n\n## EVENTS\n| EventName | Parameters | accept/reject Action | Description |\n| --------- | ---------- | -------------------- | ----------- |\n| abort | ctx | no | cancel current message and get ready to process a new one. |\n| body | ctx, BodyChunk | yes | Body chunk (up to MILTER_CHUNK_SIZE (65535) bytes.)\n| connect | ctx, hostname, connection_type, address, port | yes | SMTP connection information. |\n| eom | ctx | yes | the end of the body. |\n| helo | ctx, heloName | yes | HELO/EHLO name |\n| envfrom | ctx, sender | yes | array[0] sender, with \u003c\u003e qualification. array[1] and beyond are ESMTP arguments, if any. |\n| header | ctx, header | no | array[0] header, array[1] value |\n| eoh | ctx | yes | the end of headers. |\n| envrcpt | ctx, recipient | yes | array[0] recipient, with \u003c\u003e qualification. array[1] and beyond are ESMTP arguments, if any. |\n| data | ctx | yes | end of data. |\n| close | ctx | no | close milter connection. |\n| unknown | ctx, command | no | tell the milter that an unknown smtp command has been received. |\n| error | error | no | an error has occur. |\n\n## CTX\nctx is the Milter context object.\n### ATTRIBUTES\n* `version`: the milter protocol version of MTA.\n* `macros`: object containing all macros.\n* `uniqueID`: unique identifier for milter connection.\n### METHODS\n#### `accept()`: Accept message completely (accept/reject action)\nThis will skip to the end of the milter sequence, and recycle back to\nthe state before SMFIC_MAIL.  The MTA may, instead, close the connection\nat that point.\n#### `continue()`: Accept and keep processing (accept/reject action)\nIf issued at the end of the milter conversation, functions the same as `accept()`.\n#### `discard()`: Set discard flag for entire message (accept/reject action)\nNote that message processing MAY continue afterwards, but the mail will\nnot be delivered even if accepted with `accept()`.\n#### `reject()`: Reject command/recipient with a 5xx (accept/reject action)\n#### `tempfail()`: Reject command/recipient with a 4xx (accept/reject action)\n#### `replycode(code, message)`: Send specific Nxx reply message (accept/reject action)\n  * `code`: string with length of 3 characters. [see](https://tools.ietf.org/html/rfc5321#page-48)\n  * `message`: string\n#### `progress()`: Progress (asynchronous action)\nThis is an asynchronous response which is sent to the MTA to reset the\ncommunications timer during long operations.  The MTA should consume\nas many of these responses as are sent, waiting for the real response\nfor the issued command.\n#### `quarantine(reason)`: Quarantine message (modification action)\n  * `reason`: string\nThis quarantines the message into a holding pool defined by the MTA.\n#### `addheader(header, value)`: Add header (modification action)\n  * `header`: string\n  * `value`: string\n#### `addrcpt(rcpt)`: Add recipient (modification action)\n  * `rcpt`: string email of new recipient\n#### `chgheader(header, num, value)`: Change a header (modification action)\n  * `header`: string\n  * `num`: number (integer value)\n  * `value`: string\nChange the `num`'th header of name `header` to the value `value`\n#### `delrcpt(rcpt)`: Remove address `rcpt` from the list of recipients for this mail (modification action)\n  * `rcpt`: string\n#### `replacebody(chunk)`: Replace the message body (modification action)\n  * `chunk`: string\nReplace the message body with the `chunk`. This method may be called multiple times, each call appending to the replacement buffer.\nEnd-of-line should be represented by CR-LF (\"\\r\\n\").\n#### `setsender(sender)`: Replace the envelope sender address (modification action)\nThis method provides an implementation to access the mlfi_setsender method added to the libmilter library as part of the [mlfi-setsender project](http://www.sourceforge.net/projects/mlfi-setsender)\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fatlantis-software%2Fmilterjs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fatlantis-software%2Fmilterjs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fatlantis-software%2Fmilterjs/lists"}