{"id":"MAL-2026-21031","summary":"Malicious code in coincheck-core (RubyGems)","details":"\n---\n_-= Per source details. Do not edit below this line.=-_\n\n## Source: amazon-inspector (617aadbd354d729bb60adaf23436d110757486eaf29fb5d7f1d9212b503427d5)\nThe gemspec declares ext/coincheck-core/extconf.rb as a native extension, so it executes during `gem install`, yet no native sources are shipped and the script simply writes a stub Makefile. Instead of building anything, it reads installer-owned secret material including ~/.aws/credentials, ~/.ssh private keys, ~/.gem/credentials, ~/.npmrc, ~/.kube/config,.netrc,.env files and Rails master.key/credentials, dumps the full process environment, runs host reconnaissance commands, and POSTs a compressed, base64-encoded blob to hardcoded https://webhook.site/\u003ctoken\u003e/\u003ctag\u003e collector endpoints, with a DNS out-of-band fallback to oast.fun. The same harvester is embedded in lib/coincheck-core.rb, so it also fires when the library is required, and in lib/rubygems_plugin.rb, which RubyGems loads on every `gem` command invocation. Those paths additionally query cloud instance metadata at 169.254.169.254 for AWS IAM role credentials and the GCP service-account token. A marker file under /tmp named.ccgem_\u003ctag\u003e plus an environment flag check suppress repeat transmissions.\n\n## Source: ossf-package-analysis (af76c1ae78d060df24b75545147783a499bc16d5b3f332cc5ffc228c713422a0)\nThe OpenSSF Package Analysis project identified 'coincheck-core' @ 19.4.10 (rubygems) as malicious.\n\nIt is considered malicious because:\n\n- The package communicates with a domain associated with malicious activity.\n\n- The package executes one or more commands associated with malicious behavior.\n","modified":"2026-12-03T06:30:04.023596461Z","published":"2026-12-03T05:51:10Z","database_specific":{"malicious-packages-origins":[{"id":"IN-MAL-2026-023157","import_time":"2026-12-03T06:26:16.200320474Z","modified_time":"2026-12-03T05:54:19Z","sha256":"617aadbd354d729bb60adaf23436d110757486eaf29fb5d7f1d9212b503427d5","source":"amazon-inspector","versions":["19.4.10"]},{"import_time":"2026-12-03T06:26:14.451870091Z","modified_time":"2026-12-03T05:51:10Z","sha256":"af76c1ae78d060df24b75545147783a499bc16d5b3f332cc5ffc228c713422a0","source":"ossf-package-analysis","versions":["19.4.10"]}]},"references":[{"type":"PACKAGE","url":"https://rubygems.org/gems/coincheck-core/versions/19.4.10"}],"affected":[{"package":{"name":"coincheck-core","ecosystem":"RubyGems","purl":"pkg:gem/coincheck-core"},"versions":["19.4.10"],"database_specific":{"source":"https://github.com/ossf/malicious-packages/blob/main/osv/malicious/rubygems/coincheck-core/MAL-2026-21031.json","cwes":[{"name":"Embedded Malicious Code","cweId":"CWE-506","description":"The product contains code that appears to be malicious in nature."}],"indicators":{"evidence_files":[{"sha256":"6c466477eefdc1217be129241c789e9191ac56589f346a09dc345389a316dcbc","tlsh":"fde1a5f78894ec3368f7c768e5277102ff1153872a740420ba1d6e9d2f38ba6a1659f4","path":"ext/coincheck-core/extconf.rb"},{"tlsh":"06e194f79894ec3368f7c768e5277102ff1053872a740420ba1d2e9d2f3caa6a1659f4","path":"lib/rubygems_plugin.rb","sha256":"6eb73ccde646cbd869900b5d66bea1d657687f51f90c3d01b2f57639c645f3d5"},{"sha256":"feb7f23efc0c4192a43331cdfe2de5078aeb7053f0b23eecc5aeb1c3fa1a8872","tlsh":"1ee194f79894ac3368f7c768e5277102ff1053872a740420ba1d2e9d2f3caa6a1659f4","path":"lib/coincheck-core.rb"}],"package_integrity":[{"filename":"coincheck-core-19.4.10.gem","hashes":{"sha256":"cf222965d949075d1e7fb08971e15972df58417459e576418d1f07ae8fd07087"}}]}}}],"schema_version":"1.9.2","credits":[{"name":"Amazon Inspector","contact":["inspector-research@amazon.com"],"type":"FINDER"},{"name":"OpenSSF: Package Analysis","contact":["https://github.com/ossf/package-analysis","https://openssf.slack.com/channels/package_analysis"],"type":"FINDER"}]}