<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	xmlns:media="http://search.yahoo.com/mrss/"
>

<channel>
	<title>Full Disk Access &#8211; Wade Tregaskis</title>
	<atom:link href="https://wadetregaskis.com/tags/full-disk-access/feed/" rel="self" type="application/rss+xml" />
	<link>https://wadetregaskis.com</link>
	<description></description>
	<lastBuildDate>Sun, 31 Dec 2023 23:19:29 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	

<image>
	<url>https://wadetregaskis.com/wp-content/uploads/2016/03/Stitch-512x512-1-256x256.png</url>
	<title>Full Disk Access &#8211; Wade Tregaskis</title>
	<link>https://wadetregaskis.com</link>
	<width>32</width>
	<height>32</height>
</image> 
<site xmlns="com-wordpress:feed-additions:1">226351702</site>	<item>
		<title>Full Disk Access is required to access Time Machine backups in Mojave</title>
		<link>https://wadetregaskis.com/full-disk-access-is-required-to-access-time-machine-backups-in-mojave/</link>
					<comments>https://wadetregaskis.com/full-disk-access-is-required-to-access-time-machine-backups-in-mojave/#respond</comments>
		
		<dc:creator><![CDATA[]]></dc:creator>
		<pubDate>Thu, 27 Dec 2018 17:51:51 +0000</pubDate>
				<category><![CDATA[Howto]]></category>
		<category><![CDATA[Broken by design]]></category>
		<category><![CDATA[Finder]]></category>
		<category><![CDATA[Full Disk Access]]></category>
		<category><![CDATA[Mojave]]></category>
		<category><![CDATA[Security]]></category>
		<category><![CDATA[Snafu]]></category>
		<category><![CDATA[System Integrity Protection]]></category>
		<category><![CDATA[Terminal]]></category>
		<category><![CDATA[Time Machine]]></category>
		<guid isPermaLink="false">https://blog.wadetregaskis.com/?p=4314</guid>

					<description><![CDATA[I&#8217;ve been struggling since Mojave came out to deal with it&#8217;s over-bearing expansion of SIP (&#8220;System Integrity Protection&#8221;), which is basically a super-root notion that blocks access &#8211; even to root &#8211; to lots of basic parts of the system, including obvious &#38; mostly sensible ones like /System and /Library, but also less usefully things&#8230; <a class="read-more-link" href="https://wadetregaskis.com/full-disk-access-is-required-to-access-time-machine-backups-in-mojave/" data-wpel-link="internal">Read more</a>]]></description>
										<content:encoded><![CDATA[
<p>I&#8217;ve been struggling since Mojave came out to deal with it&#8217;s over-bearing expansion of SIP (&#8220;System Integrity Protection&#8221;), which is basically a super-root notion that blocks access &#8211; even to root &#8211; to lots of basic parts of the system, including obvious &amp; mostly sensible ones like /System and /Library, but also less usefully things like any &amp; all Time Machine backups.</p>



<p>Blocking access to Time Machine makes it very difficult to actually use Time Machine, since it&#8217;s then difficult to retrieve files from a backup (you <em>have</em> to then use the stupid &#8216;warp&#8217; Time Machine interface, which is slow, ugly, and buggy).</p>



<p>Luckily, it turns out there is a fairly simple solution that <em>isn&#8217;t</em> disabling SIP entirely (which requires multiple reboots in order to do, so is typically quite disruptive &amp; slow).  It appears that any application granted Full Disk Access (System Preferences → Security &amp; Privacy → Full Disk Access) can read Time Machine backups.</p>



<p>In case you&#8217;re unfamiliar, the symptoms of this problem include:</p>



<ul class="wp-block-list"><li>Being unable to navigate into Time Machine backups in the Open / Save / etc dialogs.</li><li>Being unable to see &#8211; through <font face="menlo">ls</font> or similar tools &#8211; the contents of Time Machine backups via Terminal.</li><li>Apps reporting errors like &#8220;<font face="menlo">The file “Foo” couldn’t be opened because you don’t have permission to view it</font>&#8221; or bluntly &#8220;<font face="menlo">Operation not permitted</font>&#8221; when trying to read something in a Time Machine backup.</li></ul>



<p>There&#8217;s a strange &amp; ironically very bad security quirk though &#8211; curiously, any tools run via Terminal inherit Terminal&#8217;s access (or lack thereof) to Full Disk Access.  They <em>don&#8217;t</em> use whatever setting might be specified for them in the Security &amp; Privacy preferences.  This is pretty baffling, as it means to give Full Disk Access to <em>anything</em> you run via Terminal, you have to give it to <em>everything</em> you run via Terminal.  Anything you specifically give Full Disk Access won&#8217;t actually receive it if it happens to be launched via the Terminal (which confused me for a while, since it&#8217;s so unintuitive).</p>



<p>I&#8217;m guessing whatever mechanism enforces all this so-called security is based in LaunchServices or somesuch &#8211; while the Finder and most things in general will launch apps via LaunchServices, as detached &amp; independent process sessions, Terminal doesn&#8217;t &#8211; everything it runs, from the shells down, run under it in the process hierarchy, and seemingly share its security &amp; privacy settings.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://wadetregaskis.com/full-disk-access-is-required-to-access-time-machine-backups-in-mojave/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">4314</post-id>	</item>
		<item>
		<title>tmutil is broken by SIP in Mojave</title>
		<link>https://wadetregaskis.com/tmutil-is-broken-by-sip-in-mojave/</link>
					<comments>https://wadetregaskis.com/tmutil-is-broken-by-sip-in-mojave/#respond</comments>
		
		<dc:creator><![CDATA[]]></dc:creator>
		<pubDate>Sun, 07 Oct 2018 22:57:31 +0000</pubDate>
				<category><![CDATA[Howto]]></category>
		<category><![CDATA[Bugs!]]></category>
		<category><![CDATA[Disk Utility]]></category>
		<category><![CDATA[diskutil]]></category>
		<category><![CDATA[Full Disk Access]]></category>
		<category><![CDATA[macOS]]></category>
		<category><![CDATA[Mojave]]></category>
		<category><![CDATA[SIP]]></category>
		<category><![CDATA[Time Machine]]></category>
		<category><![CDATA[tmutil]]></category>
		<guid isPermaLink="false">https://blog.wadetregaskis.com/?p=4231</guid>

					<description><![CDATA[A diskutil bug unceremoniously erased an entire hard drive of mine a few weeks back. &#160;While I was able to successfully (AFAICT) restore the drive&#8217;s contents to it from various backups, the erasure gave the drive a new identity (UUID, specifically). &#160;The next time Time Machine ran, it compounded the diskutil bug by also unceremoniously&#8230; <a class="read-more-link" href="https://wadetregaskis.com/tmutil-is-broken-by-sip-in-mojave/" data-wpel-link="internal">Read more</a>]]></description>
										<content:encoded><![CDATA[
<p>A diskutil bug unceremoniously erased an entire hard drive of mine a few weeks back. &nbsp;While I was able to successfully (AFAICT) restore the drive&#8217;s contents to it from various backups, the erasure gave the drive a new identity (UUID, specifically). &nbsp;The next time Time Machine ran, it compounded the diskutil bug by also unceremoniously deleting all my old backups (bar one, the latest), because it didn&#8217;t recognise the new drive with identical contents to the old drive as being the same drive, and tried to back it up again, requiring way more space, causing all existing backups to be purged, etc.</p>



<p>Sigh.</p>



<p>It turns out there&#8217;s actually a nominally supported way to address exactly this scenario &#8211; <code>tmutil associatedisk</code> (kudos to <a href="https://simon.heimlicher.com/technology/time-machine-inherit-backup-using-tmutil/" data-wpel-link="external" target="_blank" rel="external noopener">Simon Heimlicher for documenting this</a>).  From the man page:</p>



<pre class="wp-block-preformatted">   <strong>associatedisk</strong> [-a] <span style="text-decoration: underline;">mount_point</span> <span style="text-decoration: underline;">snapshot_volume</span>
           Bind a snapshot volume directory to the specified local disk, thereby reconfigur-
           ing the backup history. Requires root privileges.


           In Mac OS X, HFS+ volumes have a persistent UUID that is assigned when the file
           system is created. Time Machine uses this identifier to make an association
           between a source volume and a snapshot volume. Erasing the source volume creates
           a new file system on the disk, and the previous UUID is not retained. The new
           UUID causes the source volume -> snapshot volume association to be broken. If one
           were just erasing the volume and starting over, it would likely be of no real
           consequence, and the new UUID would not be a concern; when erasing a volume in
           order to clone another volume to it, recreating the association may be desired.


           A concrete example of when and how you would use associatedisk:


           After having problems with a volume, you decide to erase it and manually restore
           its contents from a Time Machine backup or copy of another nature. (I.e., not via
           Time Machine System Restore or Migration Assistant.) On your next incremental
           backup, the data will be copied anew, as though none of it had been backed up
           before. Technically, it is true that the data has not been backed up, given the
           new UUID. However, this is probably not what you want Time Machine to do. You
           would then use associatedisk to reconfigure the backup so it appears that this
           volume has been backed up previously:


           thermopylae:~ thoth$ sudo tmutil associatedisk [-a] "/Volumes/MyNewStuffDisk"
           "/Volumes/Chronoton/Backups.backupdb/thermopylae/Latest/MyStuff"


           The result of the above command would associate the snapshot volume <span style="text-decoration: underline;">MyStuff</span> in
           the specified snapshot with the source volume <span style="text-decoration: underline;">MyNewStuffDisk</span>. The snapshot volume
           would also be renamed to match. The -a option tells associatedisk to find all
           snapshot volumes in the same machine directory that match the identity of
           <span style="text-decoration: underline;">MyStuff</span>, and then perform the association on all of them.
</pre>



<p>Perfect &#8211; and I particularly like the subtext of the prose, which seems to be a subtle acknowledgment that this is a thing that happens frequently, and that macOS&#8217;s default behaviour is stupid… &#8220;recreating the association may be desired&#8221;. &nbsp;No shit.</p>



<p>Unfortunately, that command doesn&#8217;t work in Mojave. &nbsp;I&#8217;m apparently not <a href="https://forums.macrumors.com/threads/unable-to-inherit-previous-time-machine.2144061/" data-wpel-link="external" target="_blank" rel="external noopener">the first person to notice</a>.</p>



<p>It appears the tightened security, and in particular expansion of SIP to cover many more parts of the system including Time Machine backups, are to blame. &nbsp;Even granting <code>tmutil</code> Full Disk Access etc in the system security settings is of no use (contrary to the stated purpose of Full Disk Access).</p>



<p>So you have to <a href="https://iboysoft.com/howto/disable-system-integrity-protection-macos.html" data-wpel-link="external" target="_blank" rel="external noopener">disable SIP first</a> &#8211; which requires a reboot, obnoxiously &#8211; and only then does <code>tmutil</code> work again. &nbsp;You&#8217;ll want to enable SIP again once you&#8217;re done, most likely, as the protections it provides are useful &#8211; it appears <code>tmutil</code> nve eeds to be updated to account for the new protections.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://wadetregaskis.com/tmutil-is-broken-by-sip-in-mojave/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">4231</post-id>	</item>
	</channel>
</rss>
