Latest Posts (20 found)

Inside PyPy: first contact with RPython

I get restless now and then and I want to implement a programming language. Then after mustering the resolve, I stew, for there is no good implementation language. 1 What am I to do, build my own programming language so that I can then use it to implement the first language? So I go back to modifying an existing implementation instead. There do exist established general-purpose tools for building fast programming language implementations: And more nascent ones such as Deegen , which was used to reimplement Lua. They each take different approaches: While none of these spark joy , they do each have benefits, including accomplishing the primary goal of offloading a lot of the language runtime choices and nasty details. In this post we will take a first look at RPython because it is the kind of VM implementor’s programming language that I keep thinking about. More on that later. Before we continue, please heed this warning: RPython is an implementation detail of PyPy. It has not had the years of polish that the rest of the system has had. Please do not badger maintainers. We’re going to build a little program in RPython. I am mostly following along with the docs , specifically Getting Started with RPython . There’s a little more ceremony than you might be used to and that’s because we’re going to run this file in two modes: normal Python 2 interpreter and compiled to C. This is the weirdness of RPython. If you don’t have installed, you can install PyPy, which helpfully still implements Python 2. If this all went fine, you will see it print . None of this is RPython yet . For that, we need a hint more ceremony. This is when we clone the PyPy project, in which we will find RPython. Now edit the Python program. Below the definition, add the following function: This function looks unused, but it is actually a hint to RPython: this is where the compiler should start translating. Let us now compile this program. Either inside the PyPy directory or with , run: If all goes well, you will see a whole mess of output, including a partially rendered Mandelbrot fractal. Finally, you will see something like: This is the RPython compilation process. In it, RPython is analyzing types, removing memory allocations, monomorphizing functions, and generating C code. Then it hands this C code off to a C compiler to compile. You should have in your current directory an executable named , which you can run like . It should also print . So far, this is not so different from Python. But let’s try something Pythonic. Let’s see what happens when we also use to mean string concatenation. Under normal Python 2, this will work just fine, printing and then . Under RPython, though, you get this inscrutable error (again, rough edges): and are unceremoniously dropped into the debugger, Pdb (hit Ctrl-D or type ). From this message you are meant to intuit that RPython did not enjoy that two different types flowed into the function. It helpfully tells you that there was a when trying to reconcile the and types that flowed into the function’s first parameter. It then gives you a pointer to the offending line and an IR dump. This happens because RPython requires function parameters to be monomorphic. Though the variables are syntactically untyped, RPython computes a type analysis to discover what type each variable should be. When and both flow into , boom, complaint. 2 To get around this, we do what all good C++ programmers do and we templatize the function. The RPython spelling of this is, as with many other features, a function annotation: You will find now that RPython happily compiles the program. This works because it makes a new copy of for every input type of the first ( ) argument. “Hey wait a minute,”, you might ask, “doesn’t this mean it stops being a valid Python 2 program?” Great question. No. You can still run the program as long as you provide the location of the RPython libraries via (as before): This runs ~instantly, which is a big relief. Developing an interpreter project with a 30 second or more turnaround time for each compile would be really frustrating. This has been a taste of RPython, both great and somewhat frustrating. I intentionally made it about RPython as a programming language rather than being so focused on RPython as a programming language implementation tool because I want some of its features to exist in a general purpose programming language… that then also might be used to implement other programming languages. I bring it up because I want to rehash the stuff that I occasionally grumble about in the vicinity of PLDI but for some reason have not written about online. Perhaps writing about it will encourage people. I think there is a lot of good stuff in RPython: I wish some stuff were different, or at least modifiable: I will probably add more to this list as I continue to remember some years of these conversations. Wouldn’t this be great? I don’t really have the time, energy, or expertise to build such a thing. There are so many design decisions along the way. It would probably accidentally grow to be huge and ossify along the way, and what a bummer that would be. If you have any pointers to existing projects or a way to implement such a thing in a really lightweight form (read: sub 10k lines, portable ideas), I would be very interested. Here are some pointers to other projects in the neighborhood: Thanks for CF Bolz-Tereick first for allowing me to talk their ear off about this for years and second for reviewing this post. I don’t want to implement atop Racket. C++ and C give me endless nightmares and are completely DIY. Yes, yes, I have built large VMs on C++ and C before. One time I posted so hard about the frustration that my tech lead unfollowed me on Twitter. I don’t really want to try to think about GC in Rust.  ↩ I initially thought any variable had to be monomorphic but I could not get an error from programs such as .  ↩ RPython, which has PyPy (Python) as its primary success story but also can claim Topaz (Ruby) and a couple of other smaller ones Truffle, which is the foundation of TruffleRuby, GraalPython, GraalJS, and even Sulong (LLVM) Deegen requires you to write your bytecode interpreter and type system in a C++ DSL. From this it generates an interpreter, a baseline JIT compiler, and, hopefully eventually, an optimizing JIT compiler. Truffle requires you to write an AST or (newly) bytecode interpreter in an Annotation-based Java DSL. From this it specializes guest language code before emitting Graal IR, which uses aggressive partial evaluation to generate optimized code. RPython requires you to write an interpreter in a restricted dialect of Python 2 that acts more like Java or Go than Python. The RPython compiler will then analyze your code, translate your “Python” program into C code bundled with RPython IR, and then “tier up” from the C code to JITed code at run-time. In order to go from “random RPython program” to “JIT compiler”, you need to participate in its meta-tracing , which requires annotating where your interpreter loop loops. Compile to native AOT with additional JIT. Seems like this provides good start-up performance with (optional!) tier-up as the runtime system observes the system’s behavior. Automatic memory optimization. There is no good way to syntactically express how an object should be allocated—Python is, after all, a very high-level language—so Python programs are profligate allocators of memory. RPython programs would be the same except that the AOT compiler does a whole-program analysis to try and remove these allocations. The JIT does too, but via a different mechanism. The JIT is provided to you. You don’t have to think about program analysis; the PyPy authors think about it for you. It is possible to do manual memory layout via so that you can write better data structures than Python would otherwise let you express. It provides a garbage collector for you. Furthermore, it handles all the stack scanning stuff and “oop maps” so you don’t have to build handles/ /… yourself. RPython does its partial evaluation and automatic JIT creation via meta-tracing . It is one of the last surviving tracing JIT compilers (alongside LuaJIT and, kind of, HHVM). For a lot of programs, method-based compilers seem to have produced better, or at least more predictable, results. I kind of want to see what a meta-method-JIT would look like. The user experience leaves something to be desired. I want better error messages, faster compiles, and less output. I want thorough docs. I want better performance feedback. This is in line with the rest of my ramblings about mechanical sympathy: the runtime should tell you what is wrong. I (or CF) shouldn’t have to stare at IR in traces and go “hmmmmm…” It requires writing a lot of your tooling anew. Even if I had, for example, a JavaScript parser written in Python, it likely wouldn’t be in Python 2 and it likely would not work well with RPython’s special rules. Runtimes such as JRuby get around this by compiling parsers (Prism) to WebAssembly and then bundling a WebAssembly interpreter written in Java. Along these lines, I would like more help with lexing and parsing, for which I have so little patience. I think it would be neat if it had a way to pause and save an “image” of the heap. After all, RPython is in control of all the memory and the code. It would be neat if, in addition to a JIT, it also helped you build an AOT compiler for your guest language. What if your language is statically typed? Should the toolkit provide functionality for type checking? Type inference? Some solution for C code. You can call it and stuff just fine but there’s no Sulong equivalent so it’s a totally opaque barrier to optimization. Don’t write your runtime helpers in C, sure, but at some point you have to interact with outside code. Weval, which turns an interpreter into a baseline AOT compiler. Its current implementation requires the interpreter to be compilable to Wasm and then its heap snapshottable with Wizer. One can imagine this technique being used instead to implement a JIT instead of an AOT, thereby also sidestepping the snapshot requirement. One might also imagine this applying to another IR than WebAssembly. Say, LLVM… semPy, which is an executable semantics for Python. Zig and other languages such as the more nascent k1 have the ability to run and generate code at build-time. Perhaps someone could implement a VM toolkit in one of these languages. I think a lot of the effort would still go toward something like GC handles if you want a moving GC. I don’t want to implement atop Racket. C++ and C give me endless nightmares and are completely DIY. Yes, yes, I have built large VMs on C++ and C before. One time I posted so hard about the frustration that my tech lead unfollowed me on Twitter. I don’t really want to try to think about GC in Rust.  ↩ I initially thought any variable had to be monomorphic but I could not get an error from programs such as .  ↩

