The Wiert Corner – irregular stream of stuff

Jeroen W. Pluimers on .NET, C#, Delphi, databases, and personal interests

  • My badges

  • Twitter Updates

  • My Flickr Stream

  • Pages

  • All categories

  • Enter your email address to subscribe to this blog and receive notifications of new posts by email.

    Join 1,860 other subscribers

Archive for July, 2023

Looking for maintainer(s) for fritzcap (Python project that captures calls from a Fritz!Box)

Posted by jpluimers on 2023/07/12

Given my health uncertainty, I am looking for maintainers for the fritzcap project (it captures calls from a Fritz!Box modem/router and is written in Python).

History

The fritzcap project was originally started in2007 by [Wayback/Archive] spongebob | IP Phone Forum, first as a binary fritzcap.exe Windows executable (see his first post at [Wayback/Archive] FritzBox: Tool für Etherreal Trace und Audiodaten-Extraktion | IP Phone Forum). In 2010 it became an open source Python project at [Wayback/Archive] Google Code Archive – Long-term storage for Google Code Project Hosting.

Read the rest of this entry »

Posted in About, Audio, Cloud, Communications Development, Containers, Development, Docker, ffmpeg, Fritz!, Fritz!Box, fritzcap, Hardware, HTTP, Infrastructure, Internet protocol suite, Media, Network-and-equipment, Personal, Power User, Python, Scripting, Software Development, TCP | Leave a Comment »

SUSE Preserves Choice in Enterprise Linux by Forking RHEL with a $10+ Million Investment | SUSE

Posted by jpluimers on 2023/07/11

https://www.suse.com/news/SUSE-Preserves-Choice-in-Enterprise-Linux/

Via

https://twitter.com/jilles_com/status/1678814306811379739

Posted in Uncategorized | Leave a Comment »

Figuring out the open network connections for processes ran by python

Posted by jpluimers on 2023/07/11

TL;DR:

pidof python | tr " " "\n" | xargs -r -n 1 lsof -i -a -e /run/user/1001/gvfs -p

