hrbrmstr's Daily Drop

Share this post

Drop #121 (2022-10-18): Go, Go [Go] Gadgets

dailyfinds.hrbrmstr.dev

Drop #121 (2022-10-18): Go, Go [Go] Gadgets

wtfutil; webhook; termshark

boB Rudis
Oct 18, 2022
Share this post

Drop #121 (2022-10-18): Go, Go [Go] Gadgets

dailyfinds.hrbrmstr.dev

Working in a shop with incredibly talented Golang engineers has given me a bit more appreciation of the language (FWIW Smalltalk is still the best, followed by Rust and R), so today's edition features three useful tools that even Inspector Gadget would find useful.

wtfutil

screenshot.jpg

Continuing on the regularly recurring theme of "more command line; less browser", meet wtfutil [GH]: the "personal information dashboard for your terminal," created by Chris Cummer (@senorprogrammer). The section banner image provides a glimpse into how wtfutil looks, and some of what it can do.

Dashboard blocks are managed in an (ugh) YAML file, where you control everything from page layout/theme and other global settings. You can incorporate one of a gazillion data modules to keep an eye on any bits of info from almost any source (including RSS feeds); or, you can roll your own. All information displayed can have a customized refresh rate, and the only real limits to this terminal dashboard are your imagination.

Wtfutil's YAML config file — like all ugly YAML files — gets overwhelming pretty fast. Thankfully, Georgi Gerganov (@ggerganov) heard you liked TUIs for your TUI configs, and made wtf-tui to help you manage the settings.

I'm slowly adding more blocks to mine and will drop a link to my config file when it stabilizes.

If you use wtfutil, drop some pointers in the comments for others.

Leave a comment

webhook

Virtually every decent "cloud" service supports webhooks of some fashion. Webhooks are nothing more than operations that are called when some event happens in some platform. Sec/Dev/Ops teams make great use of these for monitoring and job execution.

The unusually mundanely names webhook is a small footprint Golang server that "allows you to easily create HTTP endpoints (hooks) on your server, which you can use to execute configured commands. You can also pass data from the HTTP request (such as headers, payload or query variables) to your commands. webhook also allows you to specify rules which have to be satisfied in order for the hook to be triggered."

This highly focused server does four things and does them well:

  • receives webhook HTTP callback requests

  • parses the incoming headers, payload and query variable

  • checks ^^ against rules you define

  • pass arguments to a defined command line program as parameters or environment variables

Think of it as an automation-centric CGI server, and you can write the commands in any language you’re comfortable with.

The webhook rules are robust, and the docs provide security guidance to help ensure you don't compromise your system as you seek to orchestrate and automate all the things.

Hopefully more cloud services will support WireGuard (Tailscale, mentioned in the previous edition, is an easy path into the WireGuard ecosystem) so all infrastructure bits like this never have to be exposed to the internets again.

Share

termshark

demo24

Tshark is a command line network protocol analyzer, designed to process packets and spew out text streams. It's the CLI sibling of Wireshark, which is a full-on GUI that does the same things. Since a GUI exists, it may seem odd to want a TUI that wraps tshark, but sometimes you need a visual interface and don't have access to a proper screen, or you just prefer keeping things in terminal land. Network traffic data streams/files can be YUGE, so having something graphical on a remote system saves you from potentially time-crushing file transfers.

Termshark provides such a TUI for tshark in a robust single binary executable for every platform. It can:

  • read pcap files or sniff live interfaces

  • filter pcaps or live captures using Wireshark's display filters

  • reassemble and inspect TCP and UDP flows

  • view network conversations by protocol

  • copy ranges of packets to the clipboard from the terminal

If I'm testing out a new crawler or protocol client, Termshark has made it less painful to get immediate views into what I'm sending to a remote system (even if said system is headless and just on the other side of my home office).

It has a well-crafted user guide and an FAQ that likely has thought of any question you may have about the tool.

Share

FIN

I heartily encourage all 🇺🇸 readers to check out today's "Letters From An American" edition, as even with my mega media consumption setup, I missed the fact that this Administration brokered an historic diplomatic agreement between Israel and Lebanon. ☮

Share this post

Drop #121 (2022-10-18): Go, Go [Go] Gadgets

dailyfinds.hrbrmstr.dev
Previous
Next
Comments
TopNewCommunity

No posts

Ready for more?

© 2023 boB Rudis
Privacy ∙ Terms ∙ Collection notice
Start WritingGet the app
Substack is the home for great writing