In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
| linux | | https://git.kernel.org/linus/009367099eb61a4fc2af44d4eb06b6b4de7de6db | https://git.kernel.org/linus/1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 | ubuntu |
</details>
二、漏洞分析结构反馈
影响性分析说明:
Inthe Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val'.]GCC warns that `val' may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...]val; } This patch adds a default entry in the switch statement that sets`val' to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val'.]GCC warns that `val' may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...]val; } This patch adds a default entry in the switch statement that sets`val' to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
| linux | | https://git.kernel.org/linus/009367099eb61a4fc2af44d4eb06b6b4de7de6db | https://git.kernel.org/linus/1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 | ubuntu |
</details>
二、漏洞分析结构反馈
影响性分析说明:
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val'.]GCC warns that `val' may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...]val; } This patch adds a default entry in the switch statement that sets`val' to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
| linux | | https://git.kernel.org/linus/009367099eb61a4fc2af44d4eb06b6b4de7de6db | https://git.kernel.org/linus/1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 | ubuntu |
</details>
二、漏洞分析结构反馈
影响性分析说明:
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val'.]GCC warns that `val' may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...]val; } This patch adds a default entry in the switch statement that sets`val' to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
| linux | | https://git.kernel.org/linus/009367099eb61a4fc2af44d4eb06b6b4de7de6db | https://git.kernel.org/linus/1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 | ubuntu |
</details>
二、漏洞分析结构反馈
影响性分析说明:
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val'.]GCC warns that `val' may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...]val; } This patch adds a default entry in the switch statement that sets`val' to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
| linux | | https://git.kernel.org/linus/009367099eb61a4fc2af44d4eb06b6b4de7de6db | https://git.kernel.org/linus/1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 | ubuntu |
</details>
二、漏洞分析结构反馈
影响性分析说明:
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1:- Usea default branch in the switch statement to initialize `val'.]GCC warns that `val' may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)){ case 1: val= *(const unsigned char *)p; break; case 2: val= *(const unsigned short *)p; break; case 4: val= *(const unsigned int *)p; break; case 8: val= *(const unsigned long long *)p; break;} [...]val;} This patch addsa default entry in the switch statement that sets`val' to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
| linux | | https://git.kernel.org/linus/009367099eb61a4fc2af44d4eb06b6b4de7de6db | https://git.kernel.org/linus/1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 | ubuntu |
</details>
二、漏洞分析结构反馈
影响性分析说明:
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: -Use adefault branch in the switch statement to initialize `val'.]GCC warns that `val' may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) {case 1: val =*(const unsigned char *)p; break; case 2: val =*(const unsigned short *)p; break; case 4: val =*(const unsigned int *)p; break; case 8: val =*(const unsigned long long *)p; break; }[...]val; }This patch adds adefault entry in the switch statement that sets`val' to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
| linux | | https://git.kernel.org/linus/009367099eb61a4fc2af44d4eb06b6b4de7de6db | https://git.kernel.org/linus/1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 | ubuntu |
</details>
二、漏洞分析结构反馈
影响性分析说明:
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: -Use adefault branch in the switch statement to initialize `val'.]GCC warns that `val' may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) {case 1: val =*(const unsigned char *)p; break; case 2: val =*(const unsigned short *)p; break; case 4: val =*(const unsigned int *)p; break; case 8: val =*(const unsigned long long *)p; break; }[...]val; }This patch adds adefault entry in the switch statement that sets`val' to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
| linux | | https://git.kernel.org/linus/009367099eb61a4fc2af44d4eb06b6b4de7de6db | https://git.kernel.org/linus/1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 | ubuntu |
</details>
二、漏洞分析结构反馈
影响性分析说明:
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1:- Usea default branch in the switch statement to initialize `val'.]GCC warns that `val' may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)){ case 1: val= *(const unsigned char *)p; break; case 2: val= *(const unsigned short *)p; break; case 4: val= *(const unsigned int *)p; break; case 8: val= *(const unsigned long long *)p; break;} [...]val;} This patch addsa default entry in the switch statement that sets`val' to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
| linux | | https://git.kernel.org/linus/009367099eb61a4fc2af44d4eb06b6b4de7de6db | https://git.kernel.org/linus/1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 | ubuntu |
</details>
二、漏洞分析结构反馈
影响性分析说明:
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: -Use adefault branch in the switch statement to initialize `val'.]GCC warns that `val' may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) {case 1: val =*(const unsigned char *)p; break; case 2: val =*(const unsigned short *)p; break; case 4: val =*(const unsigned int *)p; break; case 8: val =*(const unsigned long long *)p; break; }[...]val; }This patch adds adefault entry in the switch statement that sets`val' to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
| linux | | https://git.kernel.org/linus/009367099eb61a4fc2af44d4eb06b6b4de7de6db | https://git.kernel.org/linus/1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 | ubuntu |
</details>
二、漏洞分析结构反馈
影响性分析说明:
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1:- Usea default branch in the switch statement to initialize `val'.]GCC warns that `val' may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)){ case 1: val= *(const unsigned char *)p; break; case 2: val= *(const unsigned short *)p; break; case 4: val= *(const unsigned int *)p; break; case 8: val= *(const unsigned long long *)p; break;} [...]val;} This patch addsa default entry in the switch statement that sets`val' to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
| linux | | https://git.kernel.org/linus/009367099eb61a4fc2af44d4eb06b6b4de7de6db | https://git.kernel.org/linus/1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 | ubuntu |
</details>
二、漏洞分析结构反馈
影响性分析说明:
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val'.]GCC warns that `val' may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...]val; } This patch adds a default entry in the switch statement that sets`val' to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val'.]GCC warns that `val' may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...]val; } This patch adds a default entry in the switch statement that sets`val' to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: -Use adefault branch in the switch statement to initialize `val'.]GCC warns that `val' may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) {case 1: val =*(const unsigned char *)p; break; case 2: val =*(const unsigned short *)p; break; case 4: val =*(const unsigned int *)p; break; case 8: val =*(const unsigned long long *)p; break; }[...]val; }This patch adds adefault entry in the switch statement that sets`val' to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1:- Usea default branch in the switch statement to initialize `val'.]GCC warns that `val' may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)){ case 1: val= *(const unsigned char *)p; break; case 2: val= *(const unsigned short *)p; break; case 4: val= *(const unsigned int *)p; break; case 8: val= *(const unsigned long long *)p; break;} [...]val;} This patch addsa default entry in the switch statement that sets`val' to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val'.]GCC warns that `val' may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...]val; } This patch adds a default entry in the switch statement that sets`val' to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
In the Linux kernel, the following vulnerability has beenresolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val'.]GCC warns that `val' may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...]val; } This patch adds a default entry in the switch statement that sets`val' to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
In the Linux kernel, the following vulnerability has beenresolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val'.]GCC warns that `val' may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...]val; } This patch adds a default entry in the switch statement that sets`val' to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
| linux | | https://git.kernel.org/linus/009367099eb61a4fc2af44d4eb06b6b4de7de6db | https://git.kernel.org/linus/1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 | ubuntu |
</details>
二、漏洞分析结构反馈
影响性分析说明:
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val'.]GCC warns that `val' may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...]val; } This patch adds a default entry in the switch statement that sets`val' to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
| linux | | https://git.kernel.org/linus/009367099eb61a4fc2af44d4eb06b6b4de7de6db | https://git.kernel.org/linus/1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 | ubuntu |
</details>
二、漏洞分析结构反馈
影响性分析说明:
In the Linuxkernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1:- Use adefault branch in the switch statement to initialize `val'.]GCC warns that `val' maybe used uninitialized in theBPF_CRE_READ_BITFIELD macro,defined in bpf_core_read.h as:[...]unsigned long longval; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)){ case 1: val =*(const unsigned char *)p;break; case 2: val =*(const unsigned short *)p;break; case 4: val =*(const unsigned int *)p;break; case 8: val =*(const unsigned long long *)p;break;} [...]val;} This patch adds adefault entry in the switch statement that sets`val'tozero in order to avoid the warning, and random values to beusedin case __builtin_preserve_field_inforeturns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
| linux | | https://git.kernel.org/linus/009367099eb61a4fc2af44d4eb06b6b4de7de6db | https://git.kernel.org/linus/1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 | ubuntu |
</details>
二、漏洞分析结构反馈
影响性分析说明:
IntheLinux kernel,the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use adefaultbranch in the switch statement to initialize `val'.]GCC warns that `val' may be useduninitialized in theBPF_CRE_READ_BITFIELD macro, definedin bpf_core_read.h as:[...]unsigned long long val; [...] switch(__CORE_RELO(s, field, BYTE_SIZE)) { case1:val = *(constunsigned char *)p; break; case2:val = *(constunsigned short *)p; break; case4:val = *(constunsigned int *)p; break; case8:val = *(constunsigned long long *)p; break; }[...]val; }Thispatch adds a defaultentry in the switch statement that sets`val' to zeroinorder to avoid the warning, and random values to beused in case__builtin_preserve_field_info returnsunexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to thisissue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
| linux | | https://git.kernel.org/linus/009367099eb61a4fc2af44d4eb06b6b4de7de6db | https://git.kernel.org/linus/1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 | ubuntu |
</details>
二、漏洞分析结构反馈
影响性分析说明:
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: -Use adefault branch in the switch statement to initialize `val'.]GCC warns that `val' may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) {case 1: val =*(const unsigned char *)p; break; case 2: val =*(const unsigned short *)p; break; case 4: val =*(const unsigned int *)p; break; case 8: val =*(const unsigned long long *)p; break; }[...]val; }This patch adds adefault entry in the switch statement that sets`val' to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
| linux | | https://git.kernel.org/linus/009367099eb61a4fc2af44d4eb06b6b4de7de6db | https://git.kernel.org/linus/1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 | ubuntu |
</details>
二、漏洞分析结构反馈
影响性分析说明:
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1:- Usea default branch in the switch statement to initialize `val'.]GCC warns that `val' may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)){ case 1: val= *(const unsigned char *)p; break; case 2: val= *(const unsigned short *)p; break; case 4: val= *(const unsigned int *)p; break; case 8: val= *(const unsigned long long *)p; break;} [...]val;} This patch addsa default entry in the switch statement that sets`val' to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
| linux | | https://git.kernel.org/linus/009367099eb61a4fc2af44d4eb06b6b4de7de6db | https://git.kernel.org/linus/1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 | ubuntu |
</details>
二、漏洞分析结构反馈
影响性分析说明:
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: -Use adefault branch in the switch statement to initialize `val'.]GCC warns that `val' may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) {case 1: val =*(const unsigned char *)p; break; case 2: val =*(const unsigned short *)p; break; case 4: val =*(const unsigned int *)p; break; case 8: val =*(const unsigned long long *)p; break; }[...]val; }This patch adds adefault entry in the switch statement that sets`val' to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
| linux | | https://git.kernel.org/linus/009367099eb61a4fc2af44d4eb06b6b4de7de6db | https://git.kernel.org/linus/1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 | ubuntu |
</details>
二、漏洞分析结构反馈
影响性分析说明:
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1:- Usea default branch in the switch statement to initialize `val'.]GCC warns that `val' may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)){ case 1: val= *(const unsigned char *)p; break; case 2: val= *(const unsigned short *)p; break; case 4: val= *(const unsigned int *)p; break; case 8: val= *(const unsigned long long *)p; break;} [...]val;} This patch addsa default entry in the switch statement that sets`val' to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val'.]GCC warns that `val' may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...]val; } This patch adds a default entry in the switch statement that sets`val' to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
| linux | | https://git.kernel.org/linus/009367099eb61a4fc2af44d4eb06b6b4de7de6db | https://git.kernel.org/linus/1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 | ubuntu |
</details>
二、漏洞分析结构反馈
影响性分析说明:
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val'.]GCC warns that `val' may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...]val; } This patch adds a default entry in the switch statement that sets`val' to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
| linux | | https://git.kernel.org/linus/009367099eb61a4fc2af44d4eb06b6b4de7de6db | https://git.kernel.org/linus/1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 | ubuntu |
</details>
二、漏洞分析结构反馈
影响性分析说明:
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: -Use adefault branch in the switch statement to initialize `val'.]GCC warns that `val' may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) {case 1: val =*(const unsigned char *)p; break; case 2: val =*(const unsigned short *)p; break; case 4: val =*(const unsigned int *)p; break; case 8: val =*(const unsigned long long *)p; break; }[...]val; }This patch adds adefault entry in the switch statement that sets`val' to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
| linux | | https://git.kernel.org/linus/009367099eb61a4fc2af44d4eb06b6b4de7de6db | https://git.kernel.org/linus/1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 | ubuntu |
</details>
二、漏洞分析结构反馈
影响性分析说明:
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1:- Usea default branch in the switch statement to initialize `val'.]GCC warns that `val' may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)){ case 1: val= *(const unsigned char *)p; break; case 2: val= *(const unsigned short *)p; break; case 4: val= *(const unsigned int *)p; break; case 8: val= *(const unsigned long long *)p; break;} [...]val;} This patch addsa default entry in the switch statement that sets`val' to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
| linux | | https://git.kernel.org/linus/009367099eb61a4fc2af44d4eb06b6b4de7de6db | https://git.kernel.org/linus/1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 | ubuntu |
</details>
二、漏洞分析结构反馈
影响性分析说明:
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: -Use adefault branch in the switch statement to initialize `val'.]GCC warns that `val' may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) {case 1: val =*(const unsigned char *)p; break; case 2: val =*(const unsigned short *)p; break; case 4: val =*(const unsigned int *)p; break; case 8: val =*(const unsigned long long *)p; break; }[...]val; }This patch adds adefault entry in the switch statement that sets`val' to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
| linux | | https://git.kernel.org/linus/009367099eb61a4fc2af44d4eb06b6b4de7de6db | https://git.kernel.org/linus/1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 | ubuntu |
</details>
二、漏洞分析结构反馈
影响性分析说明:
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1:- Usea default branch in the switch statement to initialize `val'.]GCC warns that `val' may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)){ case 1: val= *(const unsigned char *)p; break; case 2: val= *(const unsigned short *)p; break; case 4: val= *(const unsigned int *)p; break; case 8: val= *(const unsigned long long *)p; break;} [...]val;} This patch addsa default entry in the switch statement that sets`val' to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
| linux | | https://git.kernel.org/linus/009367099eb61a4fc2af44d4eb06b6b4de7de6db | https://git.kernel.org/linus/1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 | ubuntu |
</details>
二、漏洞分析结构反馈
影响性分析说明:
In the Linuxkernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1:- Use adefault branch in the switch statement to initialize `val'.]GCC warns that `val' may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined inbpf_core_read.h as:[...]unsignedlonglong val; [...] switch(__CORE_RELO(s, field,BYTE_SIZE)){ case 1: val = *(const unsigned char*)p; break; case 2: val = *(const unsigned short*)p; break; case 4: val = *(const unsignedint*)p; break; case 8: val = *(const unsigned long long*)p;break; } [...]val; } This patch addsa default entry in the switch statement that sets`val'to zero in order to avoid thewarning, and randomvalues to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.The Linux kernel CVE team has assigned CVE-2024-42161 to this issue.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
| linux | | https://git.kernel.org/linus/009367099eb61a4fc2af44d4eb06b6b4de7de6db | https://git.kernel.org/linus/1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 | ubuntu |
</details>
二、漏洞分析结构反馈
影响性分析说明:
IntheLinux kernel,the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use adefaultbranch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.has:[...]unsigned long long val; [...] switch (__CORE_RELO(s,field, BYTE_SIZE)) { case 1:val=*(const unsigned char *)p; break; case 2: val=*(const unsigned short *)p; break; case 4: val=*(const unsigned int *)p; break; case 8: val=*(const unsigned long long *)p; break; }[...]val;} Thispatchaddsa default entryin the switch statement that sets`val to zero in order toavoid the warning, and randomvalues to beused incase __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
| linux | | https://git.kernel.org/linus/009367099eb61a4fc2af44d4eb06b6b4de7de6db | https://git.kernel.org/linus/1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 | ubuntu |
</details>
二、漏洞分析结构反馈
影响性分析说明:
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: -Use adefault branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) {case 1: val =*(const unsigned char *)p; break; case 2: val =*(const unsigned short *)p; break; case 4: val =*(const unsigned int *)p; break; case 8: val =*(const unsigned long long *)p; break; }[...]val; }This patch adds adefault entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
| linux | | https://git.kernel.org/linus/009367099eb61a4fc2af44d4eb06b6b4de7de6db | https://git.kernel.org/linus/ee26dade0e3bcd8a34ae7520e373fb69365fce7a | ubuntu |
</details>
二、漏洞分析结构反馈
影响性分析说明:
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1:- Usea default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)){ case 1: val= *(const unsigned char *)p; break; case 2: val= *(const unsigned short *)p; break; case 4: val= *(const unsigned int *)p; break; case 8: val= *(const unsigned long long *)p; break;} [...]val;} This patch addsa default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
| linux | | https://git.kernel.org/linus/009367099eb61a4fc2af44d4eb06b6b4de7de6db | https://git.kernel.org/linus/ee26dade0e3bcd8a34ae7520e373fb69365fce7a | ubuntu |
</details>
二、漏洞分析结构反馈
影响性分析说明:
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1:- Usea default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)){ case 1: val= *(const unsigned char *)p; break; case 2: val= *(const unsigned short *)p; break; case 4: val= *(const unsigned int *)p; break; case 8: val= *(const unsigned long long *)p; break;} [...]val;} This patch addsa default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
| linux | | https://git.kernel.org/linus/009367099eb61a4fc2af44d4eb06b6b4de7de6db | https://git.kernel.org/linus/ee26dade0e3bcd8a34ae7520e373fb69365fce7a | ubuntu |
</details>
二、漏洞分析结构反馈
影响性分析说明:
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: -Use adefault branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) {case 1: val =*(const unsigned char *)p; break; case 2: val =*(const unsigned short *)p; break; case 4: val =*(const unsigned int *)p; break; case 8: val =*(const unsigned long long *)p; break; }[...]val; }This patch adds adefault entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
| linux | | https://git.kernel.org/linus/009367099eb61a4fc2af44d4eb06b6b4de7de6db | https://git.kernel.org/linus/ee26dade0e3bcd8a34ae7520e373fb69365fce7a | ubuntu |
</details>
二、漏洞分析结构反馈
影响性分析说明:
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...]val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...] val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.
In the Linux kernel, the following vulnerability has been resolved:bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD[Changes from V1: - Use a default branch in the switch statement to initialize `val .]GCC warns that `val may be used uninitialized in theBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:[...]unsigned long long val; [...] switch (__CORE_RELO(s, field, BYTE_SIZE)) { case 1: val = *(const unsigned char *)p; break; case 2: val = *(const unsigned short *)p; break; case 4: val = *(const unsigned int *)p; break; case 8: val = *(const unsigned long long *)p; break; } [...]val; } This patch adds a default entry in the switch statement that sets`val to zero in order to avoid the warning, and random values to beused in case __builtin_preserve_field_info returns unexpected valuesfor BPF_FIELD_BYTE_SIZE.Tested in bpf-next master.No regressions.