An open API service indexing awesome lists of open source software.

https://github.com/davidegalilei/articles

Blog Articles I write in my spare time
https://github.com/davidegalilei/articles

articles blog python security

Last synced: 2 months ago
JSON representation

Blog Articles I write in my spare time

Awesome Lists containing this project

README

          

# Articles
- [Understanding and Preventing Race Conditions in Web Applications](001-prevent-race-conditions/)

This article explores race conditions in database operations using Python, FastAPI, and PostgreSQL. It demonstrates common pitfalls in handling concurrent requests, particularly for counters and resource management. The piece offers practical solutions, including atomic updates and database constraints, while emphasizing the importance of understanding concurrency issues in software development.

- [Python Generic Return Types](002-python-generic-return-types/)

This article demonstrates implementing generic return types in Python for RPC calls, inspired by Rust's approach in the gramme.rs library. It presents a solution using Protocol classes and TypeVars that eliminates manual type hinting in API interactions. Through concrete examples, it shows how to statically bind return types to function calls, offering both simple and advanced implementations that enhance code quality and static analysis while working within Python's type system limitations.

- [JavaScript Obfuscation Through File Stream Side-Channel](003-file-stream-side-channel/)

This article discusses a novel approach to obfuscating JavaScript code in web pages using file stream side-channel techniques. It explains how to encode JavaScript into binary code, translating it into delays that can be measured and decoded back into executable code. The article includes a demo and explores potential improvements and issues with this method.

# License
All my articles contained in this repository are licensed under the [CC0 1.0 Universal](https://creativecommons.org/publicdomain/zero/1.0/) license.