In the Linux kernel, the following vulnerability has been resolved:
libbpf: Handle size overflow for ringbuf mmap
The maximum size of ringbuf is 2GB on x86-64 host, so 2 * maxentries will overflow u32 when mapping producer page and data pages. Only casting maxentries to sizet is not enough, because for 32-bits application on 64-bits kernel the size of read-only mmap region also could overflow sizet.
So fixing it by casting the size of read-only mmap region into a __u64 and checking whether or not there will be overflow during mmap.
{
"cna_assigner": "Linux",
"osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2022/49xxx/CVE-2022-49030.json"
}[
{
"signature_version": "v1",
"deprecated": false,
"target": {
"file": "tools/lib/bpf/ringbuf.c"
},
"digest": {
"line_hashes": [
"182041646045616935075848235808817900572",
"276683600360101321145863222240346408826",
"33649977801050699099361130284700725105",
"283627357449336340006601979964091912221",
"276317405728567544823796923615182929228",
"46777037936822841379590930563008198407",
"138311094736446075425802932985555985416",
"107637971047441962357732350238078909639",
"136499186092732013595400627348992744733",
"182704621375198694768512956647656748563",
"188085388368847728133562354076456569971",
"165067792517251921141928653244902384967",
"326785604433909825714773728980403031844",
"58577921407521784359618108709912564224"
],
"threshold": 0.9
},
"signature_type": "Line",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@8a549ab6724520aa3c07f47e0eba820293551490",
"id": "CVE-2022-49030-01ae9aea"
},
{
"signature_version": "v1",
"deprecated": false,
"target": {
"file": "tools/lib/bpf/ringbuf.c"
},
"digest": {
"line_hashes": [
"182041646045616935075848235808817900572",
"276683600360101321145863222240346408826",
"33649977801050699099361130284700725105",
"283627357449336340006601979964091912221",
"276317405728567544823796923615182929228",
"46777037936822841379590930563008198407",
"138311094736446075425802932985555985416",
"107637971047441962357732350238078909639",
"136499186092732013595400627348992744733",
"182563691373873487976168251486197840338",
"188085388368847728133562354076456569971",
"165067792517251921141928653244902384967",
"326785604433909825714773728980403031844",
"58577921407521784359618108709912564224"
],
"threshold": 0.9
},
"signature_type": "Line",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@927cbb478adf917e0a142b94baa37f06279cc466",
"id": "CVE-2022-49030-14148458"
},
{
"signature_version": "v1",
"deprecated": false,
"target": {
"function": "ring_buffer__add",
"file": "tools/lib/bpf/ringbuf.c"
},
"digest": {
"function_hash": "33826064554763964099384641097249816004",
"length": 2133.0
},
"signature_type": "Function",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@0140e079a42064680394fff1199a7b5483688dec",
"id": "CVE-2022-49030-1d854cd4"
},
{
"signature_version": "v1",
"deprecated": false,
"target": {
"file": "tools/lib/bpf/ringbuf.c"
},
"digest": {
"line_hashes": [
"182041646045616935075848235808817900572",
"276683600360101321145863222240346408826",
"33649977801050699099361130284700725105",
"283627357449336340006601979964091912221",
"276317405728567544823796923615182929228",
"46777037936822841379590930563008198407",
"138311094736446075425802932985555985416",
"107637971047441962357732350238078909639",
"136499186092732013595400627348992744733",
"182563691373873487976168251486197840338",
"188085388368847728133562354076456569971",
"165067792517251921141928653244902384967",
"326785604433909825714773728980403031844",
"58577921407521784359618108709912564224"
],
"threshold": 0.9
},
"signature_type": "Line",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@535a25ab4f9a45f74ba38ab71de95e97474922ed",
"id": "CVE-2022-49030-3bf47977"
},
{
"signature_version": "v1",
"deprecated": false,
"target": {
"function": "ring_buffer__add",
"file": "tools/lib/bpf/ringbuf.c"
},
"digest": {
"function_hash": "33826064554763964099384641097249816004",
"length": 2133.0
},
"signature_type": "Function",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@927cbb478adf917e0a142b94baa37f06279cc466",
"id": "CVE-2022-49030-7521a21f"
},
{
"signature_version": "v1",
"deprecated": false,
"target": {
"file": "tools/lib/bpf/ringbuf.c"
},
"digest": {
"line_hashes": [
"182041646045616935075848235808817900572",
"276683600360101321145863222240346408826",
"33649977801050699099361130284700725105",
"283627357449336340006601979964091912221",
"276317405728567544823796923615182929228",
"46777037936822841379590930563008198407",
"138311094736446075425802932985555985416",
"107637971047441962357732350238078909639",
"136499186092732013595400627348992744733",
"182563691373873487976168251486197840338",
"188085388368847728133562354076456569971",
"165067792517251921141928653244902384967",
"326785604433909825714773728980403031844",
"58577921407521784359618108709912564224"
],
"threshold": 0.9
},
"signature_type": "Line",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@0140e079a42064680394fff1199a7b5483688dec",
"id": "CVE-2022-49030-93aee4b8"
},
{
"signature_version": "v1",
"deprecated": false,
"target": {
"function": "ring_buffer__add",
"file": "tools/lib/bpf/ringbuf.c"
},
"digest": {
"function_hash": "197102358432411747101383925349542786387",
"length": 2042.0
},
"signature_type": "Function",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@8a549ab6724520aa3c07f47e0eba820293551490",
"id": "CVE-2022-49030-9be886ac"
},
{
"signature_version": "v1",
"deprecated": false,
"target": {
"function": "ring_buffer__add",
"file": "tools/lib/bpf/ringbuf.c"
},
"digest": {
"function_hash": "33826064554763964099384641097249816004",
"length": 2133.0
},
"signature_type": "Function",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@535a25ab4f9a45f74ba38ab71de95e97474922ed",
"id": "CVE-2022-49030-eeaffccb"
}
]
"https://storage.googleapis.com/osv-test-cve-osv-conversion/osv-output/CVE-2022-49030.json"