In the Linux kernel, the following vulnerability has been resolved:
cifs: potential buffer overflow in handling symlinks
Smatch printed a warning: arch/x86/crypto/poly1305glue.c:198 poly1305updatearch() error: _memcpy() 'dctx->buf' too small (16 vs u32max)
It's caused because Smatch marks 'linklen' as untrusted since it comes from sscanf(). Add a check to ensure that 'linklen' is not larger than the size of the 'link_str' buffer.
[
{
"id": "CVE-2022-49058-00af2f59",
"signature_type": "Line",
"digest": {
"line_hashes": [
"117560962276064502672212643461901703830",
"33958893892367200388610516562690784253",
"46347160300901274397730344767047186072"
],
"threshold": 0.9
},
"signature_version": "v1",
"target": {
"file": "fs/cifs/link.c"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@64c4a37ac04eeb43c42d272f6e6c8c12bfcf4304",
"deprecated": false
},
{
"id": "CVE-2022-49058-10e485f1",
"signature_type": "Line",
"digest": {
"line_hashes": [
"117560962276064502672212643461901703830",
"33958893892367200388610516562690784253",
"46347160300901274397730344767047186072"
],
"threshold": 0.9
},
"signature_version": "v1",
"target": {
"file": "fs/cifs/link.c"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@22d658c6c5affed10c8907e67160cef0b6c92186",
"deprecated": false
},
{
"id": "CVE-2022-49058-4274cc34",
"signature_type": "Line",
"digest": {
"line_hashes": [
"117560962276064502672212643461901703830",
"33958893892367200388610516562690784253",
"46347160300901274397730344767047186072"
],
"threshold": 0.9
},
"signature_version": "v1",
"target": {
"file": "fs/cifs/link.c"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@1316c28569a80ab3596eeab05bf5e01991e7e739",
"deprecated": false
},
{
"id": "CVE-2022-49058-44a0d029",
"signature_type": "Function",
"digest": {
"length": 916.0,
"function_hash": "80375727582880453925384941295551277817"
},
"signature_version": "v1",
"target": {
"function": "parse_mf_symlink",
"file": "fs/cifs/link.c"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@22d658c6c5affed10c8907e67160cef0b6c92186",
"deprecated": false
},
{
"id": "CVE-2022-49058-5a78626a",
"signature_type": "Function",
"digest": {
"length": 916.0,
"function_hash": "80375727582880453925384941295551277817"
},
"signature_version": "v1",
"target": {
"function": "parse_mf_symlink",
"file": "fs/cifs/link.c"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@3e582749e742e662a8e9bb37cffac62dccaaa1e2",
"deprecated": false
},
{
"id": "CVE-2022-49058-68ed928e",
"signature_type": "Line",
"digest": {
"line_hashes": [
"117560962276064502672212643461901703830",
"33958893892367200388610516562690784253",
"46347160300901274397730344767047186072"
],
"threshold": 0.9
},
"signature_version": "v1",
"target": {
"file": "fs/cifs/link.c"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@4e166a41180be2f1e66bbb6d46448e80a9a5ec05",
"deprecated": false
},
{
"id": "CVE-2022-49058-7b1baa79",
"signature_type": "Function",
"digest": {
"length": 916.0,
"function_hash": "80375727582880453925384941295551277817"
},
"signature_version": "v1",
"target": {
"function": "parse_mf_symlink",
"file": "fs/cifs/link.c"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@515e7ba11ef043d6febe69389949c8ef5f25e9d0",
"deprecated": false
},
{
"id": "CVE-2022-49058-7b463a26",
"signature_type": "Line",
"digest": {
"line_hashes": [
"117560962276064502672212643461901703830",
"33958893892367200388610516562690784253",
"46347160300901274397730344767047186072"
],
"threshold": 0.9
},
"signature_version": "v1",
"target": {
"file": "fs/cifs/link.c"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@eb5f51756944735ac70cd8bb38637cc202e29c91",
"deprecated": false
},
{
"id": "CVE-2022-49058-8b765631",
"signature_type": "Function",
"digest": {
"length": 916.0,
"function_hash": "80375727582880453925384941295551277817"
},
"signature_version": "v1",
"target": {
"function": "parse_mf_symlink",
"file": "fs/cifs/link.c"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@eb5f51756944735ac70cd8bb38637cc202e29c91",
"deprecated": false
},
{
"id": "CVE-2022-49058-a1528474",
"signature_type": "Function",
"digest": {
"length": 916.0,
"function_hash": "80375727582880453925384941295551277817"
},
"signature_version": "v1",
"target": {
"function": "parse_mf_symlink",
"file": "fs/cifs/link.c"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@1316c28569a80ab3596eeab05bf5e01991e7e739",
"deprecated": false
},
{
"id": "CVE-2022-49058-a9ab1c1b",
"signature_type": "Line",
"digest": {
"line_hashes": [
"117560962276064502672212643461901703830",
"33958893892367200388610516562690784253",
"46347160300901274397730344767047186072"
],
"threshold": 0.9
},
"signature_version": "v1",
"target": {
"file": "fs/cifs/link.c"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@515e7ba11ef043d6febe69389949c8ef5f25e9d0",
"deprecated": false
},
{
"id": "CVE-2022-49058-b95cfece",
"signature_type": "Function",
"digest": {
"length": 916.0,
"function_hash": "80375727582880453925384941295551277817"
},
"signature_version": "v1",
"target": {
"function": "parse_mf_symlink",
"file": "fs/cifs/link.c"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@4e166a41180be2f1e66bbb6d46448e80a9a5ec05",
"deprecated": false
},
{
"id": "CVE-2022-49058-bc0f54e1",
"signature_type": "Line",
"digest": {
"line_hashes": [
"117560962276064502672212643461901703830",
"33958893892367200388610516562690784253",
"46347160300901274397730344767047186072"
],
"threshold": 0.9
},
"signature_version": "v1",
"target": {
"file": "fs/cifs/link.c"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@9901b07ba42b39266b34a888e48d7306fd707bee",
"deprecated": false
},
{
"id": "CVE-2022-49058-ddc1a377",
"signature_type": "Line",
"digest": {
"line_hashes": [
"117560962276064502672212643461901703830",
"33958893892367200388610516562690784253",
"46347160300901274397730344767047186072"
],
"threshold": 0.9
},
"signature_version": "v1",
"target": {
"file": "fs/cifs/link.c"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@3e582749e742e662a8e9bb37cffac62dccaaa1e2",
"deprecated": false
},
{
"id": "CVE-2022-49058-ed6714c8",
"signature_type": "Function",
"digest": {
"length": 916.0,
"function_hash": "80375727582880453925384941295551277817"
},
"signature_version": "v1",
"target": {
"function": "parse_mf_symlink",
"file": "fs/cifs/link.c"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@9901b07ba42b39266b34a888e48d7306fd707bee",
"deprecated": false
},
{
"id": "CVE-2022-49058-f4c71ddc",
"signature_type": "Function",
"digest": {
"length": 916.0,
"function_hash": "80375727582880453925384941295551277817"
},
"signature_version": "v1",
"target": {
"function": "parse_mf_symlink",
"file": "fs/cifs/link.c"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@64c4a37ac04eeb43c42d272f6e6c8c12bfcf4304",
"deprecated": false
}
]