In the Linux kernel, the following vulnerability has been resolved:
xfrm: fix refcount leak in _xfrmpolicy_check()
The issue happens on an error path in _xfrmpolicycheck(). When the
fetching process of the object pols[1] fails, the function simply
returns 0, forgetting to decrement the reference count of pols[0],
which is incremented earlier by either xfrmskpolicylookup() or
xfrmpolicylookup(). This may result in memory leaks.
Fix it by decreasing the reference count of pols[0] in that path.
[
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@8f94b933103ee1bda119543369cc18a1be5536db",
"id": "CVE-2022-50007-0a936006",
"deprecated": false,
"target": {
"file": "net/xfrm/xfrm_policy.c"
},
"signature_version": "v1",
"signature_type": "Line",
"digest": {
"threshold": 0.9,
"line_hashes": [
"270475939372055069018519009339317756769",
"54188628470976307948068028489773038673",
"170170027269208934435299386967747894322",
"199095001533435416810141299690464680371"
]
}
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@18e6b6e2555c93f5ca09f2b85ef1fa025c8accea",
"id": "CVE-2022-50007-2a0cc2eb",
"deprecated": false,
"target": {
"file": "net/xfrm/xfrm_policy.c"
},
"signature_version": "v1",
"signature_type": "Line",
"digest": {
"threshold": 0.9,
"line_hashes": [
"270475939372055069018519009339317756769",
"54188628470976307948068028489773038673",
"170170027269208934435299386967747894322",
"199095001533435416810141299690464680371"
]
}
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@26ad2398fe4984f4f6f930bcb3bc9047fa77265b",
"id": "CVE-2022-50007-2a60b29d",
"deprecated": false,
"target": {
"function": "__xfrm_policy_check",
"file": "net/xfrm/xfrm_policy.c"
},
"signature_version": "v1",
"signature_type": "Function",
"digest": {
"length": 3465.0,
"function_hash": "174061315073970267961255295591924681502"
}
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@8f94b933103ee1bda119543369cc18a1be5536db",
"id": "CVE-2022-50007-9a05d1bc",
"deprecated": false,
"target": {
"function": "__xfrm_policy_check",
"file": "net/xfrm/xfrm_policy.c"
},
"signature_version": "v1",
"signature_type": "Function",
"digest": {
"length": 2974.0,
"function_hash": "63767316744899868643444375461143989240"
}
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@9c9cb23e00ddf45679b21b4dacc11d1ae7961ebe",
"id": "CVE-2022-50007-9d71bc04",
"deprecated": false,
"target": {
"function": "__xfrm_policy_check",
"file": "net/xfrm/xfrm_policy.c"
},
"signature_version": "v1",
"signature_type": "Function",
"digest": {
"length": 3465.0,
"function_hash": "174061315073970267961255295591924681502"
}
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@0769491a8acd3e85ca4c3f65080eac2c824262df",
"id": "CVE-2022-50007-a19fa27b",
"deprecated": false,
"target": {
"file": "net/xfrm/xfrm_policy.c"
},
"signature_version": "v1",
"signature_type": "Line",
"digest": {
"threshold": 0.9,
"line_hashes": [
"264086720560395520642126705460263278235",
"54188628470976307948068028489773038673",
"170170027269208934435299386967747894322",
"64665775571715510095539622089028153350"
]
}
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@63da7a2bbf3f28094920e0b8a17d2571a9bd842d",
"id": "CVE-2022-50007-a35319cd",
"deprecated": false,
"target": {
"function": "__xfrm_policy_check",
"file": "net/xfrm/xfrm_policy.c"
},
"signature_version": "v1",
"signature_type": "Function",
"digest": {
"length": 3191.0,
"function_hash": "35792663725961488371855433463811519553"
}
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@63da7a2bbf3f28094920e0b8a17d2571a9bd842d",
"id": "CVE-2022-50007-adbd3f55",
"deprecated": false,
"target": {
"file": "net/xfrm/xfrm_policy.c"
},
"signature_version": "v1",
"signature_type": "Line",
"digest": {
"threshold": 0.9,
"line_hashes": [
"264086720560395520642126705460263278235",
"54188628470976307948068028489773038673",
"170170027269208934435299386967747894322",
"64665775571715510095539622089028153350"
]
}
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@d66c052879791313f90c0584420f196a038fb8b8",
"id": "CVE-2022-50007-c209139d",
"deprecated": false,
"target": {
"function": "__xfrm_policy_check",
"file": "net/xfrm/xfrm_policy.c"
},
"signature_version": "v1",
"signature_type": "Function",
"digest": {
"length": 3465.0,
"function_hash": "174061315073970267961255295591924681502"
}
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@0769491a8acd3e85ca4c3f65080eac2c824262df",
"id": "CVE-2022-50007-c5d7c7dc",
"deprecated": false,
"target": {
"function": "__xfrm_policy_check",
"file": "net/xfrm/xfrm_policy.c"
},
"signature_version": "v1",
"signature_type": "Function",
"digest": {
"length": 3213.0,
"function_hash": "338770495449320127558839312425457163499"
}
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@d66c052879791313f90c0584420f196a038fb8b8",
"id": "CVE-2022-50007-d91a62d3",
"deprecated": false,
"target": {
"file": "net/xfrm/xfrm_policy.c"
},
"signature_version": "v1",
"signature_type": "Line",
"digest": {
"threshold": 0.9,
"line_hashes": [
"264086720560395520642126705460263278235",
"54188628470976307948068028489773038673",
"170170027269208934435299386967747894322",
"64665775571715510095539622089028153350"
]
}
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@1305d7d4f35ca6f214a2d23b075aa6a924cff3be",
"id": "CVE-2022-50007-da215b54",
"deprecated": false,
"target": {
"file": "net/xfrm/xfrm_policy.c"
},
"signature_version": "v1",
"signature_type": "Line",
"digest": {
"threshold": 0.9,
"line_hashes": [
"264086720560395520642126705460263278235",
"54188628470976307948068028489773038673",
"170170027269208934435299386967747894322",
"64665775571715510095539622089028153350"
]
}
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@26ad2398fe4984f4f6f930bcb3bc9047fa77265b",
"id": "CVE-2022-50007-e8798f43",
"deprecated": false,
"target": {
"file": "net/xfrm/xfrm_policy.c"
},
"signature_version": "v1",
"signature_type": "Line",
"digest": {
"threshold": 0.9,
"line_hashes": [
"264086720560395520642126705460263278235",
"54188628470976307948068028489773038673",
"170170027269208934435299386967747894322",
"64665775571715510095539622089028153350"
]
}
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@18e6b6e2555c93f5ca09f2b85ef1fa025c8accea",
"id": "CVE-2022-50007-f41c974f",
"deprecated": false,
"target": {
"function": "__xfrm_policy_check",
"file": "net/xfrm/xfrm_policy.c"
},
"signature_version": "v1",
"signature_type": "Function",
"digest": {
"length": 3154.0,
"function_hash": "175963047426055195271421027983636441484"
}
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@9c9cb23e00ddf45679b21b4dacc11d1ae7961ebe",
"id": "CVE-2022-50007-f55a98ad",
"deprecated": false,
"target": {
"file": "net/xfrm/xfrm_policy.c"
},
"signature_version": "v1",
"signature_type": "Line",
"digest": {
"threshold": 0.9,
"line_hashes": [
"264086720560395520642126705460263278235",
"54188628470976307948068028489773038673",
"170170027269208934435299386967747894322",
"64665775571715510095539622089028153350"
]
}
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@1305d7d4f35ca6f214a2d23b075aa6a924cff3be",
"id": "CVE-2022-50007-ff1dbc13",
"deprecated": false,
"target": {
"function": "__xfrm_policy_check",
"file": "net/xfrm/xfrm_policy.c"
},
"signature_version": "v1",
"signature_type": "Function",
"digest": {
"length": 3465.0,
"function_hash": "174061315073970267961255295591924681502"
}
}
]