💓 EV∆ ∆ΠΠ∆ 💓<p>🐘 Mastodon Account Archives 🐘</p><p>TL;DR Sometimes mastodon account backup archive downloads fail to download via browser, but will do so via fetch with some flags in the terminal. YMMV.</p><p>the following are notes from recent efforts to get around browser errors while downloading an account archive link. </p><p>yes, surely most will not encounter this issue, and that's fine. there's no need to add a "works fine for me", so this does not apply to your situation, and that's fine too. however, if one does encounter browser errors (there were several unique ones and I don't feel like finding them in the logs). </p><p>moving on... some experimentation with discarding the majority of the URL's dynamic parameters, I have it working on the cli as follows:</p><p>» \fetch -4 -A -a -F -R -r --buffer-size=512384 --no-tlsv1 -v ${URL_PRE_QMARK}?X-Amz-Algorithm=AWS4-HMAC-SHA256</p><p>the primary download URL (everything before the query initiator "?" has been substituted as ${URL_PRE_QMARK}, and then I only included Amazon's algo params, the rest of the URL (especially including the "expire" tag) seems to be unnecessary. </p><p>IIRC the reasoning there is about the CDN's method for defaulting to a computationally inexpensive front-line cache management, where the expire aspects are embedded in the URL instead of internal (to the CDN clusters) metrics lookups for cache expiration.</p><p>shorter version: dropping all of the params except the hash algo will initiate a fresh zero-cached hit at the edge, though likely that has been cached on second/non-edge layer due to my incessent requests after giving up on the browser downloads. </p><p>increasing the buffer size and forcing ipv4 are helpful for some manner of firewall rules that are on my router side, which may or may not be of benefit to others.</p><p>- Archive directory aspect of URL: https://${SERVER}/${MASTO_DIR}/backups/dumps/${TRIPLE_LAYER_SUBDIRS}/original/<br>- Archive filename: archive-${FILE_DATE}-{SHA384_HASH}.zip</p><p>Command: </p><p>» \fetch -4 -A -a -F -R -r --buffer-size=512384 --no-tlsv1 -v ${URL_PRE_QMARK}?X-Amz-Algorithm=AWS4-HMAC-SHA256</p><p>Verbose output:</p><p>resolving server address: ${SERVER}:443<br>SSL options: 86004850<br>Peer verification enabled<br>Using OpenSSL default CA cert file and path<br>Verify hostname<br>TLSv1.3 connection established using TLS_AES_256_GCM_SHA384<br>Certificate subject: /CN=${SEVER}<br>Certificate issuer: /C=US/O=Let's Encrypt/CN=E5<br>requesting ${URL_PRE_QMARK}?X-Amz-Algorithm=AWS4-HMAC-SHA256<br>remote size / mtime: ${FILE_SIZE} / 1742465117<br>archive-${FILE_DATE}-{SHA384_HASH}.zip 96 MB 2518 kBps 40s</p><p><span class="h-card" translate="no"><a href="https://mastodon.bsd.cafe/@stefano" class="u-url mention" rel="nofollow noopener noreferrer" target="_blank">@<span>stefano</span></a></span> looks to be working now :) </p><p><a href="https://mastodon.bsd.cafe/tags/mastodon" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>mastodon</span></a> <a href="https://mastodon.bsd.cafe/tags/freebsd" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>freebsd</span></a> <a href="https://mastodon.bsd.cafe/tags/terminal" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>terminal</span></a> <a href="https://mastodon.bsd.cafe/tags/cli" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>cli</span></a> <a href="https://mastodon.bsd.cafe/tags/cdn" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>cdn</span></a> <a href="https://mastodon.bsd.cafe/tags/cache" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>cache</span></a> <a href="https://mastodon.bsd.cafe/tags/expire" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>expire</span></a></p>