{"id":19747118,"url":"https://github.com/flickr/incoming-message-hash","last_synced_at":"2026-03-09T15:03:56.047Z","repository":{"id":6349160,"uuid":"54654668","full_name":"flickr/incoming-message-hash","owner":"flickr","description":"Generate a one-way hash from an http.IncomingMessage","archived":false,"fork":false,"pushed_at":"2022-02-11T23:27:47.000Z","size":34,"stargazers_count":5,"open_issues_count":0,"forks_count":4,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-10-26T01:19:25.154Z","etag":null,"topics":["hash","md5","node","request"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/flickr.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-03-24T15:53:32.000Z","updated_at":"2023-06-21T12:21:41.000Z","dependencies_parsed_at":"2022-08-06T19:15:30.781Z","dependency_job_id":null,"html_url":"https://github.com/flickr/incoming-message-hash","commit_stats":null,"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"purl":"pkg:github/flickr/incoming-message-hash","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/flickr%2Fincoming-message-hash","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/flickr%2Fincoming-message-hash/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/flickr%2Fincoming-message-hash/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/flickr%2Fincoming-message-hash/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/flickr","download_url":"https://codeload.github.com/flickr/incoming-message-hash/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/flickr%2Fincoming-message-hash/sbom","scorecard":{"id":403207,"data":{"date":"2025-08-11","repo":{"name":"github.com/flickr/incoming-message-hash","commit":"109d5f65254ce54d079993c4003a10fe2bf2f62a"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3.4,"checks":[{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","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":"Code-Review","score":0,"reason":"Found 1/23 approved changesets -- score normalized to 0","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":"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":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/pull-request.yaml:1","Info: no jobLevel write permissions found"],"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":"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":"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":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/pull-request.yaml:17: update your workflow using https://app.stepsecurity.io/secureworkflow/flickr/incoming-message-hash/pull-request.yaml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/pull-request.yaml:19: update your workflow using https://app.stepsecurity.io/secureworkflow/flickr/incoming-message-hash/pull-request.yaml/main?enable=pin","Warn: npmCommand not pinned by hash: .github/workflows/pull-request.yaml:23","Info:   0 out of   2 GitHub-owned GitHubAction dependencies pinned","Info:   0 out of   1 npmCommand 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":"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":"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":"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":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: MIT License: LICENSE:0"],"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":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'main'"],"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 10 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-18T20:34:12.691Z","repository_id":6349160,"created_at":"2025-08-18T20:34:12.691Z","updated_at":"2025-08-18T20:34:12.691Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30299882,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-09T14:33:48.460Z","status":"ssl_error","status_checked_at":"2026-03-09T14:33:48.027Z","response_time":61,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["hash","md5","node","request"],"created_at":"2024-11-12T02:16:54.761Z","updated_at":"2026-03-09T15:03:56.004Z","avatar_url":"https://github.com/flickr.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# incoming-message-hash\n\nGenerate a one-way hash from an [http.IncomingMessage][]\n\n## install\n\n``` bash\n$ npm install incoming-message-hash --save\n```\n\n## example\n\nThis example demonstrates how the hashing function returns a different hash based on the IncomingMessage's method, path, query string, headers and body.\n\n``` js\nimport hash from 'incoming-message-hash'\nimport { createServer } from 'http'\n\ncreateServer((req, res) =\u003e {\n  req.pipe(hash()).pipe(res)\n}).listen(4567, () =\u003e {\n  console.log('Server is listening on port 4567');\n})\n```\n\n``` bash\n$ curl http://localhost:4567; echo\ne91caf6d7b009b5af0fb2e18cff95598\n$ curl http://localhost:4567/foo; echo\n2f24d536fd0ca7c4eb72a8d64440066f\n$ curl http://localhost:4567/foo?a=b; echo\n0bb92c398df54668d9020b835c345cb8\n$ curl http://localhost:4567/foo?a=c; echo\n02bd995c9ebccfc0332619a03ce0a688\n$ curl -H \"Host: www.flickr.com\" http://localhost:4567; echo\nce8f3e6257911a9499923d0deebe56b5\n$ curl -X POST http://localhost:4567; echo\n41ba64dca3f3070b361b302a17742973\n$ curl -X POST -d \"yay\" http://localhost:4567; echo\n64ae029a6a4add75fadb03811a13caa7\n```\n\n## usage\n\n``` js\nvar hash = require('incoming-message-hash');\n```\n\n### hash([algorithm='md5'[, encoding='hex']])\n\nReturns a new [crypto.Hash][] stream using the specified algorithm and encoding (defaults to \"md5\" and \"hex\"). You can pipe your [http.IncomingMessage][] in and get a hash back.\n\n```js\nimport hash from 'incoming-message-hash'\nimport { createServer } from 'http'\n\ncreateServer((req, res) =\u003e {\n  req.pipe(hash()).pipe(res)\n})\n```\n\n### hash.sync(req, body[, algorithm='md5'[, encoding='hex']])\n\nSynchronous version of `hash()` that accepts an [http.IncomingMessage][] and its body and returns the hash. You must buffer up the request body yourself if you wish to use this method.\n\n```js\nimport { promise } from 'incoming-message-hash'\nimport { createServer } from 'http'\n\ncreateServer(async function (req, res) {\n  let body = ''\n\n  req.on('data', chunk =\u003e body += String(chunk))\n\n  req.on('end', () =\u003e {\n    res.end(sync(req, body))\n  })\n})\n```\n\n### hash.promise(req[, algorithm='md5'[, encoding='hex]])\n\nAsynchronous version of `hash()` that accepts an [http.IncomingMessage][] and\nbuffers the body up for you.\n\n```js\nimport { promise } from 'incoming-message-hash'\nimport { createServer } from 'http'\n\ncreateServer(async (req, res) =\u003e {\n  res.end(await promise(req))\n})\n```\n\n## license\n\nThis software is free to use under the MIT license. See the [LICENSE][] file for license text and copyright information.\n\n[LICENSE]: https://github.com/flickr/incoming-message-hash/blob/master/LICENSE\n[http.IncomingMessage]: https://nodejs.org/api/http.html#http_class_http_incomingmessage\n[crypto.Hash]: https://nodejs.org/api/crypto.html#crypto_class_hash\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fflickr%2Fincoming-message-hash","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fflickr%2Fincoming-message-hash","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fflickr%2Fincoming-message-hash/lists"}