public inbox for glibc-bugs@sourceware.org help / color / mirror / Atom feed
From: "eggert at cs dot ucla.edu" <sourceware-bugzilla@sourceware.org> To: glibc-bugs@sourceware.org Subject: [Bug time/28338] New: undefined behavior in __tzfile_compute with oddball TZif file Date: Tue, 14 Sep 2021 05:47:12 +0000 [thread overview] Message-ID: <bug-28338-131@http.sourceware.org/bugzilla/> (raw) https://sourceware.org/bugzilla/show_bug.cgi?id=28338 Bug ID: 28338 Summary: undefined behavior in __tzfile_compute with oddball TZif file Product: glibc Version: 2.34 Status: NEW Severity: normal Priority: P2 Component: time Assignee: unassigned at sourceware dot org Reporter: eggert at cs dot ucla.edu Target Milestone: --- Created attachment 13665 --> https://sourceware.org/bugzilla/attachment.cgi?id=13665&action=edit Fix access before array start in __tzfile_compute. __tzfile_compute reads before the beginning of an array when given a weird-but-valid TZif file and a localtime request exactly matching a negative leap second. Patch attached. The bug in the unpatched version occurs when (i == 0 && leaps[i].change <= 0); the code goes on to access leaps[-1] which is out of the array bounds. -- You are receiving this mail because: You are on the CC list for the bug.
next reply other threads:[~2021-09-14 5:47 UTC|newest] Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top 2021-09-14 5:47 eggert at cs dot ucla.edu [this message] 2021-10-07 14:03 ` [Bug time/28338] " adhemerval.zanella at linaro dot org
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=bug-28338-131@http.sourceware.org/bugzilla/ \ --to=sourceware-bugzilla@sourceware.org \ --cc=glibc-bugs@sourceware.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).