{"id":"GHSA-h5fq-653g-gxrm","aliases":["GO-2026-5413"],"title":"ots has a negative expire override that can bypass its secret retention policy","summary":"ots has a negative expire override that can bypass its secret retention policy","severity":"medium","cvss":5.3,"cvssVector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:N","vendor":"Luzifer","product":"github.com/Luzifer/ots","ecosystem":"go","affected":["github.com/Luzifer/ots < 1.21.5"],"patched":["github.com/Luzifer/ots 1.21.5"],"published":"2026-05-05","updated":"2026-07-21","source":"OSV","sourceUrl":"https://osv.dev/vulnerability/GHSA-h5fq-653g-gxrm","references":[{"url":"https://github.com/Luzifer/ots/security/advisories/GHSA-h5fq-653g-gxrm"},{"url":"https://github.com/Luzifer/ots/commit/3511bd18a2bec75bd9c6b4d513f2a90ccf4209b7"},{"url":"https://github.com/Luzifer/ots"},{"url":"https://github.com/Luzifer/ots/releases/tag/v1.21.5"}],"tags":["osv","go"],"ingestedAt":"2026-07-21T19:04:59.281Z","slug":"GHSA-h5fq-653g-gxrm","body":"## Overview\n\n## Summary\n\nThe `/api/create` endpoint accepted negative `expire` query values. For the memory storage backend, negative values were passed to secret creation as a negative duration and treated as no expiry, allowing callers to create secrets that persisted longer than intended.\n\n## Impact\n\nUnauthenticated users could bypass configured retention expectations for secrets they create by sending `POST /api/create?expire=-1`.\n\nThis does not allow reading or modifying secrets created by other users. Secrets remain one-time-read and, in the normal web flow, client-side encrypted.\n\n## Affected versions\n\nVersions up to and including v1.21.4 are affected.\n\n## Patched versions\n\nFixed in v1.21.5.\n\n## Workarounds\n\nDisable expiry overrides via `disableExpiryOverride: true` until upgrading.\n\n## Credit\n\nReported by Chai Cheng Xun via email.\n\n## Affected packages\n\n- `github.com/Luzifer/ots < 1.21.5`\n\n## Remediation\n\nUpgrade to a patched release:\n\n- `github.com/Luzifer/ots 1.21.5`","depth":"sunlit","depthScore":29,"depthScoreParts":{"impact":29.2,"likelihood":0,"exploitation":0,"ransomware":0},"changes":[]}