April 25, 2020

Careful with io.TeeReader and json.Decoder

Some time ago, I was investigating very strange bug in our codebase: PROXY: ERROR: http: ContentLength=513 with Body length 512 It was inside our Go reverse proxy, and what was very suspicious was the exact 1 byte discrepancy. My suspicion was on gzip middleware, which is often the cause when you forget to set request.ContentLength after compressing the payload. However it turns out it was not the case. Do you see anything problematic here? Read more

December 2, 2019

How I manage passwords without loosing sanity

A lot has been said about passwords being bane of our society. And it is true. However, with some not-so-hard setup of software, it can be made bearable. The setup starts with *KeePass2 password safe. This is a program that allows you to store arbitrary data, but also specifically usernames, passwords and URLs that can be matched to find your saved password. It can also generate safe random passwords, set expiration, and a lot more. Read more

Powered by Hugo & Kiss.