Breakdown:

  • Getting the process IDs of any python process using pidof (most of my systems do not have pgrep installed):
    # pidof python
    26128 12583
    
  • Given the above list is space separated, and xargs prefers line separated, lets replace spaces with newlines (I showed this before in Source: firewalld: show interfaces with their zone details and show zones in use):
    # pidof python | tr " " "\n"
    26128
    12583
    
  • By default, xargs squashes all input on one line:
    # pidof python | tr " " "\n" | xargs echo
    26128 12583
    
  • To work around that, you can either use the -L 1 or -n 1 argument to keep them on separate lines:
    # pidof python | tr " " "\n" | xargs -L 1 echo
    26128
    12583
    # pidof python | tr " " "\n" | xargs -n 1 echo
    26128
    12583
    
  • Now lsof can not only show open files, but also IP sockets (-i), and *only* those (-a), for a specific process ID (-p #). So by having the -p as last argument, xargs will append the process ID after it:
    # pidof python | tr " " "\n" | xargs -n 1 lsof -i -a -p
    lsof: WARNING: can't stat() fuse.gvfsd-fuse file system /run/user/1001/gvfs
          Output information may be incomplete.
    lsof: WARNING: can't stat() fuse.gvfsd-fuse file system /run/user/1001/gvfs
          Output information may be incomplete.
    COMMAND   PID    USER   FD   TYPE  DEVICE SIZE/OFF NODE NAME
    python  12583 jeroenp    7u  IPv4 8347396      0t0  TCP 192.168.124.38:54576->192.168.124.23:1012 (ESTABLISHED)
    python  12583 jeroenp    8u  IPv4 8345460      0t0  TCP 192.168.124.38:48250->192.168.124.23:http (CLOSE_WAIT)
  • The lsof: WARNING: can't stat() fuse.gvfsd-fuse file system /run/user/1001/gvfs is a warning not easy to workaround in a short manner as per [Wayback/Archive] privileges – lsof: WARNING: can’t stat() fuse.gvfsd-fuse file system – Unix & Linux Stack Exchange (thanks [Wayback/Archive] pabouk  and [Wayback/Archive] jmunsch):

    In your case lsof does not need to check the GVFS file systems so you can exclude the stat() calls on them using the -e option (or you can just ignore the waring):

    lsof -e /run/user/1000/gvfs

    (via: [Wayback/Archive] lsof: WARNING: can’t stat() fuse.gvfsd-fuse file system /run/user/1001/gvfs – Google Search)

    So you get this:

    # pidof python | tr " " "\n" | xargs -n 1 lsof -i -a -e /run/user/1001/gvfs -p
    COMMAND   PID    USER   FD   TYPE  DEVICE SIZE/OFF NODE NAME
    python  12583 jeroenp    7u  IPv4 8347396      0t0  TCP 192.168.124.38:54576->192.168.124.23:1012 (ESTABLISHED)
    python  12583 jeroenp    8u  IPv4 8345460      0t0  TCP 192.168.124.38:48250->192.168.124.23:http (CLOSE_WAIT)
  • When there are no process IDs, you do not want to run lsof, and xargs has an argument just for that: -r, see my earlier post Source: -r argument to pipe (no argument for MacOS)- If no input is given to xargs, don’t let xargs run the utility – Unix & Linux Stack Exchange, so you get this
    # pidof python | tr " " "\n" | xargs -r -n 1 lsof -i -a -e /run/user/1001/gvfs -p

Via:

–jeroen

Posted in *nix, *nix-tools, bash, bash, Development, lsof, Power User, Scripting, Software Development, xargs | Leave a Comment »

how do I merge the tabs of two open Preview windows if I have more than two open? – Ask Different

Posted by jpluimers on 2023/07/10

That was more difficult than I anticipated: [Wayback/Archive] how do I merge the tabs of two open Preview windows if I have more than two open? – Ask Different

First of all, make sure that the “tab bar” is displayed by choosing “view”->”Show Tab Bar”. Then, you should be seeing the tab bar, which displays the file name:
enter image description here
Then, in the other preview window, click and hold the tab bar, and drag it onto the tab bar of the target preview window. Using this method, you can merge as many tabs as you want.
Tested on MacOS Catalina 10.15.4

Read the rest of this entry »

Posted in Apple, Mac OS X / OS X / MacOS, macOS 10.12 Sierra, macOS 10.13 High Sierra, Power User, Uncategorized | Leave a Comment »

NeverSSL – helping you get online on WiFi networks requiring authentication

Posted by jpluimers on 2023/07/07

[Wayback/Archive] NeverSSL – helping you get online.

What?

This website is for when you try to open Facebook, Google, Amazon, etc on a wifi network, and nothing happens. Type “http://neverssl.com” into your browser’s url bar, and you’ll be able to log on.

How?

neverssl.com will never use SSL (also known as TLS). No encryption, no strong authentication, no HSTS, no HTTP/2.0, just plain old unencrypted HTTP and forever stuck in the dark ages of internet security.

While writing it in 2022, the site would redirect me to http://oldserenewonderousbirds.neverssl.com/online, http://beautifulgrandoldspell.neverssl.com/online and http://majesticsilveroldeclipse.neverssl.com/online, which will change probably each time to deter DNS caching, as per this message when I disabled JavaScript:

⚠️ JavaScript appears to be disabled. NeverSSL’s cache-busting works better if you enable JavaScript for neverssl.com.

Why NeverSSL

Because NeverSSL always uses plain unencrypted HTTP traffic, any captive portal WiFi or wired network can easily sneak in or redirect to authentication.

That way you can logon, after which you can use encrypted HTTPS/SSL/TLS/HSTS traffic.

Via

DNS hijacking can be used too

Leading to the above was this post by b0rk: [Wayback/Archive] how airports lie to you with DNS.

Via:

–jeroen

Posted in Captive-WiFi-Portal, Power User, WiFi | Leave a Comment »

How To Use Twitter Search – Advanced Guide by @Luca – Fresh van Root

Posted by jpluimers on 2023/07/07

Need to check out which of these filters still work:

[Wayback/Archive] How To Use Twitter Search – Advanced Guide by @Luca – Fresh van Root

Operator Description
since:2019-05-06 Tweets published at or after the date. (UTC +0)
until:2019-05-07 Tweets published before the date. (UTC +0)
from:Luca Tweets that are not marked as sensitive media. Tweets published by a specific user.
to:Luca Replies and mentions for a specific user.
lang:de Tweets in a specific language. Language is detected by Twitter on a Tweet basis. “und” for Tweets where Twitter was unable to determine a language.
near:Berlin within:5km [unreliable] Tweets that were posted in specific locations and optionally within a certain range.
min_faves:5 Tweets with at least that amount of faves.
-min_faves:100 Tweets that have fewer faves than specified.
min_retweets:10 Tweets that were at least retweeted that many times.
-min_retweets:3 Tweets that were retweeted less than that many times
min_replies:70 Tweets that got a minimum amount of replies.
-min_replies:8 Tweets that got fewer replies. (max_replies does not work)
filter:follows Tweets by accounts you follow.
list:Luca/Science Tweets by accounts on a specified list.
filter:verified Tweets by verified accounts.
filter:images Tweets with an image.
filter:links Tweets with an URL.
filter:media Tweets with a video or a photo.
filter:retweets [only works with the API or with “include:nativeretweets”] Retweets.
filter:quote Tweets that contain a quoted Tweet.
filter:replies Tweets that are a reply.
filter:mentions Tweets that mention a user.
filter:videos Tweets that contain a video.
filter:native_video Tweets that contain a video, that was directly uploaded to Twitter.
filter:news [unreliable] Tweets that contain a URL to a news source.
filter:safe [unreliable] Tweets that do not contain sensitive material.
include:nativeretweets It allows you to search through retweets as well. Especially useful in combination with from:account or filter:follows.

–jeroen

Posted in Power User, SocialMedia, Twitter | Leave a Comment »

An unexpected turn of events when Jeff Geerling posted “I’m hosting my website on a FARM!”

Posted by jpluimers on 2023/07/06

Some links on the unexpected turn of events after [Archive] Jeff Geerling (@geerlingguy) / Twitter posted

First his site got more traffic because of the post, then within an hour traffic exploded because of a DDoS overflowing both his Raspberry Pi cluster and his mobile data capacity.

Jeff will likely do blog posts on these and update the underlying GitHub repository at [Wayback/Archive] geerlingguy/turing-pi-2-cluster: Turing Pi 2 Cluster , but until then (since his Tweets were not threaded), this is what happened on 20220209 as it taught me a few bits:

Read the rest of this entry »

Posted in Cloud, Cloudflare, Containers, Development, Docker, Hardware Development, Infrastructure, Internet, Kubernetes (k8n), LifeHacker, OpenSpeedTest, Power User, Raspberry Pi, SpeedTest | Leave a Comment »

Thanks Stephan Kämper for showing me how to validate HTML on-line at W3C

Posted by jpluimers on 2023/07/05

In Another difference between the and element in HTML&XHTML, I mentioned Stephan Kämper taught be about the W3C HTML NU validator in [Archive] Stephan Kämper on Twitter: “I try to write fairly simple & #valid #HTML ➙ …gist..Validating it with …online HTML-Validator…, I get the error ‘No p element in scope but a p end tag seen.‘ What? Why? Removing the list from the HTML, gets rid of the error… Why?!? I. don’t. get it. 1/2″ / Twitter.

Upon closer inspection, there are actually two w3c.org HTML validators, each operating in three modes:

  1. Default checker which is DTD-based:

    This validator checks the [Wayback/Archive] markup validity of Web documents in HTML, XHTML, SMIL, MathML, etc. If you wish to validate specific content such as [Wayback/Archive] RSS/Atom feeds or [Wayback/Archive] CSS stylesheets, [Wayback/Archive] MobileOK content (now retired), or to [Wayback/Archive] find broken links, there are [Wayback/Archive] other validators and tools available. As an alternative you can also try our [Wayback/Archive] non-DTD-based validator.

    1. [Wayback/Archive] The W3C Markup Validation Service: #validate_by_uri mode (without #validate_by_uri URL fragment) and

      default: checks the HTML of a URL

    2. [Archive] The W3C Markup Validation Service: #validate_by_upload mode

      you upload a file of which the HTML then gets checked

    3. [Archive] The W3C Markup Validation Service: #validate_by_input mode

      you enter the HTML to be checked into a text box

  2. NU checker which is non-DTD-based:
    1. [Wayback/Archive] Ready to check – Nu Html Checker; #address mode (without #address URL fragment) and

      default: checks the HTML of a URL

    2. [Archive] Ready to check – Nu Html Checker: #file mode

      you upload a file of which the HTML then gets checked

    3. [Archive] Ready to check – Nu Html Checker: #textarea mode

      you enter the HTML to be checked into a <textarea> element

Notes:

  1. that all three above modes get selected by a URL fragment (after a # hash) which the Wayback machine cannot individually save, but Archive.is can, hence the non-default URLs are not saved only in Archive.is, and not in the Wayback machine.
  2. The DTD-based checker seems non-functional and redirects all requests to the non-DTD-based checker.

I also took a look at the Wayback machine saved pages under the direct URLs of both checkers:

  1. https://web.archive.org/web/*/https://validator.w3.org/*
  2. https://web.archive.org/web/*/https://validator.w3.org/nu/*

I learned that the NU validator accepts at least these arguments:

Note that you cannot do this directly with HTML files saved in a gist or GitHub repository because it serves all RAW files as

[Wayback/Archive] text/plain MIME type. You can work around this by using a raw.githack.com trick I explained before at:

I also amended my above reply with more information using the ?doc= parameter with RAW gist files and archived that thread at [Wayback/Archive] Thread by @jpluimers on Thread Reader App – Thread Reader App.

–jeroen

Posted in Development, HTML, HTML5, Software Development, Web Development | Leave a Comment »

Another difference between the and element in HTML & XHTML

Posted by jpluimers on 2023/07/04

A few weeks after queueing What is the difference between <p>, <div> and <span> in HTML&XHTML?, Stephan Kämper posted an interesting other “TIL“.

Besides that TIL, it also taught me about an on-line HTML validator. Cool: I learned two things from Stephan that day!

The above post talked about phrasing versus non-phrasing elements, Stephan discovered another difference between the p and div elements:

Stephan’s TIL: [Archive] Stephan Kämper on Twitter: “TIL or Life (and the HTML specification) is full of wonders and surprises ➙ “List elements (in particular, ol and ul elements) cannot be children of p elements.” …” / Twitter

It was based on his quest [Archive] Stephan Kämper on Twitter: “I try to write fairly simple & #valid #HTML ➙ …gist..Validating it with …online HTML-Validator…, I get the error ‘No p element in scope but a p end tag seen.‘ What? Why? Removing the list from the HTML, gets rid of the error… Why?!? I. don’t. get it. 1/2″ / Twitter, which I archived at [Wayback/Archive] Thread by @S_2K on Thread Reader App – Thread Reader App.

I responded this: [Archive] Jeroen Wiert Pluimers on Twitter: “@S_2K I thought it would be something like explained in p/div/span differences But it is yet another html oddity where structural and logical concept are mixed in one language.” / Twitter.

Both his quest and tweet referred to this key documentation part: [Wayback/Archive] HTML Standard: grouping content; the p element; note on lists:

Read the rest of this entry »

Posted in Development, HTML, HTML5, Software Development, Web Development | 1 Comment »

Lissage Angels on Twitter: “Escher’s Rubik’s Cube ” / Twitter

Posted by jpluimers on 2023/07/03

[Archive] Lissage Angels on Twitter: “Escher’s Rubik’s Cube …” / Twitter

Read the rest of this entry »

Posted in LifeHacker, Mathematics, Power User, science | Leave a Comment »