Calling Golang functions from Haskell

Calling C from Haskell is easy. Calling Golang from C is easy too. Then why should calling Golang from Haskell be tough? Yet, I could not find a single document / blog on this topic. While doing this, I also explored the possibility domain of library linking in Haskell.

My latest project (in Haskell) required a cryptographic protocol (Verifiable Random Function), whose implementation I could only find in Golang and C. The Golang ones seemed better maintained, self-contained, and understandable. So, I took the easy way out, and wrote a binary using that source code, allowing me to call the binary from Haskell (taking care to marshall the input and output binary data as base64 strings). Of course, this was ugly, and I got a (mostly) satisfying solution working, which did not have to launch a separate process for this simple task....

Read more

Exploring Dynamic and Static linking

Things no one told me about EFI

About one and a half years later, I finally thought it is time to reinstall Windows for completeness sake (don’t judge me please). Little did I know that I would be opening a pandora’s box.

So I never really understood the concept of EFI, or the difference between BIOS/UEFI; and yet, I have played around with bootloaders for quite a while now. I somehow managed to survive ...

Read more

Fixing up my laptop's bootloader and partitions

Interning at Google Seattle

Now that I’m back from the US, the extravaganza that is Google, reminiscing back to those days has made me finally decide to pen down my experience in the Cloud city, working on Cloud.

For context, I interned at Google Seattle, the third largest Google office in the US. The Seattle ...

Read more

My experiences working in the Kubernetes team, and more

My internship interview saga

So, after months of worrying, I had finally landed an internship position at Google Seattle, in the team of my choice. But before I could stop being lazy and sign the offer letter, something happened ...

Read more

I finally had a dream internship offer. But something changed...

Coding software-based mutex algos for fun

I learnt a couple of nice scheduling algorithms in my Operating Systems class last semester. They seemed like an interesting bunch, but it was not generally clear whether their performance would be good.

Now, what better a way to understand them than by coding them up? ...

Read more

Rather than memorize the algos for my exam :)

ZSH globbing to play music

Too lazy to learn to use the awesome cmus, and living on an (very regrettably) extremely unorganized music library since I came to IIT Kanpur, yeah that’s me these days when it comes to music. Without the likes of Spotify in India, I’ve been living on YouTube since more than 2 years, when I used to have a fully organized music library back in my school days.

Having a very dynamic (and mostly incomplete) music library, I was constantly being annoyed having to import folders, sort some, organize others. What would be ideal in such a scenario is a way to live in the shell itself, but have the freedom to easily search for music files and play them. ...

Read more

Shell scripting for profit :)

Anonymous, zero-server-trust couple matching - Part 1

NOTE:: The algorithm used has been re-worked, and changed since this article was written. Expect a new article with the formal algorithm soon :)

Update: The new article with the latest algorithm is here on my blog. Do read that article as a follow up!

The queerly named Puppy Love platform has been running in my university since 2014, meant to help shy nerds meet their crush, made my the Programming Club (of which, I happen to be the current coordinator)...

Read more

IITK's "Puppy-Love" reborn

moVi - Mobile video protocol (Part 1)

After a really late start to my undergraduate project (UGP) this semester, I finally started working on something we call moVi.

First off, if the idea reminds you of mosh - Mobile Shell by Keith Winstein and Hari Balakrishnan of MIT, it is not a coincidence. I’d loved their paper called Mosh: An Interactive Remote Shell for Mobile Clients, and moVi is in a way taking their idea forward...

Read more

My undergraduate project (semester 5)