<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Edouard's security notes]]></title><description><![CDATA[Edouard's security notes]]></description><link>https://edouard-g.hashnode.dev</link><generator>RSS for Node</generator><lastBuildDate>Fri, 04 Dec 2026 22:13:53 GMT</lastBuildDate><atom:link href="https://edouard-g.hashnode.dev/rss.xml" rel="self" type="application/rss+xml"/><language><![CDATA[en]]></language><ttl>60</ttl><item><title><![CDATA[Add a security.txt file to your website in 10 minutes (RFC 9116)]]></title><description><![CDATA[When someone finds a vulnerability on your website, the first question is often: "Who do I tell?" Without a clear contact, many people give up, or go…]]></description><link>https://edouard-g.hashnode.dev/add-a-security-txt-file-to-your-website-in-10-minutes-rfc-9116</link><guid isPermaLink="true">https://edouard-g.hashnode.dev/add-a-security-txt-file-to-your-website-in-10-minutes-rfc-9116</guid><category><![CDATA[security testing ]]></category><category><![CDATA[web development services]]></category><category><![CDATA[#cybersecurity]]></category><dc:creator><![CDATA[Edouard]]></dc:creator><pubDate>Sun, 29 Nov 2026 21:15:28 GMT</pubDate><content:encoded><![CDATA[<p>When someone finds a vulnerability on your website, the first question is often: "Who do I tell?" Without a clear contact, many people give up, or go public straight away. <strong>security.txt</strong>, standardised by <a href="https://www.rfc-editor.org/rfc/rfc9116">RFC 9116</a>, solves this with one small text file.</p>
<h2>Where it goes</h2>
<pre><code class="language-text">https://your-site.com/.well-known/security.txt
</code></pre>
<p>Serve it over HTTPS with <code>Content-Type: text/plain</code>. A copy at <code>/security.txt</code> is tolerated, but <code>/.well-known/</code> is the reference location.</p>
<h2>The two required fields</h2>
<ul>
<li><strong>Contact</strong>: a <code>mailto:</code> address, a form URL or a phone number. You can list several, most preferred first.</li>
<li><strong>Expires</strong>: an ISO 8601 date. It forces you to review the file; the RFC recommends less than a year ahead.</li>
</ul>
<p>A valid minimal file is just two lines:</p>
<pre><code class="language-text">Contact: mailto:security@your-site.com
Expires: 2027-11-30T23:00:00.000Z
</code></pre>
<h2>Useful optional fields</h2>
<ul>
<li><strong>Preferred-Languages</strong>: languages you read reports in (<code>en, fr</code>).</li>
<li><strong>Canonical</strong>: the official URL of the file, useful if you sign it.</li>
<li><strong>Policy</strong>: a link to your disclosure policy (timelines, scope, what you expect).</li>
<li><strong>Encryption</strong>: a link to your OpenPGP key for encrypted reports.</li>
<li><strong>Acknowledgments</strong>: a page thanking people who reported issues.</li>
</ul>
<h2>Installing it on Apache</h2>
<p>On shared hosting, create a <code>.well-known</code> folder at the web root and drop the file in. If your site rewrites every URL to <code>index.php</code>, make sure real files are served first in <code>.htaccess</code>:</p>
<pre><code class="language-apache">RewriteCond %{REQUEST_FILENAME} -f
RewriteRule ^ - [L]
</code></pre>
<h2>Checking it</h2>
<p><code>curl -I https://your-site.com/.well-known/security.txt</code> should return <code>200</code> and <code>Content-Type: text/plain</code>. Put the expiry date in your calendar: an expired file should be treated as untrustworthy.</p>
<p>To generate or validate a file without installing anything, I built a free <a href="https://edouard-guery.fr/outils/generateur-security-txt/">security.txt generator</a> that runs entirely in the browser (French UI).</p>
<p><em>Adapted from my original guide in French: <a href="https://edouard-guery.fr/blog/ajouter-security-txt-site/">Ajouter un fichier security.txt à son site</a>.</em></p>
]]></content:encoded></item></channel></rss>