221 results for "":
Crafting ICMP-bearing IPv4 packets with the help of bitvec
So. Serializing IPv4 packets. Easy? Well, not exactly.
IPv4 was annoying to parse, because we had 3-bit integers, and 13-bit integers, and who knows what else. Serializing it is going to be exactly the same.
Right now, we don’t have a way to serialize that.
Let’s take the version and ihl fields, both of which are supposed
to take 4 bits, together making a byte. We could serialize them like this:
Day 13 (Advent of Code 2022)
The day 13 puzzle needs a speech therapist.
???
…because it has an awful lisp!! Ahhhahahahhhh
Are you ok? What is.. what is going on with you?
No but seriously we have what are ostensibly S-expressions, except they use JSON-adjacent notation:
[1,1,3,1,1]
[1,1,5,1,1]
[[1],[2,3,4]]
[[1],4]
[9]
[[8,7,6]]
[[4,4],4,4]
[[4,4],4,4,4]
[7,7,7,7]
[7,7,7]
[]
[3]
[[[]]]
[[]]
[1,[2,[3,[4,[5,6,7]]]],8,9]
[1,[2,[3,[4,[5,6,0]]]],8,9]
Isaac rubs his back on non-existent doors
Haven’t blogged in a while. Life’s fine, project are a-plenty, but I just wanted to make a more lasting post about one particular issue that struck me as funny when programming Paper Isaac.
Bugs, bugs, bugs
What’s infuriating when letting others play an early prototype is that you hear constantly the same things. Some bugs are non-trivial to fix, some you’re just not motivated to fix now… sometimes you just have your head elsewhere, gotta focus, or are elbow-deep in some other piece of code and the damn walls can wait.
Game Design: The Binding of Isaac
In hours, I have played more of The Binding of Isaac than any other game in my Steam library. Edmund McMillen said he wasn’t expecting it to be a hit, and has since proceeded to be proven thoroughly wrong.
It is kind of a big deal among a certain crowd: as I’m writing this, the second season of the Binding of Isaac Racing League, hosted and commented by Crumps, is in full swing - even though the game was certainly not designed for that!
2020 Retrospective
Against all odds, it looks like the year 2020 will actually come to an end - in less than a day now. I know! Hard to believe for me too.
A lot of things have happened for me personally, and professionally. It’s been a big year in many ways, and I feel like, to get some closure, I need to highlight some of them.
From “looking at graphs” to “driving to the hospital”
GDB scripting and Indirect functions
itch.io app timeline 2016
I’ve been working on the itch.io desktop app for about a year now, so I thought I’d make a quick recap:
At the time of this writing, the app has been downloaded about 460K times (including updates). Not counting the back-end, the app and its various components are made up of around 100K lines of code (mostly javascript and golang), most of which is open-source.
The builder pattern, and a macro that keeps FFI code DRY
Our ping API is simple, but it’s also very limited:
pub fn ping ( dest : ipv4:: Addr ) -> Result <(), String >
// called as:
ping ( ipv4 :: Addr ([ 8 , 8 , 8 , 8 ])). unwrap ();
It doesn’t allow specifying the TTL (time to live) of packets, it doesn’t allow specifying the timeout, it doesn’t let one specify the data to send along, and it doesn’t give us any kind of information on the reply.
Printing ASCII cats to the terminal
Now that our development environment is all set up, let’s make something useful!
Creating the catscii crate
From a VS Code window connected to our VM (as we just set up), let’s make a new Rust project:
amos@miles:~$ cargo new catscii
Created binary (application) `catscii` package
And open it in a new VSCode window:
amos@miles:~$ code catscii