Category: development

Supershort Intro to TLS

Transport Layer Security Client & Server use a stateful connection over TCP The connection is secured using a symmetric encryption Client indicates to server to use TLS Client usually use a different port (e.g.443) A primary use of TLS is to secure World Wide Web traffic between a […]

Python AST: Evaluate an Expression

Do you want to convert a string of Python expression to Python object? Use ast $ cat myast.py import ast exDict = ‘{“name”: “1”}’ x = ast.literal_eval(exDict) print(x) $ python myast.py {‘name’: ‘1’} Another Example >>> import ast >>> x = u'[ “A”,”B”,”C” , ” D”]’ >>> x […]

Design: Brave Device Sync

The Brave Browser offers a sync facility that keeps bookmarks and browsing history across Brave browser installations. So your data from phone, laptop or iPad could all become one. All at the same time respecting your privacy. The current design of sync uses a device ID to identify […]

Dummies Guide to HTTP Cache Control

All modern browsers cache response for a request (HEAD/GET). Cache-Control is primarily meant for browser cache and how & where the server-side caches a response. Max Cache Time Browsers cache a response for the value of max-age response header If the response is expired, the browser can use […]