{"id":36619,"date":"2022-07-28T16:37:05","date_gmt":"2022-07-28T20:37:05","guid":{"rendered":"https:\/\/mjtsai.com\/blog\/?p=36619"},"modified":"2023-12-06T14:21:34","modified_gmt":"2023-12-06T19:21:34","slug":"packagekit-sip-bypass","status":"publish","type":"post","link":"https:\/\/mjtsai.com\/blog\/2022\/07\/28\/packagekit-sip-bypass\/","title":{"rendered":"PackageKit SIP Bypass"},"content":{"rendered":"<p><a href=\"https:\/\/jhftss.github.io\/CVE-2022-26712-The-POC-For-SIP-Bypass-Is-Even-Tweetable\/\">Mickey Jin<\/a> (<a href=\"https:\/\/twitter.com\/patch1t\/status\/1551931287203717120\">tweet<\/a>):<\/p>\n<blockquote cite=\"https:\/\/jhftss.github.io\/CVE-2022-26712-The-POC-For-SIP-Bypass-Is-Even-Tweetable\/\"><p>I found some new attack surfaces in the macOS PackageKit.framework, and successfully disclosed 15+ critical SIP-Bypass vulnerabilities. Apple has addressed 12 of them <a href=\"https:\/\/jhftss.github.io\/cvelist\/\">with CVE assigned<\/a> so far.<\/p>\n<p>[&#8230;]<\/p>\n<p>Moreover, an attacker could get arbitrary kernel code execution with the SIP-Bypass primitive. I did find a new way to do this on the macOS Monterey, but I couldn&rsquo;t share the exploit here right now, because it is related to another unpatched 0-day.<\/p>\n<p>[&#8230;]<\/p>\n<p>The service provides only one method to shove files from one place to another place[&#8230;] However, there is no check for the incoming clients, and any process can fire the XPC request to the service. Therefore, we can abuse the service to bypass the SIP restriction.<\/p><\/blockquote>\n<p>And another issue:<\/p>\n<blockquote cite=\"https:\/\/jhftss.github.io\/CVE-2022-26712-The-POC-For-SIP-Bypass-Is-Even-Tweetable\/\"><p>In short, the system command <code>\/usr\/libexec\/configd<\/code> has a special TCC entitlement: <code>kTCCServiceSystemPolicySysAdminFiles<\/code>, which grants the command permission to change a user&rsquo;s home directory and forge the user&rsquo;s database file <tt>TCC.db<\/tt>. An attacker could inject a malicious dylib into the process to enjoy the special TCC permission.<\/p><\/blockquote>\n\n<p>Previously:<\/p>\n<ul>\n<li><a href=\"https:\/\/mjtsai.com\/blog\/2021\/07\/13\/overview-of-tcc-bypasses-by-accident-and-design\/\">Overview of TCC Bypasses by Accident and Design<\/a><\/li>\n<li><a href=\"https:\/\/mjtsai.com\/blog\/2019\/09\/02\/privilegedhelpertools-and-checking-xpc-peers\/\">PrivilegedHelperTools and Checking XPC Peers<\/a><\/li>\n<\/ul>","protected":false},"excerpt":{"rendered":"<p>Mickey Jin (tweet): I found some new attack surfaces in the macOS PackageKit.framework, and successfully disclosed 15+ critical SIP-Bypass vulnerabilities. Apple has addressed 12 of them with CVE assigned so far. [&#8230;] Moreover, an attacker could get arbitrary kernel code execution with the SIP-Bypass primitive. I did find a new way to do this on [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"apple_news_api_created_at":"2022-07-28T20:37:08Z","apple_news_api_id":"86e9c7f1-8128-45ee-9912-091933ea60c9","apple_news_api_modified_at":"2023-12-06T19:21:37Z","apple_news_api_revision":"AAAAAAAAAAAAAAAAAAAAAA==","apple_news_api_share_url":"https:\/\/apple.news\/AhunH8YEoRe6ZEgkZM-pgyQ","apple_news_coverimage":0,"apple_news_coverimage_caption":"","apple_news_is_hidden":false,"apple_news_is_paid":false,"apple_news_is_preview":false,"apple_news_is_sponsored":false,"apple_news_maturity_rating":"","apple_news_metadata":"\"\"","apple_news_pullquote":"","apple_news_pullquote_position":"","apple_news_slug":"","apple_news_sections":"\"\"","apple_news_suppress_video_url":false,"apple_news_use_image_component":false,"footnotes":""},"categories":[2],"tags":[131,2518,2095,30,2077,48,1235,1960,1473],"class_list":["post-36619","post","type-post","status-publish","format-standard","hentry","category-technology","tag-bug","tag-entitlements","tag-exploit","tag-mac","tag-macos-12","tag-security","tag-system-integrity-protection","tag-transparency-consent-and-control-tcc","tag-xpc"],"apple_news_notices":[],"_links":{"self":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts\/36619","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/comments?post=36619"}],"version-history":[{"count":1,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts\/36619\/revisions"}],"predecessor-version":[{"id":36620,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts\/36619\/revisions\/36620"}],"wp:attachment":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/media?parent=36619"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/categories?post=36619"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/tags?post=36619"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}