0 views

2026-11-18 22:11: Last few weeks we've seen PHP2Shell, Brotli, Java4Shell, Nginx, and another PHP critical vuln imminent....

Last few weeks we've seen PHP2Shell, Brotli, Java4Shell, Nginx, and another PHP critical vuln imminent. AI is really gonna fuck things up. This shit needs regulating. Fast. Thanks for reading this post via RSS. RSS is ace, and so are you. ❤️ You can reply to this post by email , or leave a comment .

0 views
Unsung Today

“The download numbers of the mod broke all records at our site.”

Grand Theft Auto: San Andreas followed in the footsteps of 2002’s GTA: Vice City, and was released in 2004. (Subsequent versions were IV from 2008, V from 2013, and VI, launching right now .) Here’s a 2012 story at Eurogamer , written by Simon Parkin, about the infamous Hot Coffee minigame , unlocked in San Andreas by a third-party mod. It all started with a last-minute decision to remove some sex scenes that were originally meant to be published in the game: The question now was how to extract the explicit material without breaking the wider game’s functionality so close to release. An emergency meeting was called so that the senior managers could discuss a solution. During the meeting Houser explained: “You can’t always take a thing out of a game.” He had an alternative solution: rather than remove the content, the team could ‘wrap’ the sexual scenes so that while the relevant code would still be present on the game disc, it would be impossible for the player to access from within the game. As he put it in an internal email sent at a later date: “We locked it away because there was no other way to get the game done on time – safely. The code is very interwoven in [GTA] and everything reacts to everything else. The impact of yanking something late is too scary.” The decision was made. The sex would remain, but the sex would remain hidden. The idea was perhaps to unlock the scenes later via an official patch, but we all know what happens to content hidden in game’s code – inevitably, a curious nerd will find it and then talk to other nerds about it: The video showed that the content wasn’t a hidden cut-scene but a pair of playable mini-games. In one, dubbed the “spanking game” by Wildenborg, players were invited to smack CJ’s girlfriend on the backside, rhythmically tapping a button to raise an “excitement” bar. In the “shagging game”, players moved the analogue stick in time with the characters’ bodies to increase excitement. Both characters remained fully clothed and there were no genital shots. But this was still the most explicit sexual content Wildenborg had seen in a video game. “It was at this point I decided to release the patch to the public,” he says. “I tossed the name «Hot Coffee» on the file, based on the fact that the girlfriends would ask CJ in for some «coffee» as a euphemism for sex. Hot Coffee was the first modification for San Andreas.” Despite not owning a copy of the game himself, with two days still to go before the game’s European release, Wildenborg had spilled Hot Coffee. Then everything blew up. I’ll let you read the rest . It’s an interesting story that contains some good observations – “Houser understood the great contradiction at the heart of Western culture: tolerance towards violence versus intolerance towards sex” – although I am somewhat doubtful that the game creators were interested in pushing the public debate as much as they were in generating marketing-friendly controversy. If you agree with that correction, it becomes an even more interesting story in that it doesn’t portray anyone involved in a particularly positive light.

0 views
Unsung Today

“It was awful, it was too sim-y.”

The original Grand Theft Auto – known in early production as Race ’n’ Chase – had a problem: it just wasn’t too fun to play. The driving was there, the buildings were there, the missions were there, but the joy wasn’t. What injected the right amount of joy was… an unexpected bug. When the player earned a “wanted” status, the game dispatched some cop cars to chase them. As they do, the cop cars had a particular pathfinding algorithm where they meant to converge on a player. But within that algorithm, there was a mistake, as described by one of the game’s creators : […] the other thing that was a problem was the handling – the car handling was appalling. There was a point in it where you used to have a button for opening the doors and it was just rubbish. I can’t remember if this is true because we used to joke about it that you even had to start the engine. It was awful, it was too sim-y. And there was a whole living city thing that crept into it. That kind of inspires people to be more realistic and simulate more often. That steers you in a certain direction. But there were people on the team constantly trying to get that fixed. So the core of playing was fundamentally broke. There were steps being taken to fix that, but it wasn’t really gelling together. The police behaved really badly, the way they originally worked was just rubbish. Then one day, I think it was a bug, the police suddenly became mental and aggressive. It was because they were trying to drive through you. Their route finding was screwed I think and that was an awesome moment because suddenly the real drama where, “Oh my God, the police are psycho – they’re trying to ram me off the road.” That was awesome, so that stayed in. It was tweaked a little bit, but that stayed in because that was great fun. Suddenly the game got more dramatic and it’s no longer boring – the police trying to pull you over. They’re after you, they’re trying to ram you off the fucking road. Everybody suddenly went, “Hey, this is actually pretty cool. There’s something in this, this is working.” It was less about the mission stuff, which we always thought was another mess, and more about just general play – just being able to piss around. I don’t think we’ve ever seen the code or the bug in question. I found the story interesting, not only because it teaches us that you can’t really work your way around bad mechanics (this can be as true for serious apps as it is for videogames), but also because it highlights the interesting push and pull between realism and fun. The game was eventually released in 1997 and spawned a best-selling series.

0 views
Unsung Today

Le Monde’s interesting cookie pop-up

Cookie banners and pop-ups are bad not just because they are a nuisance , but also because so many try to trick you into choosing the setting that benefits the advertisers and reduces your privacy: the default option is the one bad for you, and the non-default one makes you jump through the hoops, mainfested as confusing dialogs with subpar, multi-clicks interfaces, with plausible deniability of “well, we’re giving the user control.” But I just went to the website of the French newspaper Le Monde , and saw something really interesting: = 2x) and (width >= 700px)" srcset="https://unsung.aresluna.org/_media/le-mondes-interesting-cookie-pop-up/1.2096w.avif" type="image/avif"> = 3x) or (width >= 700px)" srcset="https://unsung.aresluna.org/_media/le-mondes-interesting-cookie-pop-up/1.1600w.avif" type="image/avif"> The “Reject all cookies” was there where you usually expect a close box to be, which felt… strangely thoughtful? I wanted to click that anyway, and that ended up benefitting me. I’m expected to be proven wrong here – but this felt like an unexpected positive UI decision, given all this context, and an unexpected understanding of motor memory.

0 views

Data Contracts

Data contracts are a way to describe the contents and guarantees of datasets. Simon Harrer and Arif Wider describe in detail what they are and how to use them. They apply practices from API design to data by treating them as data-providing services - such as data products - whose interfaces we want to define as clearly as possible. This approach significantly increases the robustness of large-scale data landscapes, and gives both people and AI agents the explicit, trustworthy metadata they need to work with data autonomously, which is why more and more enterprises are adopting them.

0 views

workplace equality

