Create a node js websocket and secure it with let's encrypt
abhai
28 December 2021
This article basically describes how to create a node js websocket and secure it using let's encrypt. Because the wss differs from https, it's slightly tricky to do this directly on the node js server directly using self signed certificates which is why I'm using nginx in front of it.
Tags
A simple asynchronous reverse proxy in Rust
abhai
25 September 2020
In my previous article, I had written a very simple and basic reverse proxy. It is just like Nginx but without all the usefulness. In this new code, I have used tokio.rs. Tokio provides runtimes for asynchronous programming. A runtime bundles services together and makes a single type of (for want of a better word) process, service, runtime, etc. This makes it easier to shut down, started, etc. In the code below, I have used TcpStream and TcpListener from the tokio library and not std. I have also spawned for tokio threads and within that, tokio tasks, which are sort of like green threads, but not quite because Rust does not natively support it.
A simple reverse proxy server in Rust
abhai
24 September 2020
I wanted the application I write to be able to run well on a raspberry pi zero. And Rust could do all this extremely well. Apart from that, Rust is the safest language ever. And it's not like when Java says that it's secure. Rust means it and has gone above and beyond to make sure you can only write safe and secure code. It does this because it has one of the most advanced and thorough compilers, that WILL NOT compile your code unless it is safe. I choose Rust. Q.E.D.