snac.bsd.cafe is a Fediverse instance that uses the ActivityPub protocol. In other words, users at this host can communicate with people that use software like Mastodon, Pleroma, Friendica, etc. all around the world.

This server runs the snac software and there is no automatic sign-up process.

Site description
This is the snac instance of the BSD Cafe
Admin email
stefano@bsd.cafe
Admin account
@stesnac@snac.bsd.cafe

Search results for tag #nginx

Felix Palmen :freebsd: :c64: »
@zirias@mastodon.bsd.cafe

Released: v0.1 🥳

Looking for a simple way to add to your reverse proxy? Then swad *could* be for you!

swad is the "Simple Web Authentication Daemon", written in pure (+ ) with almost no external dependencies. support requires (or ). It's designed to work with nginx' "auth_request" module and offers authentication using a and a login form.

Well, this is a first release and you can tell by the version number it isn't "complete" yet. Most notably, only one single credentials checker is implemented: . But as pam already allows pretty flexible configuration, I already consider this pretty useful 🙈

If you want to know more, read here:
github.com/Zirias/swad

    AodeRelay boosted

    Felix Palmen :freebsd: :c64: »
    @zirias@mastodon.bsd.cafe

    ... better start early I guess. What would you think of this sample file?

    Hint: the tokens surrounded by %% will be replaced by my build system before installing this thing.

    For context, this is a web service offering cookie+forms login meant for e.g. ' "auth_request".

    swad sample configuration page 1/3

    Alt...swad sample configuration page 1/3

    swad sample configuration page 2/3

    Alt...swad sample configuration page 2/3

    swad sample configuration page 3/3

    Alt...swad sample configuration page 3/3

      AodeRelay boosted

      Felix Palmen :freebsd: :c64: »
      @zirias@mastodon.bsd.cafe

      DId lots of smaller improvements to ... but first, I had to hunt down a crash 🤯. Finally found it was caused by my lib (to be fixed later): A connection there can resolve the hostname of a remote end and does so in a thread job to avoid blocking. If the connection dies meanwhile, the job is canceled. Seems my canceling mechanism relying on a signal to the thread is, well, not reliable (the signal can arrive delayed). Ok, for now just disabled name resolution to sidestep that.

      Now, integration with is much better. I intrdoduced (optional) custom headers to transport the authentication realm and the redirect URI, plus state management in the session, so these can be passed to the "auth" endpoint. This requires to make sure nginx always passes the session , Unfortunately, I still need a "hacky" redirect configuration for login in nginx. If auth_request could just pass the response body, this would be unnecessary .... 🙄

      The nginx configuration shows running on "files" and another nginx running on "wwwint" serving output there. This nginx instance helpfully adds cache hints, which I have to override, so a redirect works as expected when for example the swad session times out.

      Full nginx configuration integrating swad for authentication

      Alt...Full nginx configuration integrating swad for authentication

      swad log output showing bots trying unauthenticated access

      Alt...swad log output showing bots trying unauthenticated access

        mascal »
        @mascal@bench.thebus.top

        Deploying (https://anubis.techaro.lol/) to stop AI crawlers overburdening your servers using and , from @schahn@mastodon.social: https://blueslugs.com/2025/03/27/deploying-anubis-on-nginx/

        The Anubis project is still very fresh and got a sudden popularity, but it's definitely something to follow.

        Hopefully I'm in the smolweb side and only shitpost, so I don't need it :D

          AodeRelay boosted

          Martin Owens :inkscape: »
          @doctormo@floss.social

          I've set up my new website AI bot tar-baby. It works by giving everyone a chance to not fall into it.

          An anchor link that says "I am a bot" and links to /tar-baby/{datetime}/ it's got a fixed position at top -100px so should never be seen

          The robots.txt says "Disallow: /tar-baby/" so if you were reading the robots, you'd know.

          Then logs the requests to tar-baby/ to a log of their ip-addresses and browser strings and sends them a 301 redirect to google.com

          1/2

            Felix Palmen :freebsd: :c64: »
            @zirias@mastodon.bsd.cafe

            First "production test" successful 💪 ... after band-aid "deployment" (IOW, scp binaries to the prod jail).

            integrates with exactly as I planned it. And authentication using a child process running as root also just works (while the main process dropped privileges). 🥳

            So, I guess I can say goodbye to hammering my poor DSL connection just to download poudriere build logs.

            Still a lot to do for : Make it nicer. So many ideas. Best start would probably be to implement more credentials checking modules besides PAM.

            nginx configuration fragment for my build logs, using authentication provided from my new service

            Alt...nginx configuration fragment for my build logs, using authentication provided from my new service

            nginx configuration fragment integrating my new authentication service

            Alt...nginx configuration fragment integrating my new authentication service

            Syslog output of my new authentication service, and a process list output showing it's running as 'nobody', but with a pam helper running as 'root'

            Alt...Syslog output of my new authentication service, and a process list output showing it's running as 'nobody', but with a pam helper running as 'root'

              Xavier «X» Santolaria :verified_paw: :donor: »
              @0x58@infosec.exchange

              📨 Latest issue of my curated and list of resources for week #13/2025 is out!

              It includes the following and much more:

              ➝ DNA of 15 Million People for Sale in Bankruptcy,

              administration accidentally texted a journalist its war plans,

              ➝ Critical Ingress controller vulnerability allows RCE without authentication,

              hits Ukraine's state railway,

              ➝ Troy Hunt's Mailchimp account was successfully phished,

              Offering $100K Bounties for Critical ,

              AI is now available in for users in 41 European countries... and cannot be turned off

              Subscribe to the newsletter to have it piping hot in your inbox every week-end ⬇️

              infosec-mashup.santolaria.net/

                AodeRelay boosted

                Felix Palmen :freebsd: :c64: »
                @zirias@mastodon.bsd.cafe

                Trying to come up with my own little self-hosted to work with ' "authentication request" facility ... first step done! 🥳

                Now I have a subset of HTTP 1.x implemented in , together with a dummy handler showing nothing but a static hello-world root document.

                I know it's kind of stubborn doing that in C, but hey, it is great fun 🙈

                github.com/Zirias/swad

                  thedæmon »
                  @thedaemon@snac.9front.club

                  Any tips on setting up snac on FreeBSD? I always have difficulty figuring out https and ssl.. Using nginx, freebsd 14.2, snac.

                    AodeRelay boosted

                    Felix Palmen :freebsd: :c64: »
                    @zirias@mastodon.bsd.cafe

                    I just realized "basic auth" won't do it, because I'd effectively lock myself out when on my work notebook. That's because Microsoft decided basic auth is insecure. 🙄

                    Well, I still have some working C code somewhere that implements a simple HTTP/1.1 server which supports registering handlers for routes ... let's see whether I can use that to build some service to use with "auth_request", offering form+cookie auth with a PAM backend. Could after all be a fun project. 🙈

                      Felix Palmen :freebsd: :c64: »
                      @zirias@mastodon.bsd.cafe

                      @bagder Wow. For a few months, I was wondering why I suddenly have bandwidth issues when activating my camera in MS Teams meetings, so others can't understand me any more.

                      A look into my logs seems to clarify. Bots are eagerly fetching my (partially pretty large) build logs. 🧐 ( "watching shit scroll by"?)

                      I see GPTBot at least occassionally requests robots.txt, which I don't have so far. Other bots don't seem to be interested. Especially PetalBot is hammering my server. And there are others (bytedance, google, ...)

                      Now what? Robots.txt would actually *help* well-behaved bots here (I assume build logs aren't valuable for anything). The most pragmatic thing here would be to add some http basic auth in the reverse proxy for all poudriere stuff. It's currently only public because there's no reason to keep it private....

                      Have to admit I feel inclined to try one of the tarpitting/poisoning approaches, too. 😏

                        Marcus Noble »
                        @Marcus@k8s.social

                        If you're running ingress-nginx in your Kubernetes cluster please take a look at this latest CVE details, it's a big one! Patches are out so please get updating as soon as you can!

                        kubernetes.io/blog/2025/03/24/

                          AodeRelay boosted

                          James Seward »
                          @jamesoff@mastodon.jamesoff.net

                          @Edent > and reverse proxy manager installed. Probably done that right. No idea if it'll survive a reboot.

                          Reboot now to check while you have all the context in your brain to fix it.

                            Neil Brown boosted

                            Terence Eden »
                            @Edent@mastodon.social

                            Right!

                            installed. Most of my media reorganised and indexed.

                            deleted. I can't be bothered running it 24/7 on my phone.

                            and reverse proxy manager installed. Probably done that right. No idea if it'll survive a reboot.

                            set up with Dynamic DNS. No SSL errors!

                            HD Streaming over 5G works - but will have to see how adaptive it is on shitty hotel WiFi.

                            Bit of a faff, but seems to be working. Next step is configuring a Fire Stick to work with it.

                              AodeRelay boosted

                              /dev/fd0 »
                              @fd0@social.freebsd.amsterdam

                              do you have anything in between and ?

                              I am currently unable to find a way to get rid of the

                              # webfinger
                              location /.well-known/webfinger {
                              proxy_pass http://localhost:8001;
                              proxy_set_header Host $http_host;
                              proxy_set_header X-Forwarded-For $remote_addr;
                              }

                              and the like in

                                Alessandro »
                                @alemelandri@mastodon.uno

                                In my journey on and securing my VPS, I was able to setup on , but on a Mac it’s barely usable.
                                Browser keeps asking for username and password to access system keychain, no matter what I do.
                                Am I missing something?

                                  partizan boosted

                                  Stefano Marinelli »
                                  @stefano@mastodon.bsd.cafe

                                  I was thinking about how it was possible to stop using a gem like HAProxy for so long. It used to be my go-to choice, but then I switched to using Nginx for everything, and I almost forgot about it.
                                  Well, it’s great to reconnect with old friends!

                                    Joel Carnat ♑ 🤪 :runbsd: »
                                    @joel@piou.foolbazar.eu

                                    The (1) AI bots have merged into a single Mecha; limiting the number of duplicated code line and speeding the process a bit. Also is now using a dedicated log format to ease the parsing process.

                                    I think it can still be optimized using the mantra: no matter how, if you bug me, I’ll just chop your head off.

                                      partizan boosted

                                      Stefano Marinelli »
                                      @stefano@mastodon.bsd.cafe

                                      Question: Nginx or HAProxy as a reverse proxy? I’ve tested both. In some cases, I still need nginx, while in others, after a closer look, it’s not necessary.
                                      Performance, etc.
                                      Opinions from those who use/have used both?

                                        Jan ☕🎼🎹☁️🏋️‍♂️ »
                                        @jan@fedi.kcore.org

                                        Really struggling getting an config to do what I want.

                                        It's easy imho:

                                        ```
                                        root /var/www/blank;

                                        location /pma/ {
                                        alias /path/to/phpmyadmin;
                                        }

                                        location / {
                                        alias /path/to/my/webroot;
                                        }

                                        yet, it always keeps resolving paths from the root. I don't get it.

                                        It's probably gotta be something really silly.

                                          ScriptFanix ❤️ ⏚ ⸫ »
                                          @ScriptFanix@maly.io

                                          Dites, c'est possible d'observer le trafic FPM sur une socket ? J'ai un petit soucis avec NextCloud dans un cas bien spécifique. Au début c'était HAProxy qui posait problème, mais de ce côté c'est réglé. Par contre, j'ai qui ferme la connexion vers HAProxy prématurément lors du d'un morceau de musique. Du coup je voudrais voir si c'est NGinX qui a un problème, ou ?
                                          NGinX et PHP-FPM communiquent via une socket, sinon j'aurais tout simplement fait un tcpdump...

                                            gemelen »
                                            @gemelen@mammut.moe

                                            I'm doing a bit of my own server revamp and one of the points is a decision: stay with Nginx or switch to Caddy.
                                            For my loads I could run bashttpd, so it's only about the comfort of setting up, configuring, is it secure enough and so on.

                                            I went for a JSON format for caddyfile (to see what you could do) and it's prohibitevly bad admin-wise....

                                            Sidenote, this exploration blog.tjll.net/reverse-proxy-ho shows that you want Nginx as your production proxy and Caddy for file delivery.

                                              jhx »
                                              @jhx@mastodon.bsd.cafe

                                              Stuart Longland (VK4MSL) »
                                              @stuartl@mastodon.longlandclan.id.au

                                              This afternoon, I got close to what I wanted to achieve in terms of load-balancing between the two I have running.

                                              I had originally planned to use 's or to do the job, but protocol was the limiting factor… so I went instead.

                                              One thing I haven't worked out yet, is how to pass the client IP by PROXY protocol to a HTTP back-end. Seems I can do it for a generic TCP stream, but not HTTP.

                                              The alternative is to set X-Forwarded-For, and have the back-ends trust it, like they trust PROXY for the gateway's IPv4 address for .

                                              But… it works, you can hit sabot.vk4msl.com/ and you'll either get sabot01 (which uses nepenthes) or sabot02 (which uses iocaine). Since neither cares about the URI, I can bounce the client between them.

                                              This did get me thinking though, if enough of us did it, we could have a for websites to redirect/link to when they think they're being scraped by an AI bot.

                                              We could provide a pool of servers that would provide the link maze. Front-end proxies would just bounce you between all the pool members, feeding your bot nonsense.

                                                Stuart Longland (VK4MSL) »
                                                @stuartl@mastodon.longlandclan.id.au

                                                It appears that running as a load-balancer on can sometimes cause the host to run away and seize up… to the point that `sshd` either times out or refuses connections … and serial console will ask for a username, then hang rather than asking for a password.

                                                I got my father to power cycle the router, but no dice, the machine did not recover.

                                                So one house call later, turns out a file in /var was causing fsck_ffs to barf.

                                                One `fsck_ffs` later, a reboot, and we were back on-air.

                                                I logged in and disabled/stopped `nginx`, and now back at base, I've deployed a new VM to act as the load balancer. Thus, if it prangs that machine up, who cares… I can remote reset it.

                                                  Jan <3 boosted

                                                  yawnbox :rebel: »
                                                  @yawnbox@disobey.net

                                                  ouch

                                                  nginx 1.27.4 out

                                                  [nginx-announce] nginx-1.27.4

Sergey Kandaurov pluknet at nginx.com
Wed Feb 5 17:10:26 UTC 2025
Previous message (by thread): [nginx-announce] njs-0.8.9
Next message (by thread): [nginx-announce] nginx-1.26.3
Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Changes with nginx 1.27.4                                        05 Feb 2025

    *) Security: insufficient check in virtual servers handling with TLSv1.3
       SNI allowed to reuse SSL sessions in a different virtual server, to
       bypass client SSL certificates verification (CVE-2025-23419).

    *) Feature: the "ssl_object_cache_inheritable", "ssl_certificate_cache",
       "proxy_ssl_certificate_cache", "grpc_ssl_certificate_cache", and
       "uwsgi_ssl_certificate_cache" directives.

    *) Feature: the "keepalive_min_timeout" directive.

    *) Workaround: "gzip filter failed to use preallocated memory" alerts
       appeared in logs when using zlib-ng.

    *) Bugfix: nginx could not build libatomic library using the library
       sources if the --with-libatomic=DIR option was used.

    *) Bugfix: QUIC connection might not be established when using 0-RTT;
       the bug had appeared in 1.27.1.

    *) Bugfix: nginx now ignores QUIC version negotiation packets from
       clients.

    *) Bugfix: nginx could not be built on Solaris 10 and earlier with the
       ngx_http_v3_module.

    *) Bugfixes in HTTP/3.


-- 
Sergey Kandaurov

                                                  Alt...[nginx-announce] nginx-1.27.4 Sergey Kandaurov pluknet at nginx.com Wed Feb 5 17:10:26 UTC 2025 Previous message (by thread): [nginx-announce] njs-0.8.9 Next message (by thread): [nginx-announce] nginx-1.26.3 Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] Changes with nginx 1.27.4 05 Feb 2025 *) Security: insufficient check in virtual servers handling with TLSv1.3 SNI allowed to reuse SSL sessions in a different virtual server, to bypass client SSL certificates verification (CVE-2025-23419). *) Feature: the "ssl_object_cache_inheritable", "ssl_certificate_cache", "proxy_ssl_certificate_cache", "grpc_ssl_certificate_cache", and "uwsgi_ssl_certificate_cache" directives. *) Feature: the "keepalive_min_timeout" directive. *) Workaround: "gzip filter failed to use preallocated memory" alerts appeared in logs when using zlib-ng. *) Bugfix: nginx could not build libatomic library using the library sources if the --with-libatomic=DIR option was used. *) Bugfix: QUIC connection might not be established when using 0-RTT; the bug had appeared in 1.27.1. *) Bugfix: nginx now ignores QUIC version negotiation packets from clients. *) Bugfix: nginx could not be built on Solaris 10 and earlier with the ngx_http_v3_module. *) Bugfixes in HTTP/3. -- Sergey Kandaurov

                                                    Ángel boosted

                                                    Stefano Marinelli »
                                                    @stefano@fedihome.stefanomarinelli.it

                                                    0 ★ 1 ↺

                                                    Stefano BSD Cafe (snac instance account) »
                                                    @stesnac@snac.bsd.cafe

                                                    Stefano Marinelli »
                                                    @stefano@mastodon.bsd.cafe

                                                    AodeRelay boosted

                                                    IT Notes »
                                                    @itnotes@snac.it-notes.dragas.net

                                                    AodeRelay boosted

                                                    brian »
                                                    @brian@farty.toot.monster

                                                    For anyone who has snac deployed with httpd on OpenBSD (especially on a resource-restricted system) and is running into lag, errors, or service crashes, I highly recommend using nginx instead of httpd. Nginx--in addition to simply being faster in general--provides easy access to media caching (see @stefano@bsd.cafe's excellent article) and robust rate-limiting/traffic throttling controls.

                                                    Switching and properly tuning my nginx config seems to be (mostly) shielding my little VPS from being overwhelmed when someone with thousands of followers boosts one of my posts.


                                                      AodeRelay boosted

                                                      Justine Smithies »
                                                      @justine@snac.smithies.me.uk

                                                      My own preference is FreeBSD and for my static website and my fediverse server.

                                                        Dan Langille »
                                                        @dvl@bsd.network

                                                        The cert for forums.nginx.org is still expired.

                                                          The Real Grunfink »
                                                          @grunfink@comam.es

                                                          Sysadmin extraordinaire Stefano Marinelli (@stefano@bsd.cafe) has written this great, concise article on how to tune to improve performance while serving media like images or videos.

                                                          https://it-notes.dragas.net/2025/01/29/improving-snac-performance-with-nginx-proxy-cache/

                                                            T M Liddelow boosted

                                                            Stefano Marinelli »
                                                            @stefano@mastodon.bsd.cafe

                                                            IT Notes »
                                                            @itnotes@snac.it-notes.dragas.net

                                                            Jcrabapple boosted

                                                            Stefano Marinelli »
                                                            @stefano@mastodon.bsd.cafe

                                                            Publishing a photo of approximately 4MB from my snac instance (at home with 20 Mbit/sec uplink) meant overwhelming everything.
                                                            This happened because, for every remote instance, Nginx was requesting the multimedia file from snac. However, due to saturated connections, it took several seconds, leading to thread exhaustion in snac.
                                                            I resolved this issue by caching the multimedia files myself using Nginx, which significantly improved performance.

                                                            This matter will be covered in a subsequent (simple) blog post.

                                                              dch :flantifa: :flan_hacker: boosted

                                                              Dan Langille »
                                                              @dvl@bsd.network

                                                              Any devs here?

                                                              The cert for forum.nginx.org has expired.

                                                                Tom »
                                                                @pertho@mastodon.bsd.cafe

                                                                Hey people! What is your "go to" monitoring tool? Prometheus/Grafana? Uptime-Kuma? *shiver* DataDog?

                                                                Anything with nice graphs? I'm looking for something to monitor machines with the possibility to get into the nitty-gritty of PHP/Web/Nginx/MySQL type of monitoring. All the stuff that lets you delve into it seems to be commercial (think: NewRelic, etc)

                                                                There has to be decent FOSS tools for this kind of thing, isn't there?

                                                                  DokuWiki »
                                                                  @dokuwiki@phpc.social

                                                                  Calling all experienced users! 🚒

                                                                  Can you help tidying up the DokuWiki Nginx guide?

                                                                  dokuwiki.org/install:nginx

                                                                  Please be bold in editing! Remove any clutter, streamline instructions, and make it shine!