At my workplace, the typical office worker secretary stuff - the kind of position meant to free the backs of the knowledge workers - is 99% done by women. Meanwhile, the knowledge workers are 50/50 men and women. That’s already considered progress and deserves some acknowledgement. They also try to hire more women into leadership positions, which has been going well. The difficulty is more about getting women to apply to these positions rather than unwillingness to hire them for it, and they’ve made an effort to offer dual leadership positions in which two people in part time positions fill one leadership role. Still, the fact that anything considered “lower” than a knowledge worker, specifically the job where you take care of the minutiae of others’ jobs so they can focus on their creative process or problem solving, is still female-dominated bothers me and negatively affects my view on career success as my gender. Of course, there are reasons beyond the influence of an organization: Office work like that needs less qualifications and can be done part time. They’re a great opportunity for mothers, who are unfortunately still expected to cut their career and have a more flexible job with less hours in the week for their child than the other parent (usually father), who is expected to stay at work full time, be dependable and never take time off for the child (that’s what the mother is for…). It’s good for chronically ill people (who often happen to be women), and it’s great for women who need to get a job after being a SAHM for years before the divorce happened and now they’re 45+ with no work experience. Realistically, this is bound to drown out male applicants, if they exist. Still, a part of it also feels like men are often considered ‘too good’ for these kinds of jobs and as if their potential would be squandered if they worked in these roles. I see it in traineeships and new hires, how women are expected to stay in these lower roles because it’s “safe and non-demanding” (“what if you want children?”) and men are expected to immediately surpass that for something bigger almost right out the gate, regardless of a potential wish to have children or not. Bias about women being less smart or capable but more nurturing also plays into this. Taking care of someone else’s calendar at work, pre-sorting their mailbox and filtering what gets their attention, taking their calls for them, writing emails on their behalf, preparing PowerPoint presentations for them and similar work feels like household work, but at the office instead. It’s like cleaning house, doing laundry, ironing shirts, and cooking so everything’s ready for when the man of the house gets home or has to leave for work and he doesn’t have to lift a finger so he can focus on work only. Making sure documents for their work are ready and reports are done in time for the official deadline feels like making sure the kids did their homework or the newspaper is next to his breakfast plate. It’s not just the work itself though, it’s also everything around the office that revolves around office culture and relationships. When I look around in my workplace, this is run by women. Who plans office events? Women. Who bakes the cakes? Women. Who gathers money and prepares a card and gift for people’s birthdays, retirements and weddings at the office? Women. Who do people turn to when they wanna vent about work or their private life? Women. Many women have care work at home and the office, both as core aspect of their work and just by existing in the office. When you tell men this, they’ll usually say that no one asked women to do this, because who needs someone checking in with others, who needs that decoration for Halloween, who asked for that annoying work event, who needs cake in the kitchen or a useless card, or a stocked fridge? I think this take is stupid, because I too don’t care for cards, can’t even eat most cakes here and stay away from most work events, yet I recognize that it adds something to the workplace atmosphere and relationships that I still profit from even as a work hermit. Many men at work will scoff at these things, do nothing to get people together and roll their eyes when the first 5 minutes of a work meeting are spent discussing non-work things, yet still show up to it all to get drunk, feast on cake and laugh loudly with the boys, taking advantage of it while pretending they don’t care and it would be equally as good if this simply did not happen. Many don’t even have a reference for how cold and sterile the climate would otherwise be because almost all workplaces have women (or a woman) who is inofficially or officially responsible for these things. And even if she herself does not want to do these things (as everyone seems to think women naturally just crave managing office relationships), the people around her will expect her to or directly ask her to take over these matters. It’s like when people point out or call for a “woman’s touch” in a house or apartment due to a good eye for decoration or a lack thereof, but for the office culture instead. During my earlier times at my workplace while I was at different departments, I experienced firsthand how they tried to force me into the office-woman-box. For men, it was okay to arrive, silently walk past the open office doors to their own office, close the door, and focus on their own thing, and only emerge during lunch, if at all. It was accepted not only because these men held knowledge worker positions where the need to lock yourself away to focus was understandable to most, but also because of the expectation that men aren’t social. Meanwhile, women were expected to stop at every door to say good morning, and after arrival, should chitchat a bit about last weekend or the planned vacation. And they better leave their office door open, otherwise it comes off as rude and closed off. While the higher positions awarded almost all men a single office, the women were sitting in offices with 2-4 other women in the same position. So when I behaved like it was normal for men to behave, it was seen as arrogant and antisocial, when the same behavior was accepted for men. As a woman, you are supposed to be accessible to everyone at all times. You’re the office mommy after all, so if someone needs help finding a document or something else they should be able to find themselves, it’s faster to go to your office or call you and make it your problem, like children who spilled juice on themselves. I have dealt with this by helping the first time while explaining how to do it themselves, and when they ask a second time, refer to the first explanation. I will help, but I am not your maid. It has led to a lot less “I just couldn’t care to first try and solve this myself” type of mails and calls to me, but an increase for others who do take it upon themselves to be the maid for everything. I cannot even fully explain how all-encompassing it all is, in how many situations in and outside of work, people of all ages and genders have the automatic response to search for the nearest woman regardless of responsibility, availability or skill. You could be deep in your work in another subteam as a woman and people will rather bother you about the broken coffee machine than the nearest available man. I recognize that women at work never asked to be a role model for anyone; they’re here to work, so of course they are not responsible for the impression it gives me to see work still split up so conservatively between genders, especially the older generation of women 55+. Change takes time, and many of them started working under different conditions, so all that I have mentioned are effects from different attitudes. Yes, some may just not wanted to dream bigger and that’s their ideal job. But many were also put on this path because of expectations around childcare or because while they still could, they could not get promoted over a similarly qualified man, or could not get any support from their partners to gain other qualifications on the side to help advance a career. It’s hard to tell who chose this versus who settled for it and now makes the best of it, or who might even be secretly unhappy. I’m glad that nowadays, I work in a department that doesn’t treat people in a strongly gendered way, accepts the way I prefer to behave at work, and where my boss is a woman I can look up to that is ambitious and career-driven and who supports me in my endeavors to break out of the women job box. It’s something I need to see inbetween all the normalization of part time work and financial reliance on a husband for women who work here, or who have never recovered their interests and drive back after just being mother for 18 years. Published 18 Nov, 2026

0 views

Nvidia Earnings; Office Convergence; OS Wars, AI Edition

Nvidia's earnings were boring, and also a statement as to why Jensen Huang probably isn't coming back; then, Microsoft and Anthropic ship dueling operating system updates.

0 views

curl on OSS-Scanner

