<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xml:base="https://blog.velocifyer.com/" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    
    <title>Blog-Ifyer</title>
    <link>https://blog.velocifyer.com/</link>
    <atom:link href="https://blog.velocifyer.com/Posts/Feeds/rss.xml" rel="self" type="application/rss+xml" />
    <description>Velocifyer&#39;s Blog.</description>
    <language>en</language>
    <item>
      <title>How to self host a font from Google Fonts, the easy way, via NPM</title>
      <link>https://blog.velocifyer.com/Posts/8,How%20to%20self-host%20a%20font%20from%20Google%20Fonts,%20the%20easy%20way,%20via%20NPM/</link><description>&lt;p&gt;In one of my previous posts (&lt;a href=&quot;https://blog.velocifyer.com/Posts/3,How%20to%20self%20host%20a%20font%20from%20google%20fonts/&quot;&gt;How to self host a web-font from google fonts&lt;/a&gt;), I taught you how to do it manually.&lt;/p&gt;&lt;p&gt;The advantage to doing it this way instead of hot linking is speed and privacy.&lt;/p&gt;&lt;p&gt;It turns out that there is an easier way to do it, with NPM.&lt;/p&gt;&lt;p&gt;Here&#39;s how to do it.&lt;/p&gt;&lt;h2 id=&quot;setup-npm&quot; tabindex=&quot;-1&quot;&gt;Setup NPM&lt;/h2&gt;&lt;div class=&quot;markdown-alert markdown-alert-note&quot;&gt;&lt;p class=&quot;markdown-alert-title&quot;&gt;&lt;svg class=&quot;octicon octicon-info mr-2&quot; viewBox=&quot;0 0 16 16&quot; version=&quot;1.1&quot; width=&quot;16&quot; height=&quot;16&quot; aria-hidden=&quot;true&quot;&gt;&lt;path d=&quot;M0 8a8 8 0 1 1 16 0A8 8 0 0 1 0 8Zm8-6.5a6.5 6.5 0 1 0 0 13 6.5 6.5 0 0 0 0-13ZM6.5 7.75A.75.75 0 0 1 7.25 7h1a.75.75 0 0 1 .75.75v2.75h.25a.75.75 0 0 1 0 1.5h-2a.75.75 0 0 1 0-1.5h.25v-2h-.25a.75.75 0 0 1-.75-.75ZM8 6a1 1 0 1 1 0-2 1 1 0 0 1 0 2Z&quot;&gt;&lt;/path&gt;&lt;/svg&gt;Note&lt;/p&gt;&lt;p&gt;&lt;strong&gt;Only do this if you haven&#39;t set up NPM for this already&lt;/strong&gt;&lt;/p&gt;&lt;/div&gt;&lt;ol&gt;&lt;li&gt;Run &lt;code&gt;npm init&lt;/code&gt;.&lt;/li&gt;&lt;li&gt;Add node_modules to .gitignore (or equivelent).&lt;/li&gt;&lt;li&gt;Other developers (or CI) should run &lt;code&gt;npm ci&lt;/code&gt; before using your code.&lt;/li&gt;&lt;/ol&gt;&lt;h2 id=&quot;get-the-font-package-name-and-install-the-font&quot; tabindex=&quot;-1&quot;&gt;Get the font package name and install the font&lt;/h2&gt;&lt;div class=&quot;markdown-alert markdown-alert-note&quot;&gt;&lt;p class=&quot;markdown-alert-title&quot;&gt;&lt;svg class=&quot;octicon octicon-info mr-2&quot; viewBox=&quot;0 0 16 16&quot; version=&quot;1.1&quot; width=&quot;16&quot; height=&quot;16&quot; aria-hidden=&quot;true&quot;&gt;&lt;path d=&quot;M0 8a8 8 0 1 1 16 0A8 8 0 0 1 0 8Zm8-6.5a6.5 6.5 0 1 0 0 13 6.5 6.5 0 0 0 0-13ZM6.5 7.75A.75.75 0 0 1 7.25 7h1a.75.75 0 0 1 .75.75v2.75h.25a.75.75 0 0 1 0 1.5h-2a.75.75 0 0 1 0-1.5h.25v-2h-.25a.75.75 0 0 1-.75-.75ZM8 6a1 1 0 1 1 0-2 1 1 0 0 1 0 2Z&quot;&gt;&lt;/path&gt;&lt;/svg&gt;Note&lt;/p&gt;&lt;p&gt;This guide is designed for variable fonts. The steps should be simaler for non variable fonts.&lt;/p&gt;&lt;/div&gt;&lt;ol&gt;&lt;li&gt;Go to &lt;a href=&quot;https://fontsource.org/&quot;&gt;fontsource.org&lt;/a&gt;, and search for the font you want(eg &lt;code&gt;Google Sans Flex&lt;/code&gt;).&lt;/li&gt;&lt;li&gt;Click on &amp;quot;Get Font&amp;quot;.&lt;/li&gt;&lt;li&gt;Click on &amp;quot;Developer Setup&amp;quot;.&lt;/li&gt;&lt;li&gt;It should give you a command like &lt;code&gt;npm install @fontsource-variable/google-sans-flex&lt;/code&gt;; run that command.&lt;/li&gt;&lt;li&gt;Copy the part after &lt;code&gt;npm install&lt;/code&gt; (eg copy &lt;code&gt;@fontsource-variable/google-sans-flex&lt;/code&gt;); this will now be refered to as $FONT_PACKAGE.&lt;/li&gt;&lt;li&gt;There should be a folder &lt;code&gt;./node_modules/$PACKAGE_NAME&lt;/code&gt;. If you have a SSG or something, set that folder (and the files subdirectory) to passthrough&lt;/li&gt;&lt;/ol&gt;&lt;h2 id=&quot;start-using-the-font.&quot; tabindex=&quot;-1&quot;&gt;Start using the font.&lt;/h2&gt;&lt;ol&gt;&lt;li&gt;Decide which axis to use. For this example, we will only use wght.&lt;/li&gt;&lt;li&gt;For each axis, import the CSS from &lt;code&gt;./node_modules/PACKAGE_NAME&lt;/code&gt;.&lt;/li&gt;&lt;/ol&gt;&lt;p&gt;For this blog, we do:&lt;/p&gt;&lt;pre class=&quot;language-html&quot; tabindex=&quot;0&quot;&gt;&lt;code class=&quot;language-html&quot;&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token punctuation&quot;&gt;&amp;lt;&lt;/span&gt;link&lt;/span&gt; &lt;span class=&quot;token attr-name&quot;&gt;rel&lt;/span&gt;&lt;span class=&quot;token attr-value&quot;&gt;&lt;span class=&quot;token punctuation attr-equals&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;stylesheet&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;&lt;/span&gt; &lt;span class=&quot;token attr-name&quot;&gt;href&lt;/span&gt;&lt;span class=&quot;token attr-value&quot;&gt;&lt;span class=&quot;token punctuation attr-equals&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;/node_modules/@fontsource-variable/google-sans-flex/wght.css?v=14d83eeaec00bf58668a2b71d65ab080aaa1525e4b552f80e89aa9538c0dc9ec&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;ol start=&quot;3&quot;&gt;&lt;li&gt;Ensure that your use of the font is license compliant. (the license is often in &lt;code&gt;./node_modules/PACKAGE_NAME/LICENSE&lt;/code&gt;; you may have to link to it) &lt;strong&gt;THIS IS NOT LEGAL ADVICE&lt;/strong&gt;&lt;/li&gt;&lt;li&gt;Find the name used for the font-family from from the font-family rule in the CSS you are importing.&lt;/li&gt;&lt;li&gt;Using &lt;a href=&quot;https://developer.mozilla.org/en-US/docs/Web/CSS/Reference/Properties/font-family&quot;&gt;the font-family CSS rule&lt;/a&gt;, use the font.&lt;/li&gt;&lt;/ol&gt;</description><pubDate>Thu, 08 Oct 2026 00:00:00 +0000</pubDate>
      <dc:creator>Velocifyer</dc:creator>
      <guid>https://blog.velocifyer.com/Posts/8,How%20to%20self-host%20a%20font%20from%20Google%20Fonts,%20the%20easy%20way,%20via%20NPM/</guid>
    </item>
    <item>
      <title>How to self-host a web font from Google Fonts</title>
      <link>https://blog.velocifyer.com/Posts/3,How%20to%20self%20host%20a%20font%20from%20google%20fonts/</link><description>&lt;p&gt;A common place to get a web font is &lt;a href=&quot;https://fonts.google.com/&quot; referrerpolicy=&quot;no-referrer&quot;&gt;Google Fonts&lt;/a&gt;. If you want to use a font from Google Fonts, you should not just paste the code they give you because that would leak the IP addresses of visitors to Google.&lt;/p&gt;&lt;p&gt;Instead, you should download the font files and put them on your webserver.&lt;/p&gt;&lt;p&gt;Do not use the download button on Google Fonts becasue the download button in Google Fonts gives TTF files and not WOFF2 files. WOFF2 files are better because they are compressed and because Google Fonts subsets them.&lt;/p&gt;&lt;p&gt;&lt;!--If you want a font used on this website(like Noto Sans(the best font) and Fira Code), follow the instructions in the README from &lt;a href=&quot;https://codeberg.org/Velocifyer/Blog-ifyer/src/branch/main/Assets/Fonts/&quot; referrerpolicy=&quot;no-referrer-when-downgrade&quot; ping=&quot;https://blog.velocifyer.com/clicked+link+to+codeberg+fonts&quot;&gt;
        here
    &lt;/a&gt; and skip steps 0 and 1.&lt;br/&gt; --&gt; &lt;strong&gt;THIS IS NOT LEGAL ADVICE&lt;/strong&gt;&lt;br&gt;&lt;strong&gt;I AM NOT YOUR LAWYER&lt;/strong&gt; &lt;strong&gt;ENSURE THAT YOUR USE OF THE FONT WILL COMPLY WITH THE LICENSE&lt;/strong&gt;&lt;/p&gt;&lt;h2 id=&quot;download-the-font&quot; tabindex=&quot;-1&quot;&gt;Download the font&lt;/h2&gt;&lt;ol start=&quot;0&quot;&gt;&lt;li&gt;Go to &lt;a href=&quot;https://fonts.google.com/&quot; referrerpolicy=&quot;no-referrer&quot;&gt;Google Fonts&lt;/a&gt; and search for the font you want.&lt;/li&gt;&lt;li&gt;Select &quot;Get font&quot;.&lt;/li&gt;&lt;li&gt;Select &quot;Get embed code&quot; (don&#39;t paste the code it gives you).&lt;/li&gt;&lt;li&gt;Select which options you want included.&lt;/li&gt;&lt;li&gt;In the HTML code it gives you, it should have something like:&lt;pre class=&quot;language-html&quot; tabindex=&quot;0&quot;&gt;&lt;code class=&quot;language-html&quot;&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token punctuation&quot;&gt;&amp;lt;&lt;/span&gt;link&lt;/span&gt; &lt;span class=&quot;token attr-name&quot;&gt;href&lt;/span&gt;&lt;span class=&quot;token attr-value&quot;&gt;&lt;span class=&quot;token punctuation attr-equals&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;https://fonts.googleapis.com/css2?family=Fira+Code&amp;amp;display=swap&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;&lt;/span&gt; &lt;span class=&quot;token attr-name&quot;&gt;rel&lt;/span&gt;&lt;span class=&quot;token attr-value&quot;&gt;&lt;span class=&quot;token punctuation attr-equals&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;stylesheet&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Download the file using the URL after the href in that element (&lt;/p&gt;&lt;pre class=&quot;language-url&quot; tabindex=&quot;0&quot;&gt;&lt;code class=&quot;language-url&quot;&gt;&lt;span class=&quot;token scheme&quot;&gt;https&lt;span class=&quot;token scheme-delimiter&quot;&gt;:&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;token authority&quot;&gt;&lt;span class=&quot;token authority-delimiter&quot;&gt;//&lt;/span&gt;&lt;span class=&quot;token host&quot;&gt;fonts.googleapis.com&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;token path&quot;&gt;&lt;span class=&quot;token path-separator&quot;&gt;/&lt;/span&gt;css2&lt;/span&gt;&lt;span class=&quot;token query&quot;&gt;&lt;span class=&quot;token query-delimiter&quot;&gt;?&lt;/span&gt;&lt;span class=&quot;token pair&quot;&gt;&lt;span class=&quot;token key&quot;&gt;family&lt;/span&gt;=&lt;span class=&quot;token value&quot;&gt;Fira+Code&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;token pair-delimiter&quot;&gt;&amp;amp;&lt;/span&gt;&lt;span class=&quot;token pair&quot;&gt;&lt;span class=&quot;token key&quot;&gt;display&lt;/span&gt;=&lt;span class=&quot;token value&quot;&gt;swap&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;in this case)&lt;/p&gt;&lt;p&gt;Download each font referenced in the CSS file you just downloaded.&lt;br&gt;Put all of the font you just downloaded in a folder, ideally with a something that will change each update and a long cache time (like /Assets/Fira/Code/2025-8-13/).&lt;/p&gt;&lt;p&gt;Copy the CSS file into that folder.&lt;/p&gt;&lt;p&gt;Change the CSS to use relative links.&lt;br&gt;(eg change&lt;/p&gt;&lt;pre class=&quot;language-css&quot; tabindex=&quot;0&quot;&gt;&lt;code class=&quot;language-css&quot;&gt;&lt;span class=&quot;token property&quot;&gt;src&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;token url&quot;&gt;&lt;span class=&quot;token function&quot;&gt;url&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;https://fonts.gstatic.com/s/firacode/v26/uU9eCBsR6Z2vfE9aq3bL0fxyUs4tcw4W_D1sJVD7Ng.woff2&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;/span&gt; &lt;span class=&quot;token function&quot;&gt;format&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;token string&quot;&gt;&#39;woff2&#39;&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;into&lt;/p&gt;&lt;pre class=&quot;language-css&quot; tabindex=&quot;0&quot;&gt;&lt;code class=&quot;language-css&quot;&gt;&lt;span class=&quot;token property&quot;&gt;src&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;token url&quot;&gt;&lt;span class=&quot;token function&quot;&gt;url&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;uU9eCBsR6Z2vfE9aq3bL0fxyUs4tcw4W_D1sJVD7Ng.woff2&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;/span&gt; &lt;span class=&quot;token function&quot;&gt;format&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;token string&quot;&gt;&#39;woff2&#39;&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;)&lt;/p&gt;&lt;/li&gt;&lt;p&gt;&lt;/p&gt;&lt;/ol&gt;&lt;h2 id=&quot;use-the-font&quot; tabindex=&quot;-1&quot;&gt;Use the font&lt;/h2&gt;&lt;p&gt;Paste the license of the font into a file. To find the license of a google font do,&lt;/p&gt;&lt;ol start=&quot;0&quot;&gt;&lt;li&gt;Search for the font on &lt;a href=&quot;https://fonts.google.com/&quot; referrerpolicy=&quot;no-referrer&quot;&gt;Google Fonts&lt;/a&gt;;&lt;/li&gt;&lt;li&gt;Select the font;&lt;/li&gt;&lt;li&gt;Select &quot;License&quot;&lt;/li&gt;&lt;/ol&gt;&lt;p&gt;Add html to use the CSS like:&lt;/p&gt;&lt;pre class=&quot;language-html&quot; tabindex=&quot;0&quot;&gt;&lt;code class=&quot;language-html&quot;&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token punctuation&quot;&gt;&amp;lt;&lt;/span&gt;link&lt;/span&gt; &lt;span class=&quot;token attr-name&quot;&gt;href&lt;/span&gt;&lt;span class=&quot;token attr-value&quot;&gt;&lt;span class=&quot;token punctuation attr-equals&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;/Assets/Fonts/Fira/Code/2025-8-13/fira-code.css&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;&lt;/span&gt; &lt;span class=&quot;token attr-name&quot;&gt;rel&lt;/span&gt;&lt;span class=&quot;token attr-value&quot;&gt;&lt;span class=&quot;token punctuation attr-equals&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;preload&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;/&gt;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token punctuation&quot;&gt;&amp;lt;&lt;/span&gt;link&lt;/span&gt; &lt;span class=&quot;token attr-name&quot;&gt;href&lt;/span&gt;&lt;span class=&quot;token attr-value&quot;&gt;&lt;span class=&quot;token punctuation attr-equals&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;/Assets/Fonts/Fira/Code/2025-8-13/fira-code.css&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;&lt;/span&gt; &lt;span class=&quot;token attr-name&quot;&gt;rel&lt;/span&gt;&lt;span class=&quot;token attr-value&quot;&gt;&lt;span class=&quot;token punctuation attr-equals&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;stylesheet&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;/&gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Add css to use the font like:&lt;/p&gt;&lt;pre class=&quot;language-css&quot; tabindex=&quot;0&quot;&gt;&lt;code class=&quot;language-css&quot;&gt;&lt;span class=&quot;token selector&quot;&gt;code&lt;/span&gt; &lt;span class=&quot;token punctuation&quot;&gt;{&lt;/span&gt;
