The allocated target buffer for base64 output is sometimes too short, leading to an overrun. (And I suspect it's causing memory corruption with eventual misbehavior and segfaults.)
A hex string may be the same length as the base64 representation. To allow for a terminating null on the base64 string, we need to allocate an additional byte.
string abcd
hex 61626364
base64 YWJjZA==
You can view, comment on, or merge this pull request online at:
https://github.com/xrootd/xrootd/pull/1012
Commit Summary
- [XrdHttp] Fix one-byte overrun in Tobase64()
File Changes
Patch Links:
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or mute the thread.
[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/xrootd/xrootd/pull/1012?email_source=notifications\u0026email_token=AA7NRDRRJPIOQTE62QJBWUDP4I6RLA5CNFSM4H3J434KYY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4G3S3FAQ",
"url": "https://github.com/xrootd/xrootd/pull/1012?email_source=notifications\u0026email_token=AA7NRDRRJPIOQTE62QJBWUDP4I6RLA5CNFSM4H3J434KYY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4G3S3FAQ",
"name": "View Pull Request"
},
"description": "View this Pull Request on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]
Use REPLY-ALL to reply to list
To unsubscribe from the XROOTD-DEV list, click the following link:
https://listserv.slac.stanford.edu/cgi-bin/wa?SUBED1=XROOTD-DEV&A=1