OSS Scanner is a service by Anthropic to scan critical open-source repositories for security vulnerabilities curl maintainer Max Dymond submitted pull-request 1191 to OSS-Scanner in the end of October and we were swiftly enrolled into the program. The idea for this service is inspired by OSS-Fuzz : Anthropic scans the participating open source projects for security problems on their machines at some interval with their magic applied and they let us know if they find anything. I don’t think they officially say exactly which model they use for this nor how often they rescan. Early in the morning of November 5 we received our first sign of life from them since they merged the PR. An automated mail: Forty-five security vulnerabilities in a single shot is a lot . But sure, we did ask them to do this. Of course, had we not asked them, chances are someone else would instead have figured these ones out and reported to us separately. There are many people with capable harnesses and AI models out there. The Anthropic email with all the findings described that the analysis considers one of the flaws to be severity MEDIUM and the remaining 44 at severity LOW. In addition, they also found 23 ordinary bugs that are also included in the report. The ordinary bugs they reported have not yet been analyzed. This blog post focuses on the 45 reported claimed vulnerabilities. In this large tarball we got individual markdown reports for each finding, together with their associated reproducers and in many cases also their suggested patches for mitigation. With a little scripting and lots of manual fiddling, I submitted all these reports as individual issues on GitHub following our new policy . I paced myself and did this over a period of several days to soften the impact this had on the team. Each report starts in ASSESS mode and once it has been given proper attention we move it to a suitable severity level or we set it to NONE if there is no vulnerability at all there. You can view all the issues yourself . In the curl project we have decided to gradually raise the requirements for severity LOW vulnerabilities. Issues that seem too ridiculous or unlikely we now set to NONE to a larger extent than we have in the past. As just a bug as we like to call them. With this in mind, curl maintainers worked fiercely on the reports of the coming days until we had reached an initial verdict for all the 45 reports – and in the mean time we also received a few additional reports submitted by other reporters. The severity MEDIUM finding we consider to be a LOW and we also agreed with an additional four findings, thus landing on five (11.1%) confirmed. 36 of the 45 findings we consider just bug s, three of them were not even bugs while one of the findings was completely wrong . The wrong one insisted the issue in the complete opposite way and claimed we should patch away our proper way to instead do it the AI’s suggested inferior way – which would introduce the vulnerability it warned for. Vulnerability rate The 11% vulnerability confirm rate is lower than the average in vulnerability reports we have seen in 2026 but the 80% just a bug share is a much higher rate than ordinary reports. The average share of vulnerability reports that report “just a bug” has been at about 43% earlier during this year. Combined, a conclusion must land on that these reports have high quality, but are way too eager to call them vulnerabilities. This should also be seen with the understanding that we as a project have shifted slightly and have higher requirements now. One of the most annoying things with AI generated reports in general is the length of the reports and these ones are no exceptions. It feels like an unwritten law that they must produce very long texts and it feels like the reports are always excessively long no matter the complexity of the issue it reports. In that regard, human reports still easily outperform the AIs’. Several of these findings contain proposed patches for the identified issues. In some instances they have been almost exactly what were necessary, but more commonly the fixing took human effort to analyze the (too) long report and write up the fix for it. Since 41 out of the 45 findings identified problems, we got our hands full. At the time of this writing, eleven of the reported bugs are still not addressed. When an AI finds a bug, they tend to identify problems that no user ever ran into. Users typically report problems when they do something and curl then does something unexpected or it somehow doesn’t satisfy the user’s wishes. In these findings, the reported problems are more theoretical . In many cases this makes the reports less important, and sometimes unlikely to cause problems in real world use cases. We willingly joined this effort as getting flaws and bugs reported helps us improve curl. However, since the severity levels of the findings are of this, shall we say trivial , kind, it feels reasonable to reconsider our participation if this keeps up. Part of the idea of making more vulnerability reports public early is to make it possible for everyone to join in and help. Provide your comments and views on reports still in ASSESS. Submit your proposed changes as pull-requests, or help review changes proposed by others. Help review the advisories for confirmed vulnerabilities to make sure the descriptions make sense and are accurate and that we figure out exactly when they were introduced etc.

0 views

Re: Dying Indies

Cassidy wrote a post titled “Why are all the indie-friendly products dying at the same time?” that it’s worth reading if you’re interested in this kind of topic. I’m not gonna TLDR her post, but I wanna add one extra consideration: a lot of startups are good products, but terrible businesses. And the problem with VC-powered projects is that you can trick yourself into thinking you have a good business when in reality you have a good product, with no real business attached to it. And what end up surviving are good businesses with solid products. Services that started charging a fair and reasonable amount of money from the get-go, delivering a quality service in return. Services that are more like traditional businesses, in a way. And that’s honestly good in my view. Thank you for using and believing in RSS. You're awesome. Send me an email :: Sign my guestbook :: Become a supporter

0 views

Attackers Used Optimizely to A/B Test Malware on Top Websites

At least 178 top web destinations unwittingly served a variety of malware exploits against visitors over the past 24 hours thanks to a security vulnerability involving Optimizely , a company that helps websites customize user experiences and test out new features. Experts say the incident, which saw data-stealing malicious software silently injected into sites like the BBC , CNN ,  Equifax , Ledger and Zoom , was exacerbated by the reality that few popular websites enforce strict rules on the sources of third-party content. The Zoom.com homepage loading the malicious JavaScript file from Optimizely. Image: blog.report-uri.com. Click to enlarge. According to a blog post from the security firm Report URI , on November 16 malicious JavaScript code was served to visitors of 178 organizations through Optimizely’s platform. Report URI researcher Scott Helme wrote that the payload delivered by the malicious Javascript was rebuilt 26 times during the day, dropping a multi-purpose malware kit that could steal payment card data, cookies and screenshots, and swap any cryptocurrency payment addresses for the attacker’s. Helme noted the affected websites also served exploit code custom made to attack known vulnerabilities in older Apple iPhone and iPad devices. Known by such names as “ DarkSword ” and “ Coruna ,” these are zero-click exploit kits that chain together a half-dozen security holes to seize complete control over outdated devices and extract data. “The important lesson here is that trusted JavaScript doesn’t always remain trustworthy,” Helme wrote . “A website can be compromised through a third-party dependency without its own code or infrastructure ever being breached.” Contacted for comment, Optimizely said that on November 16, 2026 it “identified a security incident in which an unauthorized party exploited a vulnerability in the Optimizely Experimentation to add malicious JavaScript to some customer projects.” “We acted swiftly to contain the incident and have fully remediated the identified vulnerability,” reads a written statement shared by Optimizely. “These measures included blocking access to the vulnerable path, deploying a fix, removing the injected code from affected projects, ending active sessions, revoking tokens, and resetting access for affected user accounts. We have also implemented additional protections to prevent malicious code from being delivered in Cloudflare. While the incident has been fully remediated, we are working with third-party experts on a comprehensive investigation.” Many top web properties no longer fully display content unless visitors agree to let often dozens of third parties serve JavaScript, a powerful web scripting language that enables interactive content. JavaScript code is run on the user’s device, and it can read information displayed in the user’s browser and even modify a website’s appearance or content. One reason JavaScript is so heavily used is that it enables fairly precise browser fingerprinting and other ways of tracking visitors and clicks. According to the 2025 Web Almanac by HTTP Archive, the median homepage loads at least 22 JavaScript files. But as the incident with Optimizely shows, a compromise at a third-party vendor’s website can quickly snowball into a supply chain attack against downstream websites that end up serving visitors tampered and malicious JavaScript files. Zach Edwards is a researcher at Infoblox and the co-founder of the ad-tracking service DecryptAds . Edwards said Optimizely is a vendor which often collects data outside of consent flows, with their JavaScript snippets being embedded as close to the top of the page as possible to ensure that it’s one of the first things to render, which is important since the product is primarily built for A/B testing. “So to make the product work as expected, this code is setup to fire immediately on-page load, and not restrict rendering behind a consent dialog box,” he said. “This means that this supply chain attack didn’t require any clicking or consent to trigger — most of the impacted clients would immediately serve up the payload as soon as someone loaded the page, further increasing risks from this type of JavaScript snippet being compromised.” Websites can minimize the chances that a breach at a third-party content provider spirals into a supply chain attack by taking full advantage of “ Content Security Policies ” or CSPs, which specify the domain names that are allowed to serve third-party content. But Edwards said most websites — apart from perhaps the largest e-commerce, social media and financial platforms — don’t even bother with CSPs, or else tend to leave them overly permissive for marketing reasons. “With literally all websites which embed 3rd party JavaScript resources, if you don’t have a content security policy then if any of those partners get compromised, new domains can be injected into your website via JavaScript which won’t be stopped,” he said. “We’re in the age of JavaScript supply chain attacks and yet almost no one is talking about why content security policies were invented and how this is largely the solution for operators, even though it’s not always simple to get it initially deployed.” How broadly deployed were CSPs at the websites impacted by the Optimizely attack? According to Report URI, 68 of the sites had no CSP at all, while 50 of them had a CSP that still allowed the malware payload and the data theft. The company found only 24 of the affected sites (15 percent) had CSPs that fully blocked the malicious payload. Image: blog.report-uri.com. The overall deployment of CSPs across the Web’s busiest sites is somewhat lower — about 10 percent — according to Helme’s site crawler.ninja , which scans the top million websites daily for security issues. Helme said he hopes this incident will encourage more sites to adopt effective CSPs, noting that it could have been far worse: By Report URI’s estimates, the purveyors of this malware attack managed to steal only around $7,500 worth of virtual currency from affected users, as well as an unknown number of payment card records. Helme said he often compares the current widespread lack of CSPs to the Wild West. “Organizations are running all this code, but they don’t know what it’s doing,” Helme said in an interview with KrebsOnSecurity. “This is why we keep seeing such large scale breaches in places [where] there are no checks and rules in place on the code we’re running, so this was kind of inevitable. Once an attacker gets to the point of running code on your site, the question is what do they want to do with that and can they write the script to do it. Now with AI that’s not a problem anymore.” Internet users can control the JavaScript elements allowed to run on webpages by using simple script-blocking plugins like NoScript. But these tools have always only been effective for diehard security and privacy nerds who are willing to put up with sifting through dozens of JavaScript requests on each new website. Happily, modern ad blocking software can handily block most third-party JavaScript requests. Ten years ago, the standard security advice for end users was to install antivirus and enable a firewall. These days, your ad/script blocker is your firewall. We explored several options and approaches to blocking ads in our August 2026 story, Who’s Tracking You?

