URI: 
       add susmb page - www.codemadness.org - www.codemadness.org saait content files
  HTML git clone git://git.codemadness.org/www.codemadness.org
   DIR Log
   DIR Files
   DIR Refs
   DIR README
   DIR LICENSE
       ---
   DIR commit 9b2a439ea8b020383160bc4fd7d7bdc7a511583f
   DIR parent 32eedb63d291b8e15f652c3d34e9dc9ebab467f2
  HTML Author: Hiltjo Posthuma <hiltjo@codemadness.org>
       Date:   Fri,  6 Mar 2026 13:06:22 +0100
       
       add susmb page
       
       Diffstat:
         M config.cfg                          |       2 +-
         M output/atom.xml                     |      14 +++++++++++++-
         M output/atom_content.xml             |     113 ++++++++++++++++++++++++++++++-
         M output/atom_content_gopher.xml      |     113 ++++++++++++++++++++++++++++++-
         M output/atom_gopher.xml              |      14 +++++++++++++-
         M output/index                        |       1 +
         M output/index.html                   |       1 +
         M output/jsonfeed.json                |       8 ++++++++
         M output/jsonfeed_content.json        |       8 ++++++++
         M output/jsonfeed_content_gopher.json |       8 ++++++++
         M output/jsonfeed_gopher.json         |       8 ++++++++
         M output/rss.xml                      |       8 ++++++++
         M output/rss_content.xml              |     106 ++++++++++++++++++++++++++++++
         M output/rss_content_gopher.xml       |     106 ++++++++++++++++++++++++++++++
         M output/rss_gopher.xml               |       8 ++++++++
         M output/sfeed.tsv                    |       1 +
         M output/sfeed_content.tsv            |       1 +
         M output/sfeed_content_gopher.tsv     |       1 +
         M output/sfeed_gopher.tsv             |       1 +
         M output/sitemap.xml                  |       4 ++++
         M output/twtxt.txt                    |       1 +
         M output/twtxt_gopher.txt             |       1 +
         M output/urllist.txt                  |       1 +
       
       23 files changed, 524 insertions(+), 5 deletions(-)
       ---
   DIR diff --git a/config.cfg b/config.cfg
       @@ -1,5 +1,5 @@
        # last updated the site.
       -siteupdated = 2025-12-14
       +siteupdated = 2026-03-06
        
        sitetitle = Codemadness
        siteurl = https://www.codemadness.org
   DIR diff --git a/output/atom.xml b/output/atom.xml
       @@ -2,11 +2,23 @@
        <feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
                <title>Codemadness</title>
                <subtitle>blog with various projects and articles about computer-related things</subtitle>
       -        <updated>2025-12-14T00:00:00Z</updated>
       +        <updated>2026-03-06T00:00:00Z</updated>
                <link rel="alternate" type="text/html" href="https://www.codemadness.org" />
                <id>https://www.codemadness.org/atom.xml</id>
                <link rel="self" type="application/atom+xml" href="https://www.codemadness.org/atom.xml" />
        <entry>
       +        <title>susmb: unprivileged mounting of SMB/CIFS shares via FUSE</title>
       +        <link rel="alternate" type="text/html" href="https://www.codemadness.org/susmb.html" />
       +        <id>https://www.codemadness.org/susmb.html</id>
       +        <updated>2026-03-06T00:00:00Z</updated>
       +        <published>2026-03-06T00:00:00Z</published>
       +        <author>
       +                <name>Hiltjo</name>
       +                <uri>https://www.codemadness.org</uri>
       +        </author>
       +        <summary>susmb: unprivileged mounting of SMB/CIFS shares via FUSE</summary>
       +</entry>
       +<entry>
                <title>Chess puzzle book generator</title>
                <link rel="alternate" type="text/html" href="https://www.codemadness.org/chess-puzzles.html" />
                <id>https://www.codemadness.org/chess-puzzles.html</id>
   DIR diff --git a/output/atom_content.xml b/output/atom_content.xml
       @@ -2,11 +2,122 @@
        <feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
                <title>Codemadness</title>
                <subtitle>blog with various projects and articles about computer-related things</subtitle>
       -        <updated>2025-12-14T00:00:00Z</updated>
       +        <updated>2026-03-06T00:00:00Z</updated>
                <link rel="alternate" type="text/html" href="https://www.codemadness.org" />
                <id>https://www.codemadness.org/atom_content.xml</id>
                <link rel="self" type="application/atom+xml" href="https://www.codemadness.org/atom_content.xml" />
        <entry>
       +        <title>susmb: unprivileged mounting of SMB/CIFS shares via FUSE</title>
       +        <link rel="alternate" type="text/html" href="https://www.codemadness.org/susmb.html" />
       +        <id>https://www.codemadness.org/susmb.html</id>
       +        <updated>2026-03-06T00:00:00Z</updated>
       +        <published>2026-03-06T00:00:00Z</published>
       +        <author>
       +                <name>Hiltjo</name>
       +                <uri>https://www.codemadness.org</uri>
       +        </author>
       +        <summary>susmb: unprivileged mounting of SMB/CIFS shares via FUSE</summary>
       +        <content type="html"><![CDATA[<h1>susmb: unprivileged mounting of SMB/CIFS shares via FUSE</h1>
       +        <p><strong>Last modification on </strong> <time>2026-03-06</time></p>
       +        <p>usmb is a program to mount SMB shares from userland via FUSE.
       +Under-the-hood it uses Samba and exposes the network share as a regular local filesystem.
       +Programs can just access the filesystem and for example do not need to add code for SMB support or link against Samba.
       +It is more convenient than scripting around smbclient in some cases.<br />  
       +smbclient(1): <a href="https://www.samba.org/samba/docs/current/man-html/smbclient.1.html">https://www.samba.org/samba/docs/current/man-html/smbclient.1.html</a></p>
       +<p>susmb is a fork of usmb from 2013-02-04.
       +<a href="http://repo.or.cz/w/usmb.git/snapshot/aa94e132c12faf1a00f547ea4a96b5728612dea6.tar.gz">http://repo.or.cz/w/usmb.git/snapshot/aa94e132c12faf1a00f547ea4a96b5728612dea6.tar.gz</a>
       +(git commit aa94e132c12faf1a00f547ea4a96b5728612dea6)</p>
       +<p>usmb has been unmaintained since 2013. Sometimes programs are finished and so
       +being unmaintained is not so bad. I think the general idea of the code was good
       +and it is still a useful program for some systems, probably mostly BSD systems.
       +Linux has a SMB/CIFS driver anyway.</p>
       +<p>The two main reasons I forked usmb were performance issues with it on OpenBSD
       +(because of hardcoded options and assumptions for FUSE for Linux) and issues by
       +using it in non-interactive mode.</p>
       +<h2>Clone</h2>
       +<pre><code>git clone git://git.codemadness.org/susmb
       +</code></pre>
       +<h2>Browse</h2>
       +<p>You can browse the source-code at:</p>
       +<ul>
       +<li><a href="https://git.codemadness.org/susmb/">https://git.codemadness.org/susmb/</a></li>
       +<li><a href="gopher://codemadness.org/1/git/susmb">gopher://codemadness.org/1/git/susmb</a></li>
       +</ul>
       +<h2>Download releases</h2>
       +<p>Releases are available at:</p>
       +<ul>
       +<li><a href="https://codemadness.org/releases/susmb/">https://codemadness.org/releases/susmb/</a></li>
       +<li><a href="gopher://codemadness.org/1/releases/susmb">gopher://codemadness.org/1/releases/susmb</a></li>
       +</ul>
       +<h2>Build and install</h2>
       +<pre><code>$ make
       +# make install
       +</code></pre>
       +<h2>Dependencies</h2>
       +<ul>
       +<li>C compiler.</li>
       +<li>libc + BSD extensions (libbsd on Linux).</li>
       +<li>FUSE 2.6 or later (and probably version &lt;3).</li>
       +<li>Samba / libsmbclient 4.20+.</li>
       +</ul>
       +<h2>Usage example</h2>
       +<pre><code>susmb \
       +        -u hiltjo \
       +        -f \
       +        -o 'uid=1000,gid=1000,allow_other' \
       +        "smb://domain\someuser@192.168.1.1/Storage" \
       +        /mnt/share
       +</code></pre>
       +<h2>Changes</h2>
       +<p>susmb has the patches applied from OpenBSD ports 7.6:
       +<a href="https://cvsweb.openbsd.org/ports/sysutils/usmb/patches">https://cvsweb.openbsd.org/ports/sysutils/usmb/patches</a></p>
       +<p>Below is a summary of the most important changes:</p>
       +<h2>Performance</h2>
       +<ul>
       +<li>Set struct stat st.st_blksiz to a higher number for more efficient buffering
       +for programs using the standard FILE* stdio interfaces. Huge improvement for
       +reads and writes.<br />  
       +On OpenBSD the default block size for FUSE is 512 bytes.
       +This crippled network performance.<br />  
       +On OpenBSD there is no FUSE caching layer (at time of writing 2025-09-07), so
       +each read call had more overhead.</li>
       +<li>Remove the hardcoded FUSE mount option max_read=N.<br />  
       +This crippled network performance.</li>
       +</ul>
       +<h2>Security</h2>
       +<ul>
       +<li>Many code simplifications and deletions (reducing attack surface and makes it
       +easier to review).</li>
       +<li>Use unveil(2) syscall to lock down much of the filesystem except the
       +mountpoint and required FUSE devices.</li>
       +<li>Optional privilege dropping support: on OpenBSD FUSE would need to run as root:
       +(sysctl kern.usermount was removed around July 2016, around
       +commit 65c8a8a0394483b41de8f02c862e65fb529cf538).<br />  
       +After mounting the filesystem and acquiring access to the FUSE driver
       +privileges are dropped. This is not perfect, but at least now the Samba smbclient
       +code runs as a user again.</li>
       +<li>Reading the password from the terminal in a secure way using readpassphrase(3).</li>
       +</ul>
       +<h2>Cleanups</h2>
       +<ul>
       +<li>Merge everything into one C file for easier code review.</li>
       +<li>Remove Samba &lt; 3.3 compatibility layer and code. This is hard to test
       +nowadays anyway.</li>
       +<li>Use getopt for option parsing: remove dependencies on glib which was used for
       +option parsing only.</li>
       +<li>Remove long option support.</li>
       +<li>Remove libxml2 dependency and configuration via XML. Configuration is now
       +done via a simpler syntax as a URI from the command-line. This was also
       +listed in the man page under the BUGS section as a wanted feature.</li>
       +<li>Remove autoconf and Debian-specific packaging files. Use a simple Makefile.</li>
       +<li>Man page rewritten from roff to mandoc.</li>
       +</ul>
       +<h2>OpenBSD port added as sysutils/susmb</h2>
       +<p>An OpenBSD port was added to sysutils/susmb (thanks to Pascal Stumpf!).</p>
       +<p>Mailinglist thread: <a href="https://marc.info/?l=openbsd-ports&amp;m=177169411929407&amp;w=2">https://marc.info/?l=openbsd-ports&amp;m=177169411929407&amp;w=2</a></p>
       +]]></content>
       +</entry>
       +<entry>
                <title>Chess puzzle book generator</title>
                <link rel="alternate" type="text/html" href="https://www.codemadness.org/chess-puzzles.html" />
                <id>https://www.codemadness.org/chess-puzzles.html</id>
   DIR diff --git a/output/atom_content_gopher.xml b/output/atom_content_gopher.xml
       @@ -2,11 +2,122 @@
        <feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
                <title>Codemadness</title>
                <subtitle>blog with various projects and articles about computer-related things</subtitle>
       -        <updated>2025-12-14T00:00:00Z</updated>
       +        <updated>2026-03-06T00:00:00Z</updated>
                <link rel="alternate" type="text/gopher" href="gopher://codemadness.org" />
                <id>gopher://codemadness.org/0/atom_content_gopher.xml</id>
                <link rel="self" type="application/atom+xml" href="gopher://codemadness.org/0/atom_content_gopher.xml" />
        <entry>
       +        <title>susmb: unprivileged mounting of SMB/CIFS shares via FUSE</title>
       +        <link rel="alternate" type="text/gopher" href="gopher://codemadness.org/1/phlog/susmb" />
       +        <id>gopher://codemadness.org/1/phlog/susmb</id>
       +        <updated>2026-03-06T00:00:00Z</updated>
       +        <published>2026-03-06T00:00:00Z</published>
       +        <author>
       +                <name>Hiltjo</name>
       +                <uri>gopher://codemadness.org</uri>
       +        </author>
       +        <summary>susmb: unprivileged mounting of SMB/CIFS shares via FUSE</summary>
       +        <content type="html"><![CDATA[<h1>susmb: unprivileged mounting of SMB/CIFS shares via FUSE</h1>
       +        <p><strong>Last modification on </strong> <time>2026-03-06</time></p>
       +        <p>usmb is a program to mount SMB shares from userland via FUSE.
       +Under-the-hood it uses Samba and exposes the network share as a regular local filesystem.
       +Programs can just access the filesystem and for example do not need to add code for SMB support or link against Samba.
       +It is more convenient than scripting around smbclient in some cases.<br />  
       +smbclient(1): <a href="https://www.samba.org/samba/docs/current/man-html/smbclient.1.html">https://www.samba.org/samba/docs/current/man-html/smbclient.1.html</a></p>
       +<p>susmb is a fork of usmb from 2013-02-04.
       +<a href="http://repo.or.cz/w/usmb.git/snapshot/aa94e132c12faf1a00f547ea4a96b5728612dea6.tar.gz">http://repo.or.cz/w/usmb.git/snapshot/aa94e132c12faf1a00f547ea4a96b5728612dea6.tar.gz</a>
       +(git commit aa94e132c12faf1a00f547ea4a96b5728612dea6)</p>
       +<p>usmb has been unmaintained since 2013. Sometimes programs are finished and so
       +being unmaintained is not so bad. I think the general idea of the code was good
       +and it is still a useful program for some systems, probably mostly BSD systems.
       +Linux has a SMB/CIFS driver anyway.</p>
       +<p>The two main reasons I forked usmb were performance issues with it on OpenBSD
       +(because of hardcoded options and assumptions for FUSE for Linux) and issues by
       +using it in non-interactive mode.</p>
       +<h2>Clone</h2>
       +<pre><code>git clone git://git.codemadness.org/susmb
       +</code></pre>
       +<h2>Browse</h2>
       +<p>You can browse the source-code at:</p>
       +<ul>
       +<li><a href="https://git.codemadness.org/susmb/">https://git.codemadness.org/susmb/</a></li>
       +<li><a href="gopher://codemadness.org/1/git/susmb">gopher://codemadness.org/1/git/susmb</a></li>
       +</ul>
       +<h2>Download releases</h2>
       +<p>Releases are available at:</p>
       +<ul>
       +<li><a href="https://codemadness.org/releases/susmb/">https://codemadness.org/releases/susmb/</a></li>
       +<li><a href="gopher://codemadness.org/1/releases/susmb">gopher://codemadness.org/1/releases/susmb</a></li>
       +</ul>
       +<h2>Build and install</h2>
       +<pre><code>$ make
       +# make install
       +</code></pre>
       +<h2>Dependencies</h2>
       +<ul>
       +<li>C compiler.</li>
       +<li>libc + BSD extensions (libbsd on Linux).</li>
       +<li>FUSE 2.6 or later (and probably version &lt;3).</li>
       +<li>Samba / libsmbclient 4.20+.</li>
       +</ul>
       +<h2>Usage example</h2>
       +<pre><code>susmb \
       +        -u hiltjo \
       +        -f \
       +        -o 'uid=1000,gid=1000,allow_other' \
       +        "smb://domain\someuser@192.168.1.1/Storage" \
       +        /mnt/share
       +</code></pre>
       +<h2>Changes</h2>
       +<p>susmb has the patches applied from OpenBSD ports 7.6:
       +<a href="https://cvsweb.openbsd.org/ports/sysutils/usmb/patches">https://cvsweb.openbsd.org/ports/sysutils/usmb/patches</a></p>
       +<p>Below is a summary of the most important changes:</p>
       +<h2>Performance</h2>
       +<ul>
       +<li>Set struct stat st.st_blksiz to a higher number for more efficient buffering
       +for programs using the standard FILE* stdio interfaces. Huge improvement for
       +reads and writes.<br />  
       +On OpenBSD the default block size for FUSE is 512 bytes.
       +This crippled network performance.<br />  
       +On OpenBSD there is no FUSE caching layer (at time of writing 2025-09-07), so
       +each read call had more overhead.</li>
       +<li>Remove the hardcoded FUSE mount option max_read=N.<br />  
       +This crippled network performance.</li>
       +</ul>
       +<h2>Security</h2>
       +<ul>
       +<li>Many code simplifications and deletions (reducing attack surface and makes it
       +easier to review).</li>
       +<li>Use unveil(2) syscall to lock down much of the filesystem except the
       +mountpoint and required FUSE devices.</li>
       +<li>Optional privilege dropping support: on OpenBSD FUSE would need to run as root:
       +(sysctl kern.usermount was removed around July 2016, around
       +commit 65c8a8a0394483b41de8f02c862e65fb529cf538).<br />  
       +After mounting the filesystem and acquiring access to the FUSE driver
       +privileges are dropped. This is not perfect, but at least now the Samba smbclient
       +code runs as a user again.</li>
       +<li>Reading the password from the terminal in a secure way using readpassphrase(3).</li>
       +</ul>
       +<h2>Cleanups</h2>
       +<ul>
       +<li>Merge everything into one C file for easier code review.</li>
       +<li>Remove Samba &lt; 3.3 compatibility layer and code. This is hard to test
       +nowadays anyway.</li>
       +<li>Use getopt for option parsing: remove dependencies on glib which was used for
       +option parsing only.</li>
       +<li>Remove long option support.</li>
       +<li>Remove libxml2 dependency and configuration via XML. Configuration is now
       +done via a simpler syntax as a URI from the command-line. This was also
       +listed in the man page under the BUGS section as a wanted feature.</li>
       +<li>Remove autoconf and Debian-specific packaging files. Use a simple Makefile.</li>
       +<li>Man page rewritten from roff to mandoc.</li>
       +</ul>
       +<h2>OpenBSD port added as sysutils/susmb</h2>
       +<p>An OpenBSD port was added to sysutils/susmb (thanks to Pascal Stumpf!).</p>
       +<p>Mailinglist thread: <a href="https://marc.info/?l=openbsd-ports&amp;m=177169411929407&amp;w=2">https://marc.info/?l=openbsd-ports&amp;m=177169411929407&amp;w=2</a></p>
       +]]></content>
       +</entry>
       +<entry>
                <title>Chess puzzle book generator</title>
                <link rel="alternate" type="text/gopher" href="gopher://codemadness.org/1/phlog/chess-puzzles" />
                <id>gopher://codemadness.org/1/phlog/chess-puzzles</id>
   DIR diff --git a/output/atom_gopher.xml b/output/atom_gopher.xml
       @@ -2,11 +2,23 @@
        <feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
                <title>Codemadness</title>
                <subtitle>blog with various projects and articles about computer-related things</subtitle>
       -        <updated>2025-12-14T00:00:00Z</updated>
       +        <updated>2026-03-06T00:00:00Z</updated>
                <link rel="alternate" type="text/gopher" href="gopher://codemadness.org" />
                <id>gopher://codemadness.org/0/atom_gopher.xml</id>
                <link rel="self" type="application/atom+xml" href="gopher://codemadness.org/0/atom_gopher.xml" />
        <entry>
       +        <title>susmb: unprivileged mounting of SMB/CIFS shares via FUSE</title>
       +        <link rel="alternate" type="text/gopher" href="gopher://codemadness.org/1/phlog/susmb" />
       +        <id>gopher://codemadness.org/1/phlog/susmb</id>
       +        <updated>2026-03-06T00:00:00Z</updated>
       +        <published>2026-03-06T00:00:00Z</published>
       +        <author>
       +                <name>Hiltjo</name>
       +                <uri>gopher://codemadness.org</uri>
       +        </author>
       +        <summary>susmb: unprivileged mounting of SMB/CIFS shares via FUSE</summary>
       +</entry>
       +<entry>
                <title>Chess puzzle book generator</title>
                <link rel="alternate" type="text/gopher" href="gopher://codemadness.org/1/phlog/chess-puzzles" />
                <id>gopher://codemadness.org/1/phlog/chess-puzzles</id>
   DIR diff --git a/output/index b/output/index
       @@ -11,6 +11,7 @@ i                codemadness.org        70
        i                codemadness.org        70
        iPhlog posts                codemadness.org        70
        i                codemadness.org        70
       +12026-03-06 susmb: unprivileged mounting of SMB/CIFS shares via FUSE        /phlog/susmb        codemadness.org        70
        12024-02-02 Chess puzzle book generator        /phlog/chess-puzzles        codemadness.org        70
        12023-11-22 xargs: an example for parallel batch jobs        /phlog/xargs        codemadness.org        70
        12023-11-20 Improved Youtube RSS/Atom feed        /phlog/youtube-feed        codemadness.org        70
   DIR diff --git a/output/index.html b/output/index.html
       @@ -39,6 +39,7 @@
                        <div id="main">
                                <h1>Posts</h1>
                                <table>
       +<tr><td><time>2026-03-06</time></td><td><a href="susmb.html">susmb: unprivileged mounting of SMB/CIFS shares via FUSE</a></td></tr>
        <tr><td><time>2024-02-02</time></td><td><a href="chess-puzzles.html">Chess puzzle book generator</a></td></tr>
        <tr><td><time>2023-11-22</time></td><td><a href="xargs.html">xargs: an example for parallel batch jobs</a></td></tr>
        <tr><td><time>2023-11-20</time></td><td><a href="youtube-feed.html">Improved Youtube RSS/Atom feed</a></td></tr>
   DIR diff --git a/output/jsonfeed.json b/output/jsonfeed.json
       @@ -3,6 +3,14 @@
        "title": "Newsfeed",
        "items": [
        {
       +        "id": "https://www.codemadness.org/susmb.html",
       +        "date_published": "2026-03-06T00:00:00Z",
       +        "title": "susmb: unprivileged mounting of SMB/CIFS shares via FUSE",
       +        "url": "https://www.codemadness.org/susmb.html",
       +        "authors": [{"name": "Hiltjo"}],
       +        "content_text": "susmb: unprivileged mounting of SMB/CIFS shares via FUSE"
       +},
       +{
                "id": "https://www.codemadness.org/chess-puzzles.html",
                "date_published": "2024-02-02T00:00:00Z",
                "title": "Chess puzzle book generator",
   DIR diff --git a/output/jsonfeed_content.json b/output/jsonfeed_content.json
       @@ -3,6 +3,14 @@
        "title": "Newsfeed",
        "items": [
        {
       +        "id": "https://www.codemadness.org/susmb.html",
       +        "date_published": "2026-03-06T00:00:00Z",
       +        "title": "susmb: unprivileged mounting of SMB/CIFS shares via FUSE",
       +        "url": "https://www.codemadness.org/susmb.html",
       +        "authors": [{"name": "Hiltjo"}],
codemadness.org:70 /git/www.codemadness.org/commit/9b2a439ea8b020383160bc4fd7d7bdc7a511583f.gph:397: line too long