Feed aggregator

Show HN: Hexi, modern header-only network binary serialisation for C++ hackers

Hacker News - Fri, 03/28/2025 - 1:37pm

Over the last few years, I've needed an easy way to quickly serialise and deserialise various network protocols safely and efficiently. Most of the libraries that existed at the time were either quite heavy, had less than stellar performance, or were an abstraction level above what I was looking for.

I decided to put together my own class to do the job, starting with an easy, low-overhead way to move bytes in and out of arbitrary buffers. Along the way, it picked up useful bits and pieces, such as buffer structures and allocators that made the byte shuffling faster, often being able to do it with zero allocations and zero copies. Safety features came along to make sure that malicious packet data or mistakes in the code wouldn't result in segfaults or vulnerabilities.

It's become useful enough to me that I've packaged it up in its own standalone library on the chance that it might be useful to others. It has zero dependencies other than the standard library and has been designed for quick integration into any project within minutes, or seconds with a copy paste of the amalgamated header. It can be used in production code but it's also ideal for for those that want to quickly hack away at binary data with minimal fuss.

Comments URL: https://news.ycombinator.com/item?id=43508061

Points: 7

# Comments: 0

Categories: Hacker News

April Fool's Day 2025 Pranks: Wearable Mattress, Cat Poo Scented Candle, Sports-Drink Shampoo

CNET Feed - Fri, 03/28/2025 - 1:37pm
If you see a weird product this week and next, don't be so sure it's real.
Categories: CNET

Windows 11 Roadmap

Hacker News - Fri, 03/28/2025 - 1:29pm
Categories: Hacker News

Best TV on a Budget for 2025

CNET Feed - Fri, 03/28/2025 - 1:29pm
You don't have to spend a lot of cash to get a good TV. Here are our top picks for the best budget televisions from Samsung, Roku and more.
Categories: CNET

Want To Go To College? Pay the College Board

SlashDot - Fri, 03/28/2025 - 1:14pm
Categories: SlashDot

AI Receptionist for Small Businesses

Hacker News - Fri, 03/28/2025 - 12:59pm
Categories: Hacker News

Pages