0 views
Unsung Yesterday

“I’ve spent years on it. Years. On a box.”

Designer Pablo Stanley created a really fun interactive exploration of what it takes to create a seemingly simple “composer” (industry’s jargon for a more sophisticated input field or things like it): = 2x) and (width >= 700px)" srcset="https://unsung.aresluna.org/_media/ive-spent-years-on-it-years-on-a-box/1.2096w.avif" type="image/avif"> = 3x) or (width >= 700px)" srcset="https://unsung.aresluna.org/_media/ive-spent-years-on-it-years-on-a-box/1.1600w.avif" type="image/avif"> It’s a bit outside of Unsung’s purview since a lot of it is very “sung.” The case study focuses on visual presentation, and doesn’t cover systems design or consistency with other things; I even worried at times it could perpetuate an image of a UX designer being a “lone genius,” overindexing on visuals and tactile experiences over more important things, of which there is a ton in the AI neck of the industry woods. At the same time, there are also mentions of flow, and a general drive toward reducing complexity that feel worthwhile. Plus, the theme of details that seem minuscule on the surface, but will all ladder up to a lot of friction in repeated use, is something we cover a lot . Also, I am burying the lede: it’s a really enjoyable and well-crafted experience – don’t miss the sound and music! – and this unique way of talking about interface details could be inspiring in and of itself. You can also watch the entire thing as a video with Stanley narrating, but I personally liked the interactive version more:

0 views
Lea Verou Yesterday

Nudeps: bundler-like imports, none of the baggage

You a package (e.g. ), you write , and it works — as long as there is a bundler in between. Without one, the browser has no idea what is: it only understands URLs, and was never meant to be deployed. So even the simplest project ends up needing a bundler, only so it can use dependencies instead of reinventing the wheel. But bundlers add a significant tax. They process every single file, introduce several layers of abstraction between source and deployment, and these abstractions often leak : things that work fine in the browser can break in the build. Earlier this year, I published Web dependencies are broken: Can we fix them? that discusses this from a platform architecture perspective. Besides the architectural concerns, the complexity is an active developer pain point: in State of JS 2025 , “Managing Dependencies” was the 3rd biggest pain point , and “Build tools” were 6th. However, getting rid of build tools is not the goal. Some use cases should not be handled by the browser, so bundlers and build tools will always have a role to play. The goal is making them lighter, composable, and less essential . In that vein… Nudeps 1 is a new kind of lightweight build tool that lets you continue using to manage dependencies, vendor them locally, and import them via bare specifiers (package names like or instead of URLs), without the bundler. You set it up once, and then you can forget about it: you keep ing packages and importing them by name, and they work in the browser. And it only ever touches your dependencies, never your own code . Since my apprentice Dmitry and I prototyped the initial MVP in February, we and others have tested it on a variety of projects, and at this point I’m confident that — while not perfect — it’s ready for prime time. A core architectural difference between Nudeps and bundlers is that your own code remains untouched . In fact, it doesn’t even need a watcher that runs whenever you make edits! It only touches dependency files, and doesn’t rewrite anything, making it extremely lightweight in terms of complexity it adds. This means it can complement any other tooling — or none. You write raw HTML, CSS, JS? This is for you. You use a templating engine, a CSS preprocessor, and TypeScript? This is also for you (though understandably you may have less use for it). This also makes it complement static site generators and island architectures particularly well. Does it replace your build process? If all you needed it for was getting imports to work, it could. If you also compile your code (JSX, TypeScript, single-file components), you still need a tool for that, but it can be a much smaller one. Bundlers make complex things possible. Nudeps is hoping to occupy the space on the left of the curve and make simple things easy . Assuming you don’t need to customize anything (e.g. using for the map, for the dependencies, all default settings) it goes like this: That’s it. You’re done. You can now and to your heart’s content, and start using packages right away in your code. Things Just Work™. We have been so trained to expect friction and complexity, that some testers thought they were doing it wrong: I ran the npx command and added the import map to my app, but I assumed that there was still a lot more work to do. I was shocked to realize I was done. — Sam Littlefair Most of the pieces were already there, and were just waiting for someone to put the puzzle together. Import maps allow us to import bare specifiers (package names like ) instead of URLs in the browser and are Baseline Widely Available. JSPM is a library that traces a dependency graph and generates an import map. It focuses on CDN use cases, but its engine is exposed as a separate library that can be repurposed, which is what Nudeps uses under the hood (with a lot of tweaks). Import maps currently have to be inline in the HTML of every page, which would require templating, but external import maps can be easily emulated via a small script that injects the map. Package managers like npm already give you the file structure and let you manage versioning, that structure just can’t be deployed as-is to the web . When you install Nudeps via , it does two things: Using as a hook means there is no Nudeps watcher or command to run when you start working on a project! In that sense, Nudeps actually gets you better DX than a bundler 2 . Then, whenever runs, it… Here’s an example of what that script may look like. In production, you can prune to only the specifiers actually used (via the option), and including them all in development means the import map only needs to change when your dependencies do, not whenever you write an import. Yes! Obviously some frameworks are compile-only (e.g. Svelte), but many have runtime-only imports. Even React can be used, though without JSX the ergonomics are poor. My personal go-to is Vue . Most libraries also work fine, including D3 , gsap , Lit , Three.js , Floating UI , interact.js , and Underscore . Beyond common cases, Nudeps supports quite a few edge cases too: Many CJS-only packages like lodash work too, via a tiny shim (that Nudeps handles), and the jQuery demo even loads two different jQuery versions side by side through npm aliases. Yes! In fact the demos include two such dependencies: Open Props and Bootstrap Icons . The catch is that since browsers currently have no way to include CSS stylesheets via specifiers , you need to use actual URLs ( this is changing ). This also means these packages cannot use other dependencies (unless they bundle them). Thankfully, that’s the case for most. To make this easier, Nudeps creates symlinks (or redirects, where symlinks are not supported) so you can import versionless URLs like . From the very beginning of our testing (back in February), Claude understood it just fine, making only minor mistakes that were unnecessary, but ultimately harmless (Nudeps still worked fine), such as: And the package now includes a file, which makes them go away entirely once the agent is instructed to actually use it. Most packages work. Also, since Nudeps doesn’t bundle, packages with a lot of tiny modules pulled together by ESM imports may be slower to load initially. If you’re a package author that wants to provide a Nudeps-friendly bundle, generating a bundle that consolidates them somewhat can improve performance. But there is a tradeoff to all bundling: the more files are bundled, the less granularly they can be loaded. There is typically a sweet spot, and that varies depending on the structure and usage patterns of your package. But please do not bundle your package’s dependencies in there as well — these need to remain separate, so they can be shared with other packages that use the same version of the same dependency. Nudeps does one job, so there are things it doesn’t do, and things it doesn’t do yet : Nudeps is just the beginning, and is far from perfect. There are certainly plenty of unknown unknowns, and many things we simply haven’t gotten around to. Besides bugfixes and closing the gaps above, at the top of the roadmap is testing more packages to ensure compatibility and uncover edge cases. If you want to give Nudeps a try, the easiest way is to head to your terminal and run in your project directory — or just let your agent do it. Get Nudeps Demos Nudeps on npm I’m hoping that Nudeps is the first step towards a future of lighter, composable build tools . Try it and let us know how it went! Thanks to the beta testers: @g12n , @jak2k , @lgarron , @beejunk . Thanks to Jordan Harband for his early feedback around package subsetting. And as always to my apprentice Dmitry for his help working out the kinks and making this a reality. Which you can choose to read as either nude deps or nu (new) deps ↩︎ Of course if you need to start a server for development, that doesn’t make a ton of difference. But localhost is cheap. Your editor can start one. Your agent can start one. Heck, I even have one running at the root of all my cloned repos. ↩︎ You run and it will set everything up for you. You add to your HTML through whatever mechanism you want, before any other scripts that import dependencies: Adds Nudeps to your Adds two scripts that run : , so Nudeps re-runs itself every time you or , and , so a fresh clone is ready too. copies the necessary files from into a directory, which is meant to be deployed, but not committed: it is regenerated on every , and comes with its own flattens the directory structure by including the version number in the directory name (e.g. becomes ) which gives you better deduplication and granular cache busting, generates an import map injection script with all specifiers in your direct dependencies and the specifiers they actually use, using JSPM under the hood. Local packages ( ) npm aliases ( ) git dependencies ( ) npm workspaces (experimental) Adding entries to (the generated files already ignore themselves) Running manually, adding it as an script, or even running manually because it thought it was a custom script. It wasn’t aware of the hook (and would in fact insist it doesn’t exist 😅) Adding config file overrides that weren’t necessary Nudeps works much better with ESM packages. CJS support is very experimental. Some packages unfortunately assume that they are running in a Node.js environment and rely on Node.js-specific APIs like . For the most common ones, you can just stub them, but if it starts getting out of hand, you’re better off using a bundle for that particular package (you can add overrides via Nudeps’ config). It doesn’t transform your code. Anything that needs compiling (JSX, TypeScript, Svelte) still needs its own tool, which Nudeps happily works alongside. npm only, for now. Supporting other package managers (pnpm, yarn, etc) is at the top of the roadmap, since many people today have moved away from npm. Non-JS dependencies need actual URLs, not specifiers. Workers also don’t do specifiers, see No benchmarks yet. Depending on the package structure and type of usage, bundlers may be significantly faster or even slightly slower. It would be nice to get some data on this. Which you can choose to read as either nude deps or nu (new) deps ↩︎ Of course if you need to start a server for development, that doesn’t make a ton of difference. But localhost is cheap. Your editor can start one. Your agent can start one. Heck, I even have one running at the root of all my cloned repos. ↩︎

