{"id":"CVE-2021-21428","published":"2021-05-10T18:50:12Z","modified":"2024-08-03T18:09:16Z","title":"Creation of Temporary File in Directory with Insecure Permissions in the OpenAPI-Generator online generator","vendor":"OpenAPITools","product":"openapi-generator","tier":"tail","description":{"text":"Openapi generator is a java tool which allows generation of API client libraries (SDK generation), server stubs, documentation and configuration automatically given an OpenAPI Spec. openapi-generator-online creates insecure temporary folders with File.createTempFile during the code generation process. The insecure temporary folders store the auto-generated files which can be read and appended to by any users on the system. The issue has been patched with `Files.createTempFile` and released in the v5.1.0 stable version.","provenance":"source","from":"CVE.org"},"cvss":{"score":9.3,"severity":"CRITICAL","version":"3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.00351,"percentile":0.21214,"provenance":"source"},"cwes":[{"id":"CWE-269","name":"Improper Privilege Management"}],"references":[{"url":"https://github.com/OpenAPITools/openapi-generator/security/advisories/GHSA-23x4-m842-fmwf","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/OpenAPITools/openapi-generator/pull/8788","tags":["x_refsource_MISC"]}],"priority":{"score":10.8,"factors":[{"name":"EPSS percentile","points":4.24},{"name":"CVSS severity","points":6.51}]},"vendorSlug":"openapitools","affectedVersions":[{"vendor":"OpenAPITools","product":"openapi-generator","versions":["< 5.1.0"]}],"affected":[{"ecosystem":"Maven","package":"org.openapitools:openapi-generator-online","vulnerableRanges":["<5.1.0"],"patched":["5.1.0"],"from":["GHSA-23x4-m842-fmwf"],"provenance":"source"}],"summary":{"text":"The openapi-generator-online component of the OpenAPITools openapi-generator product creates temporary folders with File.createTempFile during code generation, so the auto-generated files are stored in locations that are insecure. An attacker with local access to the system can read and append to those generated files, since any user on the system can access them, and no privileges or user interaction are required.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-20T21:44:05Z"},"euvd":{"id":"EUVD-2021-0893","exploited":false,"provenance":"source"},"lineage":{"familyId":"fam-swagger-api-swagger-codegen-cve-2021-21363","parents":[{"from":"CVE-2021-21363","to":"CVE-2021-21428","relation":"related","confidence":"high","kind":"lineage","evidence":[{"kind":"osv-related","provenance":"source","id":"GHSA-23x4-m842-fmwf","via":"reference","url":"https://github.com/swagger-api/swagger-codegen/security/advisories/GHSA-pc22-3g76-gm6j"}]}]}}