In the Linux kernel, the following vulnerability has been resolved:
netfilter: nftsetrbtree: fix overlap expiration walk
The lazy gc on insert that should remove timed-out entries fails to release the other half of the interval, if any.
Can be reproduced with tests/shell/testcases/sets/0044intervaloverlap0 in nftables.git and kmemleak enabled kernel.
Second bug is the use of rbeprev vs. prev pointer. If rbeprev() returns NULL after at least one iteration, rbe_prev points to element that is not an end interval, hence it should not be removed.
Lastly, check the genmask of the end interval if this is active in the current generation.
[
{
"id": "CVE-2023-53304-017d5466",
"target": {
"file": "net/netfilter/nft_set_rbtree.c"
},
"digest": {
"line_hashes": [
"53172599047333514096758690419117826547",
"273442660338655390814777516518140518827",
"107990530882356724053403499416811575039",
"199159222258857346756457025308483287309",
"133856760659744056907656148284173067593",
"122179434421342771279288655758536261000",
"231492451486480431822371260776326942809",
"158786902479737354811207307632381863672",
"313074012963881649217144033617003271373",
"138599083326748678734688788373613660777",
"269227455918778153461533120620964091901",
"323960449169383982679443959241827353966",
"326064532413314920388957192634516358720",
"207267448997991820784992407744505587893",
"19302396390207800904103248875952713451",
"208847150745767814484747211404062346941",
"318880427682731914861767394515328648563",
"104259889122266342905224245041086875029",
"231155644174713330839940613659393861220",
"233397430950564116502434483132624032398",
"211360622668213237468422872753589672548",
"263722148224009607872260343116378582401",
"113394037531380563656344138958441940818",
"302337775697281697137173066534376476819",
"91573496095094877497621727838252969140"
],
"threshold": 0.9
},
"signature_version": "v1",
"deprecated": false,
"signature_type": "Line",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@acaee227cf79c45a5d2d49c3e9a66333a462802c"
},
{
"id": "CVE-2023-53304-0245bcb7",
"target": {
"file": "net/netfilter/nft_set_rbtree.c"
},
"digest": {
"line_hashes": [
"53172599047333514096758690419117826547",
"273442660338655390814777516518140518827",
"107990530882356724053403499416811575039",
"199159222258857346756457025308483287309",
"133856760659744056907656148284173067593",
"122179434421342771279288655758536261000",
"231492451486480431822371260776326942809",
"158786902479737354811207307632381863672",
"313074012963881649217144033617003271373",
"138599083326748678734688788373613660777",
"269227455918778153461533120620964091901",
"323960449169383982679443959241827353966",
"326064532413314920388957192634516358720",
"207267448997991820784992407744505587893",
"19302396390207800904103248875952713451",
"208847150745767814484747211404062346941",
"318880427682731914861767394515328648563",
"104259889122266342905224245041086875029",
"231155644174713330839940613659393861220",
"233397430950564116502434483132624032398",
"211360622668213237468422872753589672548",
"263722148224009607872260343116378582401",
"113394037531380563656344138958441940818",
"302337775697281697137173066534376476819",
"91573496095094877497621727838252969140"
],
"threshold": 0.9
},
"signature_version": "v1",
"deprecated": false,
"signature_type": "Line",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@50cbb9d195c197af671869c8cadce3bd483735a0"
},
{
"id": "CVE-2023-53304-213ff665",
"target": {
"file": "net/netfilter/nft_set_rbtree.c"
},
"digest": {
"line_hashes": [
"53172599047333514096758690419117826547",
"273442660338655390814777516518140518827",
"107990530882356724053403499416811575039",
"199159222258857346756457025308483287309",
"133856760659744056907656148284173067593",
"122179434421342771279288655758536261000",
"231492451486480431822371260776326942809",
"158786902479737354811207307632381863672",
"313074012963881649217144033617003271373",
"138599083326748678734688788373613660777",
"269227455918778153461533120620964091901",
"323960449169383982679443959241827353966",
"326064532413314920388957192634516358720",
"207267448997991820784992407744505587893",
"19302396390207800904103248875952713451",
"208847150745767814484747211404062346941",
"318880427682731914861767394515328648563",
"104259889122266342905224245041086875029",
"231155644174713330839940613659393861220",
"233397430950564116502434483132624032398",
"211360622668213237468422872753589672548",
"263722148224009607872260343116378582401",
"113394037531380563656344138958441940818",
"302337775697281697137173066534376476819",
"91573496095094877497621727838252969140"
],
"threshold": 0.9
},
"signature_version": "v1",
"deprecated": false,
"signature_type": "Line",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@89a4d1a89751a0fbd520e64091873e19cc0979e8"
},
{
"id": "CVE-2023-53304-2efe7a61",
"target": {
"function": "nft_rbtree_gc_elem",
"file": "net/netfilter/nft_set_rbtree.c"
},
"digest": {
"length": 616.0,
"function_hash": "312016713040669789940659515556522880107"
},
"signature_version": "v1",
"deprecated": false,
"signature_type": "Function",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@893cb3c3513cf661a0ff45fe0cfa83fe27131f76"
},
{
"id": "CVE-2023-53304-4370ec32",
"target": {
"function": "nft_rbtree_gc_elem",
"file": "net/netfilter/nft_set_rbtree.c"
},
"digest": {
"length": 616.0,
"function_hash": "312016713040669789940659515556522880107"
},
"signature_version": "v1",
"deprecated": false,
"signature_type": "Function",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@acaee227cf79c45a5d2d49c3e9a66333a462802c"
},
{
"id": "CVE-2023-53304-6210b43d",
"target": {
"file": "net/netfilter/nft_set_rbtree.c"
},
"digest": {
"line_hashes": [
"53172599047333514096758690419117826547",
"273442660338655390814777516518140518827",
"107990530882356724053403499416811575039",
"199159222258857346756457025308483287309",
"133856760659744056907656148284173067593",
"122179434421342771279288655758536261000",
"231492451486480431822371260776326942809",
"158786902479737354811207307632381863672",
"313074012963881649217144033617003271373",
"138599083326748678734688788373613660777",
"269227455918778153461533120620964091901",
"323960449169383982679443959241827353966",
"326064532413314920388957192634516358720",
"207267448997991820784992407744505587893",
"19302396390207800904103248875952713451",
"208847150745767814484747211404062346941",
"318880427682731914861767394515328648563",
"104259889122266342905224245041086875029",
"231155644174713330839940613659393861220",
"233397430950564116502434483132624032398",
"211360622668213237468422872753589672548",
"263722148224009607872260343116378582401",
"113394037531380563656344138958441940818",
"302337775697281697137173066534376476819",
"91573496095094877497621727838252969140"
],
"threshold": 0.9
},
"signature_version": "v1",
"deprecated": false,
"signature_type": "Line",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@8284a79136c384059e85e278da2210b809730287"
},
{
"id": "CVE-2023-53304-76915c66",
"target": {
"file": "net/netfilter/nft_set_rbtree.c"
},
"digest": {
"line_hashes": [
"53172599047333514096758690419117826547",
"273442660338655390814777516518140518827",
"107990530882356724053403499416811575039",
"199159222258857346756457025308483287309",
"133856760659744056907656148284173067593",
"122179434421342771279288655758536261000",
"231492451486480431822371260776326942809",
"158786902479737354811207307632381863672",
"313074012963881649217144033617003271373",
"138599083326748678734688788373613660777",
"269227455918778153461533120620964091901",
"323960449169383982679443959241827353966",
"326064532413314920388957192634516358720",
"207267448997991820784992407744505587893",
"19302396390207800904103248875952713451",
"208847150745767814484747211404062346941",
"318880427682731914861767394515328648563",
"104259889122266342905224245041086875029",
"231155644174713330839940613659393861220",
"233397430950564116502434483132624032398",
"211360622668213237468422872753589672548",
"263722148224009607872260343116378582401",
"113394037531380563656344138958441940818",
"302337775697281697137173066534376476819",
"91573496095094877497621727838252969140"
],
"threshold": 0.9
},
"signature_version": "v1",
"deprecated": false,
"signature_type": "Line",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@cd66733932399475fe933cb3ec03e687ed401462"
},
{
"id": "CVE-2023-53304-7c9d7064",
"target": {
"file": "net/netfilter/nft_set_rbtree.c"
},
"digest": {
"line_hashes": [
"53172599047333514096758690419117826547",
"273442660338655390814777516518140518827",
"107990530882356724053403499416811575039",
"199159222258857346756457025308483287309",
"133856760659744056907656148284173067593",
"122179434421342771279288655758536261000",
"231492451486480431822371260776326942809",
"158786902479737354811207307632381863672",
"313074012963881649217144033617003271373",
"138599083326748678734688788373613660777",
"269227455918778153461533120620964091901",
"323960449169383982679443959241827353966",
"326064532413314920388957192634516358720",
"207267448997991820784992407744505587893",
"19302396390207800904103248875952713451",
"208847150745767814484747211404062346941",
"318880427682731914861767394515328648563",
"104259889122266342905224245041086875029",
"231155644174713330839940613659393861220",
"233397430950564116502434483132624032398",
"211360622668213237468422872753589672548",
"263722148224009607872260343116378582401",
"113394037531380563656344138958441940818",
"302337775697281697137173066534376476819",
"91573496095094877497621727838252969140"
],
"threshold": 0.9
},
"signature_version": "v1",
"deprecated": false,
"signature_type": "Line",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@893cb3c3513cf661a0ff45fe0cfa83fe27131f76"
},
{
"id": "CVE-2023-53304-82e31f45",
"target": {
"function": "nft_rbtree_gc_elem",
"file": "net/netfilter/nft_set_rbtree.c"
},
"digest": {
"length": 616.0,
"function_hash": "312016713040669789940659515556522880107"
},
"signature_version": "v1",
"deprecated": false,
"signature_type": "Function",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@8284a79136c384059e85e278da2210b809730287"
},
{
"id": "CVE-2023-53304-96a9324c",
"target": {
"function": "nft_rbtree_gc_elem",
"file": "net/netfilter/nft_set_rbtree.c"
},
"digest": {
"length": 616.0,
"function_hash": "312016713040669789940659515556522880107"
},
"signature_version": "v1",
"deprecated": false,
"signature_type": "Function",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@50cbb9d195c197af671869c8cadce3bd483735a0"
},
{
"id": "CVE-2023-53304-a3ef70d2",
"target": {
"function": "nft_rbtree_gc_elem",
"file": "net/netfilter/nft_set_rbtree.c"
},
"digest": {
"length": 616.0,
"function_hash": "312016713040669789940659515556522880107"
},
"signature_version": "v1",
"deprecated": false,
"signature_type": "Function",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@cd66733932399475fe933cb3ec03e687ed401462"
},
{
"id": "CVE-2023-53304-b274d036",
"target": {
"function": "nft_rbtree_gc_elem",
"file": "net/netfilter/nft_set_rbtree.c"
},
"digest": {
"length": 616.0,
"function_hash": "312016713040669789940659515556522880107"
},
"signature_version": "v1",
"deprecated": false,
"signature_type": "Function",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@89a4d1a89751a0fbd520e64091873e19cc0979e8"
},
{
"id": "CVE-2023-53304-f45fb1be",
"target": {
"function": "nft_rbtree_gc_elem",
"file": "net/netfilter/nft_set_rbtree.c"
},
"digest": {
"length": 616.0,
"function_hash": "312016713040669789940659515556522880107"
},
"signature_version": "v1",
"deprecated": false,
"signature_type": "Function",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@f718863aca469a109895cb855e6b81fff4827d71"
},
{
"id": "CVE-2023-53304-f81372b5",
"target": {
"file": "net/netfilter/nft_set_rbtree.c"
},
"digest": {
"line_hashes": [
"53172599047333514096758690419117826547",
"273442660338655390814777516518140518827",
"107990530882356724053403499416811575039",
"199159222258857346756457025308483287309",
"133856760659744056907656148284173067593",
"122179434421342771279288655758536261000",
"231492451486480431822371260776326942809",
"158786902479737354811207307632381863672",
"313074012963881649217144033617003271373",
"138599083326748678734688788373613660777",
"269227455918778153461533120620964091901",
"323960449169383982679443959241827353966",
"326064532413314920388957192634516358720",
"207267448997991820784992407744505587893",
"19302396390207800904103248875952713451",
"208847150745767814484747211404062346941",
"318880427682731914861767394515328648563",
"104259889122266342905224245041086875029",
"231155644174713330839940613659393861220",
"233397430950564116502434483132624032398",
"211360622668213237468422872753589672548",
"263722148224009607872260343116378582401",
"113394037531380563656344138958441940818",
"302337775697281697137173066534376476819",
"91573496095094877497621727838252969140"
],
"threshold": 0.9
},
"signature_version": "v1",
"deprecated": false,
"signature_type": "Line",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@f718863aca469a109895cb855e6b81fff4827d71"
}
]