Daily Edition · Page 5

THE DAILY INDEX

Technology, AI, software, security, crypto and business

ARTICLES & TUTORIALS

TLDR Dev

FINDING ALL REGEX MATCHES HAS ALWAYS BEEN O(N²). EVEN IN THE ENGINES BUILT TO PREVENT IT

Most regex engines, despite advertising linear time for single matches, suffer from a quadratic (O(n²)) performance problem when finding all matches. RE# is a novel regex engine designed to resolve this by using a two-pass algorithm, a reverse and a forward DFA, to efficiently identify all leftmost-longest matches in guaranteed linear time. It has a "hardened mode" for linear performance against adversarial inputs, and its default mode is also quite fast.

CTRL-C IN PSQL GIVES ME THE HEEBIE-JEEBIES

The article uncovers a significant security vulnerability in how the `psql` command-line tool cancels PostgreSQL queries. When a user presses Ctrl-C, `psql` sends a `CancelRequest` over a new and separate connection that is always unencrypted, even if the main database connection is secured with TLS. This plaintext transmission creates a Denial-of-Service risk, as an attacker monitoring network traffic could intercept and replay these requests to cancel future queries on the same connection.

TLDR IndexPage 5