&lt;span class=&quot;token property&quot;&gt;font-family&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;token string&quot;&gt;&quot;Fira Code&quot;&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;,&lt;/span&gt; monospace&lt;span class=&quot;token punctuation&quot;&gt;;&lt;/span&gt;
&lt;span class=&quot;token property&quot;&gt;font-optical-sizing&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;:&lt;/span&gt; auto&lt;span class=&quot;token punctuation&quot;&gt;;&lt;/span&gt;
&lt;span class=&quot;token property&quot;&gt;font-weight&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;:&lt;/span&gt; 400&lt;span class=&quot;token punctuation&quot;&gt;;&lt;/span&gt;
&lt;span class=&quot;token property&quot;&gt;font-style&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;:&lt;/span&gt; normal&lt;span class=&quot;token punctuation&quot;&gt;;&lt;/span&gt;
&lt;span class=&quot;token punctuation&quot;&gt;}&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Add a link to the font LICENSE and &lt;strong&gt;ensure that your usage of the font follows the license of the font&lt;/strong&gt;.&lt;!-- If you can&#39;t understand these steps, &lt;a href=&quot;https://codeberg.org/Velocifyer/Blog-ifyer/src/branch/main/Assets/Fonts/Noto/Sans&quot; referrerpolicy=&quot;no-referrer-when-downgrade&quot; ping=&quot;https://blog.velocifyer.com/clicked+other+link+to+codeberg+fonts&quot;&gt;
        see how it was done here.
    &lt;/a&gt; --&gt;&lt;/p&gt;</description><pubDate>Thu, 08 Oct 2026 00:00:00 +0000</pubDate>
      <dc:creator>Velocifyer</dc:creator>
      <guid>https://blog.velocifyer.com/Posts/3,How%20to%20self%20host%20a%20font%20from%20google%20fonts/</guid>
    </item>
    <item>
      <title>Stop ATSC 3.0 DRM</title>
      <link>https://blog.velocifyer.com/Posts/7,Stop%20ATSC%203.0%20DRM/</link><description>&lt;p&gt;Currently most ATSC 3.0 signals from major networks like NBC have DRM. This is annoying becuase DRM is bad.&lt;/p&gt;&lt;p&gt;Many TV sets do not let people watch DRM-Encumbered ATSC 3.0 signals without internet accses. The DRM blocks standard TV equipment like DVRs and VCRs preventing people from recording something and watching it later.&lt;br&gt;The FCC should block all DRM on public TV signals.&lt;/p&gt;&lt;p&gt;Another problem is that TV and Set Top Box makers will likely need to pay for a decryption key to display DRM-encumbered streams.&lt;br&gt;This would increase the prices of TVs.&lt;/p&gt;&lt;p&gt;DRM advocates claim that this is nessisary to stop rebroadcasting of the TV signals. However people can still use a capture card.&lt;br&gt;DRM harms consumers.&lt;/p&gt;&lt;p&gt;Another bad feature of ATSC 3.0 DRM is that it sometimes adds required intrenet connectivity.&lt;/p&gt;</description><pubDate>Mon, 09 Mar 2026 00:00:00 +0000</pubDate>
      <dc:creator>Velocifyer</dc:creator>
      <guid>https://blog.velocifyer.com/Posts/7,Stop%20ATSC%203.0%20DRM/</guid>
    </item>
    <item>
      <title>How to set up secure boot (with your own keys) and lockdown mode and TPM based storage decryption on Arch Linux</title>
      <link>https://blog.velocifyer.com/Posts/6,How%20to%20set%20up%20secure%20boot%20and%20lockdown%20mode%20and%20TPM%20based%20storage%20decryption%20on%20Arch%20Linux/</link><description>&lt;p&gt;Normaly on arch linux there is no way to know wheater someone took out your ssd and modified the files on the ESP or the root partition.&lt;/p&gt;&lt;p&gt;By encrypting the root partition you can prevent modifications to it but the ESP has to stay unencrypted.&lt;/p&gt;&lt;p&gt;So we will use secure boot (with our own keys) and unified kernel images to prevent tampering with the kernel and initramfs and TPM to verify that secure boot was not disabled.&lt;/p&gt;&lt;p&gt;We will also use kernel lockdown mode in confidentiality mode to prevent loading unsigned kernel modules or reading kernel memory.&lt;/p&gt;&lt;p&gt;After following this guide, you will not have to manualy sign files with secure boot.&lt;/p&gt;&lt;p&gt;&lt;small&gt;&lt;strong&gt;I AM NOT RESPONSIBLE FOR YOU BREAKING STUFF BY FOLLOWING THIS GUIDE!!&lt;/strong&gt;&lt;/small&gt;&lt;/p&gt;&lt;p&gt;This guide assumes you already installed archlinux with a ESP mounted at /boot/ that is located at /dev/nvme0n1p1 and a LUKS2 encryped root partition that is located at &lt;code&gt;/dev/nvme0n1p2&lt;/code&gt;and are using mkintcpio and the &lt;code&gt;linux&lt;/code&gt; kernel and the fish shell and you have sudo installed and set up to let you execute commands as root.&lt;/p&gt;&lt;h2 id=&quot;set-up-unified-kernel-images.&quot; tabindex=&quot;-1&quot;&gt;Set up unified kernel images.&lt;/h2&gt;&lt;p&gt;&lt;/p&gt;&lt;ol start=&quot;0&quot;&gt;&lt;li&gt;Install &lt;code&gt;tpm2-tss&lt;/code&gt; with pacman.&lt;/li&gt;&lt;li&gt;Set the contents of /etc/kernel/cmdline to: &lt;code&gt;rd.luks.name=uuid=root root=/dev/mapper/root rw zswap.enabled=0 rd.luks.options=tpm2-device=auto,tpm2-measure-pcr=yes&lt;/code&gt; replacing &lt;code&gt;uuid&lt;/code&gt; with the UUID of the LUKS2 root partition. (This file will define the kernel command line.)&lt;/li&gt;&lt;li&gt;Set /etc/mkinitcpio.d/linux.preset to&lt;p&gt;&lt;/p&gt;&lt;pre class=&quot;language-text&quot; tabindex=&quot;0&quot;&gt;&lt;code class=&quot;language-text&quot;&gt;# mkinitcpio preset file for the &#39;linux&#39; package            