0 views
Xe Iaso Yesterday

"No way to prevent this" say users of only language where this regularly happens

In the hours following the release of CVE-2026-123633 and CVE-2026-123007 for the project NGINX , site reliability workers and systems administrators scrambled to desperately rebuild and patch all their systems to fix an HTTP/2 connection use-after-free during reverse-proxy processing when connection slots run low, alongside an HTTP/2 flow-control integer underflow that leads to an out-of-bounds memory copy over TLS, both of which can allow unauthenticated remote code execution on affected servers with HTTP/2 enabled. This is due to the affected components being written in C, the only programming language where these vulnerabilities regularly happen. "This was a terrible tragedy, but sometimes these things just happen and there's nothing anyone can do to stop them," said programmer Dr. Deontae Rempel, echoing statements expressed by hundreds of thousands of programmers who use the only language where 90% of the world's memory safety vulnerabilities have occurred in the last 50 years, and whose projects are 20 times more likely to have security vulnerabilities. "It's a shame, but what can we do? There really isn't anything we can do to prevent memory safety vulnerabilities from happening if the programmer doesn't want to write their code in a robust manner." At press time, users of the only programming language in the world where these vulnerabilities happen continuously were referring to themselves and their situation as "helpless."

0 views

The curl 30 years gource

In association with curl’s 30 year anniversary, I made another gource video visualizing its development. Unfortunately it doesn’t cover the full 30 years since we only have records from late 1999 until today; but it is still decent. Instead I added a little bonus: I’m doing a voice over comment track, explaining and highlighting some facts and details.

0 views
Unsung Yesterday

“No one knows what ⍼ is meant to represent or where it originated from.”

A fun Masto post from abadidea, written some time in between the Microsoft outage, the grounding of all the flights, and the banking problems: My discord has an emoji named “tech debt” - which is just the angzarr, ⍼, the symbol famous for having no known use or agreed-upon meaning but somehow appearing in unicode and now it’s just a part of unicode forever. With so many enormous tech debt bills coming due recently, perhaps you, too, would like to take a moment to appreciate the tasteful angles of the angzarr. This is angzarr as rendered by your computer – ⍼ – and this is it blown up… = 2x) and (width >= 700px)" srcset="https://unsung.aresluna.org/_media/no-one-knows-what-angzarr-is-meant-to-represent-or-where-it-originated-from/1.2096w.avif" type="image/avif"> = 3x) or (width >= 700px)" srcset="https://unsung.aresluna.org/_media/no-one-knows-what-angzarr-is-meant-to-represent-or-where-it-originated-from/1.1600w.avif" type="image/avif"> …and it is true we actually do not know what it is all about. In between 2022 and 2024, computer science student Jonathan Chan ventured out to figure out the purpose of the mysterious character. In a so-far-four-part piece – part 1 , part 2 , part 3 , and part 4 – he compiled the timelines, found old docs and even one physical font block, and talked the a few people. Spoiler alert: The journey must be the reward because the story remains unresolved, and might forever be. There is a lesson I learned when researching keyboards. The answer to the question of “why is a certain key in this place?” most often ends up being “because it was there on the keyboard before this one.” There is natural inertia in not touching something that is already out there, and real cost associated both with understanding something old, and with change management necessary to change or get rid of it. You might assume there is not much damage of angzarr still existing in Unicode – out of sight, out of mind! – but it’s not as simple as that. Complexity will find its way to get to you. Here’s me searching for “right arrow” in macOS’s default character picker, and you can see what should be an easy process is muddled by having to deal with all of Unicode’s character space: = 2x) and (width >= 700px)" srcset="https://unsung.aresluna.org/_media/no-one-knows-what-angzarr-is-meant-to-represent-or-where-it-originated-from/2.2096w.avif" type="image/avif"> = 3x) or (width >= 700px)" srcset="https://unsung.aresluna.org/_media/no-one-knows-what-angzarr-is-meant-to-represent-or-where-it-originated-from/2.1600w.avif" type="image/avif"> A lot of these things might be angzarr-adjacent, used by pretty much no one, yet clouding the results. The thing I want is… well, actually it doesn’t even exist here! I need to search for “rightwards arrow”: = 2x) and (width >= 700px)" srcset="https://unsung.aresluna.org/_media/no-one-knows-what-angzarr-is-meant-to-represent-or-where-it-originated-from/3.2096w.avif" type="image/avif"> = 3x) or (width >= 700px)" srcset="https://unsung.aresluna.org/_media/no-one-knows-what-angzarr-is-meant-to-represent-or-where-it-originated-from/3.1600w.avif" type="image/avif"> Here’s another classic example. Check out the Edit menu in Photoshop – what is one menu item here that feels very much out of place? = 3x)" srcset="https://unsung.aresluna.org/_media/no-one-knows-what-angzarr-is-meant-to-represent-or-where-it-originated-from/4.1600w.avif" type="image/avif"> In between stalwarts like Cut/​Copy/Paste, and so many other universal and technical menu items, there’s one extremely specific and strange entry: Sky Replacement. I’m sure, just like with angzarr, there was once a reason. I’d even say in contrast with the mysterious character, Sky Replacement probably sees use today – perhaps even significant use. But it is such an oddball that its very presence here tells me something went awry in the design process, and no system was in place to correctly understand its added, treacherous weight , and adjust the whole information architecture to accommodate it. But also, it’s easy to point fingers at bloat elsewhere. I think a more fruitful question for anyone reading it would be: what is an angzarr in your app, and what are the hidden costs associated with it being there? I also think the original post also points to a pretty delicious irony. Usually, removing even an extremely obsolete and niche thing is hard because every feature finds its power user, who will shout at you the moment you even approach it. But for angzarr, there was a moment in time – perhaps even many years – where deleting (or demoting) it was perfectly safe. But now, the original poster’s team is using it just because it was there , and now any removal is once again a more complicated proposition.

