The auditselect command is part of the audit subsystem. The command is called by the auditbin daemon if it is configured in the /etc/security/audit/bincmds file as a backend command for processing bin files.
The auditselect command selects audit records that match identified criteria and writes the records to standard output. With the auditselect command, you can filter the audit trail to obtain specific records for analysis or select specific records for long-term storage. The command takes stream or bin input from the file specified by the Trail parameter or from standard input. If you specify the $bin string as the value of the Trail parameter, the auditbin daemon substitutes the path name of the current bin file when it calls the auditselect command. The selection criteria can be entered as an expression or from the file specified by the -f flag. If the bin files are compressed, the auditselect command unpacks them prior to processing.
There is a format string vulnerability within the auditselect command due to the way it uses formatted output routines, such as printf(). The auditselect command may pass formatted output routines user-supplied data. If a local attacker with audit group membership passes a specially crafted parameter to auditselect, that parameter may be passed to a formatted output routine. Since output routines in auditselect do not adequately filter or restrict input (via a format string specifier), the attacker may be able to exploit this vulnerability.
Please note that the auditselect command executes with root privileges.
Impact
By supplying auditselectspecially crafted input, a local attacker with membership in the audit group may be able to execute arbitrary code with root privileges.
Solution
We are currently unaware of a practical solution to this problem.
Workaround
Restrict Access to Audit Group
To successfully exploit this vulnerability an attacker must have access to the audit group. By restricting membership to the audit group to trusted users, the chances of exploitation are reduced.
Systems Affected
Vendor| Status| Date Notified| Date Updated
---|---|---|---
IBM| | 28 Feb 2005| 28 Feb 2005
If you are a vendor and your product is affected, let us know.
{"viewCount": 0, "id": "VU:896729", "hash": "fe56c5ad6d9cb5d2087fdf32f82bca9dcf1932be8b68b4651ce3a769210a4a6f", "cvss": {"score": 7.2, "vector": "AV:LOCAL/AC:LOW/Au:NONE/C:COMPLETE/I:COMPLETE/A:COMPLETE/"}, "href": "https://www.kb.cert.org/vuls/id/896729", "history": [], "edition": 1, "references": ["http://web.nvd.nist.gov/view/vuln/detail?vulnId=CAN-2005-0250", "http://www-1.ibm.com/support/docview.wss?uid=isg1IY67519", "http://www.securiteam.com/unixfocus/5OP0G15EUU.html", "http://www.idefense.com", "http://publib.boulder.ibm.com/infocenter/pseries/topic/com.ibm.aix.doc/cmds/aixcmds1/auditselect.htm#a163c11674", "http://publib.boulder.ibm.com/infocenter/pseries/index.jsp?topic=/com.ibm.aix.doc/cmds/aixcmds1/auditselect.htm", "http://secunia.com/advisories/14198/", "http://www.idefense.com/application/poi/display?id=193&type=vulnerabilities", "http://publib.boulder.ibm.com/infocenter/pseries/topic/com.ibm.aix.doc/cmds/aixcmds1/auditselect.htm#a163c11675", "http://publib.boulder.ibm.com/infocenter/pseries/topic/com.ibm.aix.doc/cmds/aixcmds1/auditselect.htm#auditselectflagm"], "cvelist": ["CVE-2005-0250", "CVE-2005-0250"], "description": "### Overview\n\nIBM AIX `auditselect` command contains a format string vulnerability that may allow a local attacker to execute arbitrary code.\n\n### Description\n\nAccording to [IBM's Command Reference](<http://publib.boulder.ibm.com/infocenter/pseries/index.jsp?topic=/com.ibm.aix.doc/cmds/aixcmds1/auditselect.htm>), the syntax and description of the `auditselect` command are as follows: \n\n`$> auditselect { `[`-e`](<http://publib.boulder.ibm.com/infocenter/pseries/topic/com.ibm.aix.doc/cmds/aixcmds1/auditselect.htm#a163c11674>)` \"Expression\" | `[`-f`](<http://publib.boulder.ibm.com/infocenter/pseries/topic/com.ibm.aix.doc/cmds/aixcmds1/auditselect.htm#a163c11675>)` File} [ `[`-m`](<http://publib.boulder.ibm.com/infocenter/pseries/topic/com.ibm.aix.doc/cmds/aixcmds1/auditselect.htm#auditselectflagm>)` ] [ Trail ] ` \n \n`The auditselect command is part of the audit subsystem. The command is called by the auditbin daemon if it is configured in the /etc/security/audit/bincmds file as a backend command for processing bin files.`\n\n`The auditselect command selects audit records that match identified criteria and writes the records to standard output. With the auditselect command, you can filter the audit trail to obtain specific records for analysis or select specific records for long-term storage. The command takes stream or bin input from the file specified by the Trail parameter or from standard input. If you specify the $bin string as the value of the Trail parameter, the auditbin daemon substitutes the path name of the current bin file when it calls the auditselect command. The selection criteria can be entered as an expression or from the file specified by the -f flag. If the bin files are compressed, the auditselect command unpacks them prior to processing.`\n\n \nThere is a format string vulnerability within the `auditselect` command due to the way it uses formatted output routines, such as `printf()`. The `auditselect` command may pass formatted output routines user-supplied data. If a local attacker with audit group membership passes a specially crafted parameter to `auditselect`, that parameter may be passed to a formatted output routine. Since output routines in `auditselect` do not adequately filter or restrict input (via a format string specifier), the attacker may be able to exploit this vulnerability. \n \nPlease note that the `auditselect` command executes with `root` privileges. \n \n--- \n \n### Impact\n\nBy supplying `auditselect `specially crafted input, a local attacker with membership in the audit group may be able to execute arbitrary code with `root` privileges. \n \n--- \n \n### Solution\n\nWe are currently unaware of a practical solution to this problem. \n \n--- \n \n**Workaround** \n \n**Restrict Access to Audit Group** \n \nTo successfully exploit this vulnerability an attacker must have access to the audit group. By restricting membership to the audit group to trusted users, the chances of exploitation are reduced. \n \n--- \n \n### Systems Affected \n\nVendor| Status| Date Notified| Date Updated \n---|---|---|--- \nIBM| | 28 Feb 2005| 28 Feb 2005 \nIf you are a vendor and your product is affected, [let us know](<mailto:cert@cert.org?Subject=VU%23896729 Vendor Status Inquiry>).\n\n### CVSS Metrics \n\nGroup | Score | Vector \n---|---|--- \nBase | N/A | N/A \nTemporal | N/A | N/A \nEnvironmental | N/A | N/A \n \n### References\n\n * <http://www-1.ibm.com/support/docview.wss?uid=isg1IY67519>\n * [http://www.idefense.com/application/poi/display?id=193&type;=vulnerabilities](<http://www.idefense.com/application/poi/display?id=193&type=vulnerabilities>)\n * <http://www.securiteam.com/unixfocus/5OP0G15EUU.html>\n * <http://secunia.com/advisories/14198/>\n\n### Credit\n\nThis vulnerability was reported by [iDEFENSE Security](<http://www.idefense.com>).\n\nThis document was written by Jeff Gennari.\n\n### Other Information\n\n * CVE IDs: [CAN-2005-0250](<http://web.nvd.nist.gov/view/vuln/detail?vulnId=CAN-2005-0250>)\n * Date Public: 08 Feb 2005\n * Date First Published: 28 Feb 2005\n * Date Last Updated: 28 Feb 2005\n * Severity Metric: 1.01\n * Document Revision: 75\n\n", "modified": "2005-02-28T00:00:00", "lastseen": "2016-02-03T09:12:06", "bulletinFamily": "info", "title": "IBM AIX auditselect contains format string vulnerability", "objectVersion": "1.2", "reporter": "CERT", "type": "cert", "published": "2005-02-28T00:00:00", "enchantments": {"vulnersScore": 5.4}}
{"result": {"cve": [{"id": "CVE-2005-0250", "type": "cve", "title": "CVE-2005-0250", "description": "Format string vulnerability in auditselect on IBM AIX 5.1, 5.2, and 5.3 allows local users to execute arbitrary code via format string specifiers in a command line argument.", "published": "2005-05-02T00:00:00", "cvss": {"score": 7.2, "vector": "AV:LOCAL/AC:LOW/Au:NONE/C:COMPLETE/I:COMPLETE/A:COMPLETE/"}, "href": "https://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2005-0250", "cvelist": ["CVE-2005-0250"], "lastseen": "2017-07-11T11:14:46"}], "osvdb": [{"id": "OSVDB:13638", "type": "osvdb", "title": "AIX auditselect Format String Local Privilege Escalation", "description": "# No description provided by the source\n\n## References:\n[Vendor Specific Advisory URL](http://archives.neohapsis.com/archives/bugtraq/2005-02/0083.html)\n[Vendor Specific Advisory URL](http://www.ibm.com/support/docview.wss?uid=isg1IY67519)\nSecurity Tracker: 1013103\n[Secunia Advisory ID:14198](https://secuniaresearch.flexerasoftware.com/advisories/14198/)\nOther Advisory URL: http://www.idefense.com/application/poi/display?id=193&type=vulnerabilities\nMail List Post: http://archives.neohapsis.com/archives/fulldisclosure/2005-02/0079.html\n[CVE-2005-0250](https://vulners.com/cve/CVE-2005-0250)\n", "published": "2005-02-08T03:39:32", "cvss": {"score": 7.2, "vector": "AV:LOCAL/AC:LOW/Au:NONE/C:COMPLETE/I:COMPLETE/A:COMPLETE/"}, "href": "https://vulners.com/osvdb/OSVDB:13638", "cvelist": ["CVE-2005-0250"], "lastseen": "2017-04-28T13:20:09"}]}}