#ALL_config=&quot;/etc/mkinitcpio.conf&quot;
ALL_kver=&quot;/boot/vmlinuz-linux&quot;
            
PRESETS=(&#39;default&#39; &#39;fallback&#39;)
            
#default_config=&quot;/etc/mkinitcpio.conf&quot;
default_image=&quot;/boot/initramfs-linux.img&quot;
default_uki=&quot;/boot/EFI/Linux/arch-linux.efi&quot;
default_options=&quot;--splash /usr/share/systemd/bootctl/splash-arch.bmp&quot;
            
#fallback_config=&quot;/etc/mkinitcpio.conf&quot;
fallback_image=&quot;/boot/initramfs-linux-fallback.img&quot;
fallback_uki=&quot;/boot/EFI/Linux/arch-linux-fallback.efi&quot;
fallback_options=&quot;-S autodetect&quot;&lt;/code&gt;&lt;/pre&gt;&lt;/li&gt;&lt;li&gt;Set the hooks line in `/etc/mkinitcpio.conf` to `HOOKS=(base systemd autodetect microcode modconf kms keyboard sd-vconsole block sd-encrypt filesystems fsck)`.&lt;/li&gt;&lt;li&gt;Run `sudo mkdir -p /boot/EFI/Linux`.&lt;/li&gt;&lt;li&gt;Run `sudo mkinitcpio -P`.&lt;/li&gt;&lt;li&gt;Run `sudo efibootmgr --create --disk /dev/nvme0n1 --part 1 --label &quot;Arch Linux&quot; --loader &#39;&#92;EFI&#92;Linux&#92;arch-linux.efi&#39; --unicode`,changing the devices to the ones actually in use.&lt;/li&gt;&lt;li&gt;Reboot.&lt;/li&gt;&lt;/ol&gt;&lt;h2 id=&quot;set-up-uefi-for-secure-boot.&quot; tabindex=&quot;-1&quot;&gt;Set up UEFI for secure boot.&lt;/h2&gt;&lt;p&gt;The exact steps for this depend on your hardware.&lt;/p&gt;&lt;p&gt;Enter your UEFI firmware.&lt;/p&gt;&lt;p&gt;If it has a option to delete specific keys then delete the Platform key and all microsoft keys.&lt;/p&gt;&lt;p&gt;You may also delete the device manufactuer&#39;s keys but I do not recommend it because it may make firmware updates harder.&lt;/p&gt;&lt;p&gt;If your UEFI does not let you delete specific keys just delete all of them.&lt;/p&gt;&lt;p&gt;Then set a “Administrator Password” in your UEFI firmware configurator and store the password somewhere safe. You may have to enable secure boot in this step.&lt;/p&gt;&lt;p&gt;I also reccomend using some sort of tamper evidence to detect if someone opened the device to disable secure boot to get the password.&lt;br&gt;(I use glitter nail polish and stickers over the screws and &lt;a href=&quot;https://f-droid.org/en/packages/org.proninyaroslav.blink_comparison/&quot;&gt;the Blink Comparison Android app&lt;/a&gt;.)&lt;/p&gt;&lt;h2 id=&quot;set-up-secure-boot-with-sbctl&quot; tabindex=&quot;-1&quot;&gt;Set up secure boot with sbctl&lt;/h2&gt;&lt;ol start=&quot;0&quot;&gt;&lt;li&gt;Install the sbctl pacman package.&lt;/li&gt;&lt;li&gt;Run &lt;code&gt;sudo sbctl create-keys&lt;/code&gt;.&lt;/li&gt;&lt;li&gt;Run &lt;code&gt;sudo mkinitcpio -P&lt;/code&gt;.&lt;/li&gt;&lt;li&gt;Run &lt;code&gt;sudo sbctl enroll-keys -f --yes-this-might-brick-my-machine&lt;/code&gt;.&lt;/li&gt;&lt;li&gt;Enable enforcement of secure boot in UEFI.&lt;/li&gt;&lt;li&gt;Reboot.&lt;/li&gt;&lt;/ol&gt;&lt;h2 id=&quot;set-up-tpm-based-decryption-of-the-root-partition.&quot; tabindex=&quot;-1&quot;&gt;Set up TPM based decryption of the root partition.&lt;/h2&gt;&lt;p&gt;&lt;/p&gt;&lt;ol start=&quot;0&quot;&gt;&lt;li&gt;Run &lt;code&gt;sudo systemd-cryptenroll /dev/nvme0n1p2 --wipe-slot=password --recovery-key&lt;/code&gt; and save the recovery key securly.&lt;/li&gt;&lt;li&gt;Run &lt;code&gt;sudo systemd-cryptenroll /dev/nvme0n1p2 --wipe-slot=empty --tpm2-device=auto --tpm2-pcrs=7+15:sha256=0000000000000000000000000000000000000000000000000000000000000000 --tpm2-with-pin=yes&lt;/code&gt; and set the pin to whatever secret you want to be needed to decrypt the disk.&lt;br&gt;Remove &lt;code&gt;--tpm2-with-pin=yes&lt;/code&gt; if you do not want a secret to have to be entered in-person (like on a server).&lt;/li&gt;&lt;li&gt;Reboot&lt;/li&gt;&lt;/ol&gt;&lt;p&gt;&lt;/p&gt;&lt;h2 id=&quot;set-up-kernel-lockdown-mode.&quot; tabindex=&quot;-1&quot;&gt;Set up kernel lockdown mode.&lt;/h2&gt;&lt;ol start=&quot;0&quot;&gt;&lt;li&gt;Make sure you do not use any unsigned kernel modules.&lt;/li&gt;&lt;li&gt;Add &lt;code&gt;lockdown=confidentiality&lt;/code&gt; to &lt;code&gt;/etc/kernel/cmdline&lt;/code&gt;.&lt;/li&gt;&lt;li&gt;Run &lt;code&gt;sudo mkinitcpio -P&lt;/code&gt;.&lt;/li&gt;&lt;li&gt;Restart the system.&lt;/li&gt;&lt;/ol&gt;&lt;p&gt;This setup does have some slight vulnerabilities. For example this only secures against a attacker with root accses until a reboot becuase the secure boot keys are stored on the device.&lt;/p&gt;&lt;p&gt;However this setup does stop a attacker who just has accses to the SSD and not the decryption key from making it run malware.&lt;br&gt;I recommend entering a random ammount of incorrect decryption passwords incase the attacker has disabled secure boot and is trying to get your password.&lt;/p&gt;&lt;p&gt;&lt;!-- &lt;hr/&gt;
            &lt;a class=&quot;link&quot; href=&quot;https://news.ycombinator.com/item?id=45520217&quot;&gt;First Hacker News post&lt;/a&gt; --&gt;&lt;/p&gt;</description><pubDate>Wed, 25 Feb 2026 00:00:00 +0000</pubDate>
      <dc:creator>Velocifyer</dc:creator>
      <guid>https://blog.velocifyer.com/Posts/6,How%20to%20set%20up%20secure%20boot%20and%20lockdown%20mode%20and%20TPM%20based%20storage%20decryption%20on%20Arch%20Linux/</guid>
    </item>
    <item>
      <title>Hello, World</title>
      <link>https://blog.velocifyer.com/Posts/0,Hello,%20World/</link><description>&lt;p&gt;Welcome to my blog!&lt;/p&gt;&lt;p&gt;This is my first post.&lt;/p&gt;&lt;p&gt;On this blog I will discuss important stuff like:&lt;/p&gt;&lt;ul&gt;&lt;li&gt;Technology&lt;/li&gt;&lt;li&gt;Computers&lt;/li&gt;&lt;li&gt;HTML&lt;/li&gt;&lt;li&gt;Blog-𝕚𝕗𝕪𝕖𝕣&lt;/li&gt;&lt;li&gt;Hot Dogs&lt;/li&gt;&lt;li&gt;Food&lt;/li&gt;&lt;li&gt;Pasta&lt;/li&gt;&lt;/ul&gt;</description><pubDate>Tue, 09 Sep 2025 00:00:00 +0000</pubDate>
      <dc:creator>Velocifyer</dc:creator>
      <guid>https://blog.velocifyer.com/Posts/0,Hello,%20World/</guid>
    </item>
  </channel>
</rss>