0 views

Running the full server-side Datasette Python app in the browser with service workers and Pyodide

Datasette Lite is my port of the Datasette Python application to run directly in the browser using WebAssembly and Pyodide . I've released a complete rewrite of Datasette Lite using service workers, and it's now almost indistinguishable from the real server-side application. You can now do all of the following, using a carefully crafted URL to lite.datasette.io : The ability to load specific Datasette references, plugins, and SQLite versions makes this a fantastic tool for linking to demos of work-in-progress features or bug reproductions, without needing to spin up a full web server to serve that demo. As an example, consider the following URL: https://lite.datasette.io/?install=datasette-maplibre&url=https://gist.githubusercontent.com/simonw/39fa5d399465766039549912e2b3d291/raw/f6dfba99a75cbb8b5d9386223220eb52272767ee/demo.db&metadata=https://gist.githubusercontent.com/simonw/39fa5d399465766039549912e2b3d291/raw/f6dfba99a75cbb8b5d9386223220eb52272767ee/metadata.yml#/demo/capitals_and_countries%23map=0/4.2/180&color=continent Follow that link and, after a short loading screen, you'll find yourself on a page that looks like this: That's Datasette running the new datasette-maplibre plugin, loading up a database of GeoJSON shapes of countries and displaying both a combined map and individual boundary maps in a table. Let's break down that URL to see what it's doing: The installs that additional plugin from PyPI. You can pass as many times as you like to load more plugins. loads that SQLite database from the provided URL. These URLs need to have open CORS headers - I host files like this in Gists , because they provide an easy way to get open CORS headers on a web-hosted file. loads this metadata.yml file . The metadata file adds HTML descriptions to various tables, and to the Datasette homepage. Visit that homepage here for a guided tour of the other features of that plugin, all defined in the metadata file. is a fragment hash that turns into a location within Datasette - here it's loading the SQL view, then appending another fragment hash to it ( is a URL-encoded ) which tells the map plugin to zoom to a certain location and to set the color of the shapes on the map based on the column in the data. That URL is doing a lot of work! I wrote more about this trick for building URL-addressable software in URL-addressable Pyodide Python environments last year. The full set of supported URL arguments is described in the Datasette Lite README . I've already started using Datasette Lite as part of the Datasette development process. Here's a recent issue describing a pagination bug - I posted a comment there demonstrating the old, broken behavior and the new fix using links to Datasette Lite: Demo of the bug: https://lite.datasette.io/?ref=1.0a42&sql=https://gist.github.com/simonw/75ececf61d50e6e8d50f0c150150ee81#/data/scores?_size=2&_sort=score - click next and the second page is empty. Here's that same page with the bug fixed (running on 1.0a43): https://lite.datasette.io/?ref=1.0a43&sql=https://gist.github.com/simonw/75ececf61d50e6e8d50f0c150150ee81#/data/scores?_size=2&_sort=score Datasette Lite is not a new project. I launched the first version back in 2022 , originally as a bit of a joke (running server-side apps in the browser is pretty funny) but one that quickly started proving its value. The problem with that initial version is that it was a hack . It worked by running Datasette in a Pyodide web worker, simulating requests through that stack, then injecting the resulting HTML back into the top level page using . This worked for basic Datasette, but meant that any feature that used JavaScript failed to work, because script tags in don't execute, and the web worker tricks it used failed to load additional JavaScript or CSS files. The new version takes a completely different approach based on Service Workers . These allow JavaScript to intercept HTTP requests for new pages and resources and serve them from client-side code instead. Datasette Lite registers a service worker for the entire domain. The parent page then creates an iframe that sends requests for Datasette pages to URLs that look like this: Those are regular Datasette URLs, but with a prefix. What's that about? The prefix is necessary because of multiple tabs. Consider the URL above, which loads the demo instance with the plugin. That URL defines a full, custom Datasette instance. You might have that one running in a tab, then one of my other demo links running in another. The service worker for is shared between all of those tabs. If it routed to a single instance of Datasette then every tab would share that underlying instance, no matter what plugins or other settings their URL attempted to configure. Instead, the parent page generates a random session ID and uses it as a prefix for all of the subsequent hidden asset and page loads. The service worker can then use that session ID to route those requests back through the parent page to a web worker running a dedicated Datasette instance for that particular session. (We still need a web worker because Pyodide in a service worker would not be able to maintain state beyond around 30 seconds, depending on the browser. There are a lot of moving parts here!) I had Claude Fable 5.2 generate several SVG diagrams to help explain this. Here's my favorite of those, now embedded in the Datasette Lite README: This system started life back in May as an AI research spike generated using Claude Opus 4.8. It wasn't until November (and Claude Fable 5.2) that I felt familiar enough with how it all works to confidently ship it to production! I added this feature last night as an off-shoot of investigating a potential bug in SQLite . Datasette is meant to work against any released version of SQLite since 3.25 (released in September 2018). There have been 87 further releases since then. Being able to fire up Datasette against a specific version of SQLite is really useful for demonstrating new SQLite features and debugging weird issues. In the past I've used various tricks to get different SQLite versions running with Python on my Mac, but it's not a trivial process. WebAssembly is perfect for this. I can load up a custom SQLite build entirely in my browser, test it there, then discard it when I close my tab. datasette/pysqlite3-wasm-wheels is my new repository which contains WebAssembly compiled Python wheels for pysqlite3 for 163 different SQLite versions. Each version gets a file with a name like this: That's for SQLite 3.54.1, the most recent version. Datasette Lite now takes a special URL parameter, which will accept a version number like , resolve the path to the corresponding wheel file, then fetch that wheel and install it into the Pyodide environment and configure Datasette to use it. Once I'd built the wheels, I decided to have Claude Fable 5.2 build me [this bonus tool]( https://datasette.github.io/pysqlite3-wasm-wheels/?versions=3.54.1,3.54.0&sql=select+json_object(%27a%27%2C+(select+json_array(1%29%29%29) for comparing a SQL query across any selected versions of SQLite. Here's an example showing how differs between SQLite 3.54.0 and 3.54.1: Nothing about how Datasette Lite works is unique to Datasette. Almost any Python application should be able to pull the same trick - running entirely in the browser using WebAssembly and Pyodide, as a cheap way to provide preview environments, demonstrate features, and recreate bugs. C and Rust extensions used to be a blocker for this kind of thing, but any good coding agent can compile those to Pyodide-compatible WebAssembly now. You can even publish them to PyPI as of PEP 783 in April 2026. One catch is databases. SQLite is no problem at all, but running PostgreSQL or MySQL in WebAssembly, while possible, is still a path less trodden. I'd love to see WebAssembly preview environments like these become a common pattern across the Python ecosystem. For Hacker News: Full server-side Datasette Python app in the browser with service workers You are only seeing the long-form articles from my blog. Subscribe to /atom/everything/ to get all of my posts, or take a look at my other subscription options . Load client-side Datasette to browse any SQLite database, JSON file, CSV file or SQL script Select a released version of Datasette to load from PyPI Load a specific commit, tag, or branch name from the Datasette GitHub repository Pick from over 100 versions of SQLite to use with Datasette Install additional Datasette plugins from PyPI or URLs to wheel files, including JavaScript visualization tools

0 views
Unsung Yesterday

“Everything in the digital universe was going to have to get patched.”

