{"id":"CVE-2022-31087","aliases":["DEBIAN-CVE-2022-31087","DSA-5177-1","EUVD-2022-52744","GHSA-q8g5-45m4-q95p","UBUNTU-CVE-2022-31087"],"status":"published","title":"Incorrect Default Permissions in ldap-account-manager","description":"LDAP Account Manager (LAM) is a webfrontend for managing entries (e.g. users, groups, DHCP settings) stored in an LDAP directory. In versions prior to 8.0 the tmp directory, which is accessible by /lam/tmp/, allows interpretation of .php (and .php5/.php4/.phpt/etc) files. An attacker capable of writing files under www-data privileges can write a web-shell into this directory, and gain a Code Execution on the host. This issue has been fixed in version 8.0. Users unable to upgrade should disallow executing PHP scripts in (/var/lib/ldap-account-manager/)tmp directory.","severity":{"version":"3.0","score":7.8,"vector":"CVSS:3.0/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","level":"high","assessor":"cna","from":"cve"},"epss":{"day":"2026-11-09","score":0.00439,"percentile":0.38427,"model":"v2026.06.15"},"facts":{"in_kev":false,"known_exploited":false,"public_exploit":false,"fix_available":true},"cwes":["CWE-74","CWE-863"],"published":"2022-06-27T20:50:11Z","modified":"2026-11-03T08:03:52Z","fixes":[{"ecosystem":"Debian:12","package":"ldap-account-manager","fixed_in":["8.0.1-1"],"sources":["osv"]},{"ecosystem":"Debian:13","package":"ldap-account-manager","fixed_in":["8.0.1-1"],"sources":["osv"]},{"ecosystem":"Debian:14","package":"ldap-account-manager","fixed_in":["8.0.1-1"],"sources":["osv"]}],"affected":[{"source":"osv","ecosystem":"Debian:12","package":"ldap-account-manager","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"8.0.1-1"}]}]},{"source":"osv","ecosystem":"Debian:13","package":"ldap-account-manager","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"8.0.1-1"}]}]},{"source":"osv","ecosystem":"Debian:14","package":"ldap-account-manager","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"8.0.1-1"}]}]},{"source":"osv","ecosystem":"Debian:11","package":"ldap-account-manager","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"8.0.1-0+deb11u1"}]}],"versions":["7.4-1","7.5-1","7.7-1","7.9-1","7.9.1-1"],"bundled":6},{"source":"osv","ecosystem":"Ubuntu:16.04:LTS","package":"ldap-account-manager","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["4.9-1","5.1-1","5.2-1","5.2-1ubuntu1"]},{"source":"osv","ecosystem":"Ubuntu:18.04:LTS","package":"ldap-account-manager","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["5.7-1","6.1-1","6.2-1"]},{"source":"osv","ecosystem":"Ubuntu:20.04:LTS","package":"ldap-account-manager","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["6.7-1"]},{"source":"osv","ecosystem":"Ubuntu:22.04:LTS","package":"ldap-account-manager","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["7.5-1","7.7-1"]},{"source":"osv","ecosystem":"Ubuntu:25.10","package":"ldap-account-manager","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["9.0-1"]},{"source":"osv","ecosystem":"Ubuntu:26.04:LTS","package":"ldap-account-manager","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["9.0-1","9.0-1build1"]}],"products":[{"vendor":"debian","product":"debian_linux"},{"vendor":"ldap-account-manager","product":"ldap_account_manager"},{"vendor":"ldapaccountmanager","product":"lam"}],"references":[{"url":"https://github.com/LDAPAccountManager/lam/commit/f1d5d04952f39a1b4ea203d3964fa88e1429dfd4","tags":["x_refsource_MISC","x_transferred","Patch","Third Party Advisory","fix","report"]},{"url":"https://github.com/LDAPAccountManager/lam/security/advisories/GHSA-q8g5-45m4-q95p","tags":["x_refsource_CONFIRM","x_transferred","Third Party Advisory","advisory","report"]},{"url":"https://www.debian.org/security/2022/dsa-5177","tags":["vendor-advisory","x_refsource_DEBIAN","x_transferred","Third Party Advisory","advisory"]},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2022/31xxx/CVE-2022-31087.json","tags":["advisory"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2022-31087","tags":["advisory"]},{"url":"https://security-tracker.debian.org/tracker/CVE-2022-31087","tags":["advisory"]},{"url":"https://ubuntu.com/security/CVE-2022-31087","tags":["report"]},{"url":"https://www.cve.org/CVERecord?id=CVE-2022-31087","tags":["report"]}],"sources":{"cve":[{"id":"CVE-2022-31087","title":"Incorrect Default Permissions in ldap-account-manager","description":"LDAP Account Manager (LAM) is a webfrontend for managing entries (e.g. users, groups, DHCP settings) stored in an LDAP directory. In versions prior to 8.0 the tmp directory, which is accessible by /lam/tmp/, allows interpretation of .php (and .php5/.php4/.phpt/etc) files. An attacker capable of writing files under www-data privileges can write a web-shell into this directory, and gain a Code Execution on the host. This issue has been fixed in version 8.0. Users unable to upgrade should disallow executing PHP scripts in (/var/lib/ldap-account-manager/)tmp directory.","status":"published","published":"2022-06-27T20:50:11Z","modified":"2025-04-23T18:07:18.371Z","cvss":[{"version":"3.0","score":7.8,"vector":"CVSS:3.0/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","level":"high","assessor":"cna"}],"cwes":["CWE-74"],"updated_at":"2026-11-02T14:34:35.279735Z"}],"euvd":[{"id":"EUVD-2022-52744","description":"LDAP Account Manager (LAM) is a webfrontend for managing entries (e.g. users, groups, DHCP settings) stored in an LDAP directory. In versions prior to 8.0 the tmp directory, which is accessible by /lam/tmp/, allows interpretation of .php (and .php5/.php4/.phpt/etc) files. An attacker capable of writing files under www-data privileges can write a web-shell into this directory, and gain a Code Execution on the host. This issue has been fixed in version 8.0. Users unable to upgrade should disallow executing PHP scripts in (/var/lib/ldap-account-manager/)tmp directory.","status":"published","published":"2022-06-27T20:50:11Z","modified":"2025-04-23T18:07:18Z","cvss":[{"version":"3.0","score":7.8,"vector":"CVSS:3.0/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","level":"high"}],"updated_at":"2026-11-02T20:52:09.387599Z"}],"nvd":[{"id":"CVE-2022-31087","description":"LDAP Account Manager (LAM) is a webfrontend for managing entries (e.g. users, groups, DHCP settings) stored in an LDAP directory. In versions prior to 8.0 the tmp directory, which is accessible by /lam/tmp/, allows interpretation of .php (and .php5/.php4/.phpt/etc) files. An attacker capable of writing files under www-data privileges can write a web-shell into this directory, and gain a Code Execution on the host. This issue has been fixed in version 8.0. Users unable to upgrade should disallow executing PHP scripts in (/var/lib/ldap-account-manager/)tmp directory.","status":"published","published":"2022-06-27T21:15:08.337Z","modified":"2026-06-17T04:44:46.16Z","cvss":[{"version":"3.1","score":7.8,"vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","level":"high","assessor":"primary"},{"version":"3.0","score":7.8,"vector":"CVSS:3.0/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","level":"high","assessor":"secondary"},{"version":"2.0","score":7.2,"vector":"AV:L/AC:L/Au:N/C:C/I:C/A:C","level":"high","assessor":"primary"}],"cwes":["CWE-74","CWE-863"],"updated_at":"2026-11-02T14:07:22.613788Z"}],"osv":[{"id":"CVE-2022-31087","title":"Incorrect Default Permissions in ldap-account-manager","description":"LDAP Account Manager (LAM) is a webfrontend for managing entries (e.g. users, groups, DHCP settings) stored in an LDAP directory. In versions prior to 8.0 the tmp directory, which is accessible by /lam/tmp/, allows interpretation of .php (and .php5/.php4/.phpt/etc) files. An attacker capable of writing files under www-data privileges can write a web-shell into this directory, and gain a Code Execution on the host. This issue has been fixed in version 8.0. Users unable to upgrade should disallow executing PHP scripts in (/var/lib/ldap-account-manager/)tmp directory.","status":"published","published":"2022-06-27T20:50:11Z","modified":"2026-10-28T02:30:31.262322708Z","cvss":[{"version":"3.0","score":7.8,"vector":"CVSS:3.0/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","level":"high"}],"cwes":["CWE-74"],"updated_at":"2026-11-02T15:44:25.516981Z"},{"id":"DEBIAN-CVE-2022-31087","description":"LDAP Account Manager (LAM) is a webfrontend for managing entries (e.g. users, groups, DHCP settings) stored in an LDAP directory. In versions prior to 8.0 the tmp directory, which is accessible by /lam/tmp/, allows interpretation of .php (and .php5/.php4/.phpt/etc) files. An attacker capable of writing files under www-data privileges can write a web-shell into this directory, and gain a Code Execution on the host. This issue has been fixed in version 8.0. Users unable to upgrade should disallow executing PHP scripts in (/var/lib/ldap-account-manager/)tmp directory.","status":"published","published":"2022-06-27T21:15:08.337Z","modified":"2026-11-03T08:03:52.390440198Z","cvss":[{"version":"3.1","score":7.8,"vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","level":"high"}],"updated_at":"2026-11-03T08:23:57.167851Z"},{"id":"UBUNTU-CVE-2022-31087","description":"LDAP Account Manager (LAM) is a webfrontend for managing entries (e.g. users, groups, DHCP settings) stored in an LDAP directory. In versions prior to 8.0 the tmp directory, which is accessible by /lam/tmp/, allows interpretation of .php (and .php5/.php4/.phpt/etc) files. An attacker capable of writing files under www-data privileges can write a web-shell into this directory, and gain a Code Execution on the host. This issue has been fixed in version 8.0. Users unable to upgrade should disallow executing PHP scripts in (/var/lib/ldap-account-manager/)tmp directory.","status":"published","published":"2022-06-27T21:15:00Z","modified":"2026-05-20T16:08:04.133825655Z","cvss":[{"version":"3.0","score":7.8,"vector":"CVSS:3.0/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","level":"high"},{"version":"3.1","score":7.8,"vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","level":"high"}],"updated_at":"2026-11-02T16:53:53.899276Z"},{"id":"DSA-5177-1","title":"ldap-account-manager - security update","status":"published","published":"2022-07-05T00:00:00Z","modified":"2026-03-09T02:09:25.039125Z","updated_at":"2026-11-02T15:46:17.543497Z"}]}}
