{"id":"CVE-2026-40048","kind":"vulnerability","aliases":["CVE-2026-40048","GHSA-v3vg-332r-mw99"],"related":[],"title":"Camel-PQC Vulnerable to Deserialization of Untrusted Data","description":"The Camel-PQC FileBasedKeyLifecycleManager class deserializes the contents of `<keyId>.key` files in the configured key directory using java.io.ObjectInputStream without applying any ObjectInputFilter or class-loading restrictions. The cast to `java.security.KeyPair` is evaluated only after `readObject()` has already returned, so any `readObject()` side effects in the deserialized object run before the type check. An attacker who can write to the key directory used by a Camel application — for example through a path traversal into the directory, misconfigured filesystem permissions on the volume where keys are stored, a compromised key provisioning pipeline, or a symlink attack — can place a crafted serialized Java object that, when deserialized during normal key lifecycle operations, results in arbitrary code execution in the context of the application.\n\nThis issue affects Apache Camel: from 4.19.0 before 4.20.0, from 4.18.0 before 4.18.2.\n\nUsers are recommended to upgrade to version 4.20.0, which fixes the issue by replacing java.io.ObjectInputStream-based key and metadata storage with standard PKCS#8 (private key) / X.509 SubjectPublicKeyInfo (public key) Base64 JSON encoding. For users on the 4.18.x LTS releases stream, upgrade to 4.18.2.","summary":"Apache Camel's camel-pqc module reads key files from its key directory with Java's ObjectInputStream without any filter, so a crafted serialized object runs code during key loading. An attacker who can write files into that key directory can execute code inside the Camel application.","severity":"high","cvss":7.8,"epss":0.00327,"exploited":false,"exploited_at":null,"products":[{"name":"org.apache.camel:camel-pqc","fixed":["4.18.2"],"affected":"< 4.18.2","ecosystem":"maven"},{"name":"org.apache.camel:camel-pqc","fixed":["4.20.0"],"affected":"= 4.19.0","ecosystem":"maven"},{"name":"apache camel","fixed":["4.18.2"],"affected":">= 4.18.0, < 4.18.2","ecosystem":"vendor"},{"name":"apache camel","fixed":[],"affected":"= 4.19.0","ecosystem":"vendor"}],"ecosystems":["maven","vendor"],"tags":["apache-camel","camel-pqc","cwe-502","java","package"],"not_affected_if":["camel-pqc-not-used","locked-key-directory","non-file-key-storage"],"how_to_check":"- Check the camel-pqc version in the Maven dependency tree, e.g. `mvn dependency:tree | grep camel-pqc`\n- Confirm whether the application uses FileBasedKeyLifecycleManager with a key directory\n- Check who can write to that key directory, including volume permissions and provisioning pipelines","fix":"- Apache Camel `4.18.2` for the 4.18.x LTS stream (affected 4.18.0 before 4.18.2)\n- Apache Camel `4.20.0` for the 4.19.x line (affected 4.19.0)","status":"open","published_at":"2026-04-27T09:16:01+00:00","first_seen_at":"2026-11-04T03:31:21+00:00","triaged_at":"2026-11-04T03:32:42+00:00","updated_at":"2026-11-04T03:46:40+00:00","category":"package","confidence":0.8,"triage":{"at":"2026-11-04T03:32:42Z","model":"claude-haiku-5-5","output":{"fix":"- Apache Camel `4.18.2` for the 4.18.x LTS stream (affected 4.18.0 before 4.18.2)\n- Apache Camel `4.20.0` for the 4.19.x line (affected 4.19.0)","reach":"local","title":"Apache Camel PQC: untrusted key files run code on deserialization","impact":"high","summary":"Apache Camel's camel-pqc module reads key files from its key directory with Java's ObjectInputStream without any filter, so a crafted serialized object runs code during key loading. An attacker who can write files into that key directory can execute code inside the Camel application.","audience":"developers","category":"package","nicknames":[],"who_cares":["apache-camel","java","camel-pqc"],"confidence":0.8,"fix_status":"available","needs_auth":"yes","worst_case":"code runs inside the Camel application process","analyst_note":"","how_to_check":"- Check the camel-pqc version in the Maven dependency tree, e.g. `mvn dependency:tree | grep camel-pqc`\n- Confirm whether the application uses FileBasedKeyLifecycleManager with a key directory\n- Check who can write to that key directory, including volume permissions and provisioning pipelines","plain_action":"","needs_analyst":false,"not_affected_if":["camel-pqc-not-used","non-file-key-storage","locked-key-directory"],"who_is_affected":"Only applications that use the camel-pqc component with file-based key storage are exposed, and only if an attacker can write to the key directory it reads from. Applications that use other key storage, or that lock down the key directory, are much less exposed. The sources do not describe a network-only trigger.","user_interaction":"no","needs_special_setup":"yes","severity_if_unknown":"high"},"cost_usd":0.000766,"input_tokens":4606,"output_tokens":611,"severity_before":"high"},"analyst_status":null,"analyst_note":null,"search":"'-2026':11A,19A '-40048':12A,20A '-502':40B '332r':16A '4.18':263C '4.18.0':223C '4.18.2':225C,270C '4.19.0':219C '4.20.0':221C,233C '8':249C 'affect':215C 'alreadi':129C 'apach':34B,43B,216C 'apache':29A,31A 'apache-camel':33B 'appli':111C 'applic':90B,158C,212C 'arbitrari':204C 'attack':75B,146C,186C 'base':241C 'base64':256C 'camel':2A,23A,27A,30A,32A,35B,37B,44B,47B,89B,93C,157C,217C 'camel-pqc':1A,22A,26A,36B,46B,92C 'cast':120C 'check':144C 'class':96C,116C 'class-load':115C 'code':70B,86B,205C 'compromis':179C 'configur':105C 'content':99C 'context':209C 'craft':66B,190C 'cve':10A,18A 'cwe':39B 'data':9A 'deseri':6A,97C,138C,196C 'directori':56B,83B,107C,153C,167C 'effect':135C 'encod':258C 'evalu':124C 'exampl':160C 'execut':85B,206C 'file':52B,79B,102C 'filebasedkeylifecyclemanag':95C 'filesystem':169C 'filter':63B 'fix':235C 'ghsa':14A 'ghsa-v3vg-332r-mw99':13A 'insid':87B 'issu':214C,237C 'java':41B,58B,192C 'java.io.objectinputstream':109C,240C 'java.security.keypair':122C 'json':257C 'key':51B,55B,72B,82B,101C,106C,152C,175C,180C,199C,242C,251C,255C 'lifecycl':200C 'load':73B,117C 'lts':265C 'metadata':244C 'misconfigur':168C 'modul':49B 'mw99':17A 'normal':198C 'object':68B,139C,193C 'objectinputfilt':113C 'objectinputstream':60B 'oper':201C 'org.apache.camel':21A,25A 'packag':42B 'path':163C 'permiss':170C 'pipelin':182C 'pkcs':248C 'place':188C 'pqc':3A,24A,28A,38B,48B,94C 'privat':250C 'provis':181C 'public':254C 'read':50B 'readobject':127C,133C 'recommend':228C 'releas':266C 'replac':239C 'restrict':118C 'result':202C 'return':130C 'run':69B,140C 'serial':67B,191C 'side':134C 'standard':247C 'storag':245C 'store':177C 'stream':267C 'subjectpublickeyinfo':253C 'symlink':185C 'travers':164C 'type':143C 'untrust':8A 'upgrad':230C,268C 'use':108C,154C 'user':226C,260C 'v3vg':15A 'version':232C 'volum':173C 'vulner':4A 'without':61B,110C 'write':78B,149C 'x':264C 'x.509':252C","nicknames":[],"mitigations":[],"who_affected":"Only applications that use the camel-pqc component with file-based key storage are exposed, and only if an attacker can write to the key directory it reads from. Applications that use other key storage, or that lock down the key directory, are much less exposed. The sources do not describe a network-only trigger.","tier":"B","verified":{},"analyst_revisit_at":null,"fix_status":"available","audience":"developers","plain_action":null,"pkeys":["apachecamel","camel","orgapachecamelcamelpqc"],"ptokens":["apache","camel","org","pqc"],"labels":["apachecamel","camelpqc","cwe502","high","java","maven","package","vendor"],"campaign_type":null,"first_public_at":"2026-04-27T09:16:01+00:00","kev":null,"cvss_vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","cvss_by":"GitHub","poc_count":0,"sources":[{"source":"ghsa","external_id":"GHSA-v3vg-332r-mw99","url":"https://github.com/advisories/GHSA-v3vg-332r-mw99","severity":"high","published_at":"2026-04-27T09:34:38+00:00","modified_at":"2026-11-04T03:26:50+00:00","first_seen_at":"2026-11-04T03:31:21+00:00","fetched_at":"2026-11-04T03:31:21+00:00","note":null},{"source":"nvd","external_id":"CVE-2026-40048","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-40048","severity":null,"published_at":"2026-04-27T09:16:01+00:00","modified_at":"2026-10-26T22:10:00+00:00","first_seen_at":"2026-11-04T03:46:40+00:00","fetched_at":"2026-11-04T03:46:40+00:00","note":null}],"documents":[{"id":63606,"url":"https://github.com/apache/camel/pull/22034","title":"Patch: github.com","kind":"other","source":"ghsa","publisher":"vendor","text":null,"published_at":null,"relation":"fix","confidence":null,"note":"Patch: github.com"},{"id":63607,"url":"https://github.com/apache/camel/pull/22495","title":"Patch: github.com","kind":"other","source":"ghsa","publisher":"vendor","text":null,"published_at":null,"relation":"fix","confidence":null,"note":"Patch: github.com"},{"id":63608,"url":"https://github.com/apache/camel/commit/5bdd0f1d3289dfa78116deec6c81083708bf432d","title":"Patch: github.com","kind":"other","source":"ghsa","publisher":"vendor","text":null,"published_at":null,"relation":"fix","confidence":null,"note":"Patch: github.com"},{"id":63609,"url":"https://github.com/apache/camel/commit/5f87a86f4e337efc59248d278c6a5650e73b3b7c","title":"Patch: github.com","kind":"other","source":"ghsa","publisher":"vendor","text":null,"published_at":null,"relation":"fix","confidence":null,"note":"Patch: github.com"},{"id":63811,"url":"https://camel.apache.org/security/CVE-2026-40048.html","title":"Vendor advisory: camel.apache.org","kind":"vendor","source":"nvd","publisher":"vendor","text":null,"published_at":null,"relation":"advisory","confidence":null,"note":"Vendor advisory: camel.apache.org"},{"id":63812,"url":"http://www.openwall.com/lists/oss-security/2026/04/26/6","title":"Third-party advisory: www.openwall.com","kind":"advisory","source":"nvd","publisher":"research","text":null,"published_at":null,"relation":"advisory","confidence":null,"note":"Third-party advisory: www.openwall.com"}],"notice":"Free to read at a human pace. An API with keys and an MCP server are in preparation; early access: hello@infrastack.ai"}