Computers spend an enormous amount of time pretending numbers can be other things, and internet infrastructure does the same, constantly working hard to translate impenetrable IP addresses such as into friendly strings like . The details of the infrastructure are above my pay grade, but in principle it works like this: You ask your browser to visit a URL on a domain it hasn’t seen before, so it doesn’t know its IP address yet. Your computer asks a DNS server for that IP address, and the server sends it over. Now, your browser knows where to go, and fires the request directly to the website using its just-learned address. Since you don’t want to bother the DNS server with too many questions, your operating system remembers the answer in its cache for a while, so next time you visit the same server, it can retrieve the IP address from memory. The DNS server in its response even handily provides a few parent addresses to cache too (e.g. ), to further save on future network traffic. Now, I glossed over one part we gloss over every day just to say sane. “The server responds” is its own complex challenge. The Internet’s series of tubes are not those rubber hoses where one opening ends up next to someone’s mouth, and another next to the other person’s ear. No, on the internet, things are divvied up in packets that all travel together side by side, squeezed like packages on an Amazon truck, and they are only dispatched to the right precise destination at the end of their journey. Even though the DNS logic was created during an early era of the internet where computers trusted each other more, the creators recognized the risk of someone else impersonating the DNS server, and sending their own invalid response to your “translate this domain into the IP address, pls” query. So, a simple authentication system was built. When asking the server, you’d include a number only you knew – in effect, a simple password. Then, when the DNS responded, it included the same number. If you saw your number and the domain you asked about, you could have a pretty high confidence that who was responding was the server you originally asked. A wrong number? Means a mangled transmission or an impersonator, so just throw the whole thing away. This seems like a primitive system, but this sort of security by unguessability happens all the time. When you start a new Medium post, you will see this in its URL bar: = 2x) and (width >= 700px)" srcset="https://unsung.aresluna.org/_media/everything-in-the-digital-universe-was-going-to-have-to-get-patched/1.2096w.avif" type="image/avif"> = 3x) or (width >= 700px)" srcset="https://unsung.aresluna.org/_media/everything-in-the-digital-universe-was-going-to-have-to-get-patched/1.1600w.avif" type="image/avif"> The part is just a number. That number is the entire security. There’s nothing preventing you from guessing that number to get to my draft, or methodically start testing each number one by one – except the space extended by 12 hexadecimal digits, at over 281 trillion numbers, is basically astronomical, and you are not. If you checked one URL per second, it would take you 9 million years. If you checked a hundred a second, it would be 60 millennia. 10,000 per second? Still over 600 years of work. This is effectively a monkeys with typewriters scenario, let alone that at some point during those 600 years Medium would also recognize what you’re trying to do, and their systems would stop responding to your efforts and perhaps send an appropriate three-letter agency your way. This system works because the number space is incredibly vast. But for the DNS query we talked about it was only 65,536 numbers. Enter Dan Kaminsky, a security researcher with a reputation for tackling the unfun, pedestrian issues no one else cared about. In 2008, Kaminsky found himself poking at the fringes of DNS, trying to find problems and vulnerabilities. He was specifically interested in helper DNS servers. See, the caching I mentioned doesn’t just happen on your computer. DNS servers are arranged in a small hierarchy and also have a bunch of helper servers (called “public resolvers”), popular for their speed. If a helper server doesn’t know something, it asks a server closer to the truth, starting with one of the supreme court of few “root servers” at the core of the whole system, and then down the chain, sometimes a few more times. Then, after receiving the answer, it sends it over to whomever asked – but it then caches the answer for a while, too, to prevent all this effort in case the same computer or another one asks about it again, too. This means that if you could convince that helper server to cache a wrong answer, you could trick a potentially significant swath of the internet to go to a wrong IP address – sending, say, all traffic your way, and then stealing people’s passwords and credit card numbers. But you’d still have to know the one right magic number out of 65,536. This is where Kaminsky tried something different. 65K numbers is a lot for a person, but not for a computer. What if you could, indeed, monkey-and-typewriter this whole situation? What if you did it by brute force ? Say, you ask a DNS server for an uncommon version of a common URL (e.g. ) so you know it won’t have it cached. No cache means that server has to ask a server closer to the core, which takes a bit of time. But before that happens, you fake an answer from that parent server to the server you just asked. No, scratch that, you fake 65,536 answers. Now, you know the domain you asked about, so that part will match for sure. You don’t know what secret number the server communicated to its parent server, but you know that out of all the answers you generate, one will have to match. Now, you just need some luck of timing. If your answer will arrive before the official answer, it will be treated as the official one and cached – and the official one coming after yours will be rejected. (Here’s a pretty horrible real-life example: Imagine someone wanting to hijack you as you land at the airport. They know where you land, but they don’t know your name – so instead of trying to guess, they just deploy a few dozen limo drivers, each one holding a card with a different popular first name. If they time it well, you will see the fake limo driver before your limo driver – and that’s the driver you will follow to your doom.) And… the real server wouldn’t just respond with an IP address . It would also, as was customary, thoughtfully include an IP address for the entire domain while you’re at it, just to help you in the future. If your fake answer included that too, you could theoretically insert yourself in front of Amazon’s traffic. Kaminsky tried it… and saw it succeed. The consequences were huge. He later recalled: Once I saw it work, my stomach dropped. I thought, “What the heck am I going to do about this? This affects everything.” An article by Erica Naone written around that time adds: Kaminsky’s technique could be used to direct Web surfers to any Web page an attacker chose. The most obvious use is to send people to phishing sites (websites designed to trick people into entering banking passwords and other personal information, allowing an attacker to steal their identities) or other fake versions of Web pages. But the danger is even worse: protocols such as those used to deliver e-mail or for secure communications over the Internet ultimately rely on DNS. A creative attacker could use Kaminsky’s technique to intercept sensitive e-mail, or to create forged versions of the certificates that ensure secure transactions between users and banking websites. “Every day I find another domino,” ­Kaminsky says. “Another thing falls over if DNS is bad… I mean, literally, you look around and see anything that’s using a network–anything that’s using a network–and it’s probably using DNS.” And here’s Wired with its typical, exaggerated take: The problem had been coded into Internet architecture in 1983. It was 2008. Somebody must have fixed it by now. He typed a quick series of commands and pressed enter. When he tried to access the Fortune 500 company’s Web site, he was redirected to an address he himself had specified. “Oh shit,” he mumbled. “I just broke the Internet.” Kaminsky asked his friend and DNS expert Paul Vixie, who grasped the severity of the situation : I realized we were looking down the gun barrel of history. It meant everything in the digital universe was going to have to get patched. Together with Vixie, they alerted Department of Homeland Security, and then execs at networking companies. The plan was hatched: he’d work with biggest DNS vendors to quietly patch the system, and only a month after that, once everything was already corked up, he’d release the details of the finding to the public. The patch was deployed on July 8, 2008. It was as cheap as possible, basically vastly increasing the number space from 65,536 to billions (Vixie compared it to dogshit, but there wasn’t time for anything else), and Kaminsky planned to announce the details on August 6. But there was an unexpected last-minute kink in the plan, which was… someone’s curiosity. Apparently, one security expert saw the patch, and from pondering that patch figured out the problem, and exposed it prematurely on July 21. Luckily, by then things were already relatively patched up, and no one could nefariously use the original flaw. This cache poisoning problem was a nightmare some compared to Y2K, and likewise avoided – but this one without any of the limelight. Kaminsky was inducted to an Internet Hall of Fame for detecting the problem and eventual successful effort in containing it. Unfortunately, this happened only a few months after his untimely death at 42 , in early 2021.

0 views
Kev Quirk Yesterday

2026-11-17 15:52: Thinking about trying #LittleFedi but I'm not sure how it would fare on a larger...

Thinking about trying #LittleFedi but I'm not sure how it would fare on a larger fedi account. I have ~13k followers - has anyone with an account of a similar size been using it? Thanks for reading this post via RSS. RSS is ace, and so are you. ❤️ You can reply to this post by email , or leave a comment .

0 views