{"id":51478,"date":"2026-04-03T14:14:42","date_gmt":"2026-04-03T18:14:42","guid":{"rendered":"https:\/\/mjtsai.com\/blog\/?p=51478"},"modified":"2026-04-13T11:40:27","modified_gmt":"2026-04-13T15:40:27","slug":"macos-26-4-paste-protection","status":"publish","type":"post","link":"https:\/\/mjtsai.com\/blog\/2026\/04\/03\/macos-26-4-paste-protection\/","title":{"rendered":"macOS 26.4 Paste Protection"},"content":{"rendered":"<p><a href=\"https:\/\/gist.github.com\/acodega\/6d63bf45a7ea89ac9f614e174ce0ecab\">Adam Codega<\/a>:<\/p>\n<blockquote cite=\"https:\/\/gist.github.com\/acodega\/6d63bf45a7ea89ac9f614e174ce0ecab\">\n<p>Apple does <strong>not<\/strong> inspect or analyze the contents of what you paste. Even harmless text like <code>\"hello world\"<\/code> will trigger the warning under the right conditions.<\/p>\n\n<p>Instead, Terminal checks <strong>where the clipboard content came from<\/strong>. It does this by calling a private API <code>_sourceSigningIdentifier<\/code> on the <code>NSPasteboard<\/code>, which reveals the code-signing identity of the application that placed the content on the clipboard.<\/p>\n\n<p>If the source app matches a predefined list (74 apps total), the paste may be flagged.<\/p>\n<\/blockquote>\n\n<p>Via <a href=\"https:\/\/mastodon.social\/@lapcatsoftware\/116301093073579122\">Jeff Johnson<\/a>:<\/p>\n<blockquote cite=\"https:\/\/mastodon.social\/@lapcatsoftware\/116301093073579122\">\n<p>The dialog is NOT displayed if Terminal app was opened within the last 30 days, or if developer tools are installed on the Mac.<\/p>\n<\/blockquote>\n\n<p><a href=\"https:\/\/leancrew.com\/all-this\/2026\/03\/saving-us-from-ourselves\/\">Dr. Drang<\/a>:<\/p>\n<blockquote cite=\"https:\/\/leancrew.com\/all-this\/2026\/03\/saving-us-from-ourselves\/\">\n<p>Surely, I thought, a command that pipes the contents of some random file on the internet into <code>bash<\/code> for execution would be worth warning about. Nope. I copied the <code>curl<\/code> command from Safari, pasted it into Terminal, and hit Return. No warning from macOS and my test folder and files disappeared again.<\/p>\n<p>My feelings about this have gone from &ldquo;I hope Apple doesn&rsquo;t make it impossible for me to work the way I normally do&rdquo; to &ldquo;Looks like Apple isn&rsquo;t going overboard on the protection&rdquo; to &ldquo;Is there any protection here at all?&rdquo;<\/p>\n<\/blockquote>\n\n<p><a href=\"https:\/\/objective-see.org\/blog\/blog_0x87.html\">Patrick Wardle<\/a>:<\/p>\n<blockquote cite=\"https:\/\/objective-see.org\/blog\/blog_0x87.html\">\n<p>You can read more about ClickFix attacks in MacPaw&rsquo;s Moonlock Labs write-up: &ldquo;<a href=\"https:\/\/moonlock.com\/clickfix-attack\">How ClickFix attacks trick users and infect devices with malware<\/a>&rdquo;<\/p>\n<p>[&#8230;]<\/p>\n<p>Long before macOS 26.4 (ok, like a month &#x1F604;), when Apple added native ClickFix protection, I had already added ClickFix protection to <a href=\"https:\/\/objective-see.org\/products\/blockblock.html\">BlockBlock<\/a>[&#8230;]<\/p>\n<p>[&#8230;]<\/p>\n<p>The reason Apple doesn&rsquo;t allow us to subscribe to these events&mdash;specifically <code>ES_EVENT_TYPE_RESERVED_1<\/code> (the paste event)&mdash;is that it&rsquo;s private, and thus only available to clients that possess the <code>com.apple.private.endpoint-security.client<\/code> entitlement.<\/p>\n<\/blockquote>\n\n<p>Previously:<\/p>\n<ul>\n<li><a href=\"https:\/\/mjtsai.com\/blog\/2026\/03\/25\/macos-26-4\/\">macOS 26.4<\/a><\/li>\n<li><a href=\"https:\/\/mjtsai.com\/blog\/2025\/09\/08\/fake-mac-apps-on-github\/\">Fake Mac Apps on GitHub<\/a><\/li>\n<li><a href=\"https:\/\/mjtsai.com\/blog\/2020\/04\/27\/blockblock-1-0\/\">BlockBlock 1.0<\/a><\/li>\n<\/ul>\n\n<p id=\"macos-26-4-paste-protection-update-2026-04-08\">Update (<a href=\"#macos-26-4-paste-protection-update-2026-04-08\">2026-04-08<\/a>): <a href=\"https:\/\/x.com\/malwarezoo\/status\/2037305551911014760\">Ferdous Saljooki<\/a>:<\/p>\n<blockquote cite=\"https:\/\/x.com\/malwarezoo\/status\/2037305551911014760\">\n<p>If you&rsquo;re looking to trigger this on a test machine running macOS 26.4:<\/p>\n<ol>\n<li><tt>\/Library\/Developer<\/tt> must not exist and no dev tools [including <a href=\"https:\/\/x.com\/malwarezoo\/status\/2037305564850503950\">non-Apple tools<\/a>] should be installed<\/li>\n<li><tt>\/var\/db\/.AppleSetupDone<\/tt> must be older than 24 hours. On a fresh install backdate it: <code>sudo touch -t 202603200000 \/var\/db\/.AppleSetupDone<\/code><\/li>\n<li>Clear Terminal&rsquo;s state: <code>defaults delete com.apple.Terminal LastTerminalStartTime<\/code> and <code>defaults delete com.apple.Terminal UserAcknowledgedPasteWarning<\/code><\/li>\n<li>Quit Terminal completely and relaunch<\/li>\n<li>Copy ANY text from Safari and paste into Terminal<\/li>\n<\/ol>\n<\/blockquote>\n\n<p id=\"macos-26-4-paste-protection-update-2026-04-13\">Update (<a href=\"#macos-26-4-paste-protection-update-2026-04-13\">2026-04-13<\/a>): <a href=\"https:\/\/eclecticlight.co\/2026\/04\/12\/last-week-on-my-mac-root-cause-analysis-and-clickfix\/\">Howard Oakley<\/a>:<\/p>\n<blockquote cite=\"https:\/\/eclecticlight.co\/2026\/04\/12\/last-week-on-my-mac-root-cause-analysis-and-clickfix\/\">\n<p>Although important, devising those defences is continuing the game of cat and mouse: no sooner are they in place than the attackers switch to a different ploy, as they have recently done by abusing a URL scheme and Script Editor. macOS offers a seemingly endless supply of mechanisms available for such abuse.<\/p>\n<p>What has largely escaped attention is how bizarre user behaviour has become. Here&rsquo;s a victim using a thoroughly GUI operating system copying what to them can only be incomprehensible gibberish and pasting it into Terminal, or running it in Script Editor. Why on earth would a user fall prey to that?<\/p>\n<p>[&#8230;]<\/p>\n<p>Over this period, tackling problems on Macs has moved from understanding how to use those GUI tools to blindly entering magic spells in Terminal, and now Script Editor. This trend has been promoted by search engines and most recently AI assistance, both of which are primarily text-based. Ask Google a Mac question, and the chances are you&rsquo;ll be presented with commands to paste in, rather than a well-written account of how to solve it in the GUI.<\/p>\n<\/blockquote>\n\n<p>I think Apple is also partly behind this change. GUI controls are increasingly absent, hidden, or in different places in different OS versions. Recommending a Terminal command can be simpler and more future-proof.<\/p>\n\n<p>Previously:<\/p>\n<ul>\n<li><a href=\"https:\/\/mjtsai.com\/blog\/2026\/04\/09\/clickfix-now-uses-script-editor-instead-of-terminal\/\">ClickFix Now Uses Script Editor Instead of Terminal<\/a><\/li>\n<\/ul>","protected":false},"excerpt":{"rendered":"<p>Adam Codega: Apple does not inspect or analyze the contents of what you paste. Even harmless text like \"hello world\" will trigger the warning under the right conditions. Instead, Terminal checks where the clipboard content came from. It does this by calling a private API _sourceSigningIdentifier on the NSPasteboard, which reveals the code-signing identity of [&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":"2026-04-03T18:14:45Z","apple_news_api_id":"6e4a5e69-00cd-4339-8da3-319180413739","apple_news_api_modified_at":"2026-04-13T15:40:31Z","apple_news_api_revision":"AAAAAAAAAAAAAAAAAAAAAg==","apple_news_api_share_url":"https:\/\/apple.news\/AbkpeaQDNQzmNozGRgEE3OQ","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":[1879,2018,30,2742,504,1670,48,318,226],"class_list":["post-51478","post","type-post","status-publish","format-standard","hentry","category-technology","tag-blockblock","tag-endpoint-security","tag-mac","tag-macos-tahoe-26","tag-malware","tag-pasteboard","tag-security","tag-terminal","tag-xcode"],"apple_news_notices":[],"_links":{"self":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts\/51478","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=51478"}],"version-history":[{"count":4,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts\/51478\/revisions"}],"predecessor-version":[{"id":51555,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts\/51478\/revisions\/51555"}],"wp:attachment":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/media?parent=51478"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/categories?post=51478"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/tags?post=51478"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}