Hacker News new | ask | show | jobs
by andai 28 days ago
I don't get it, in this scenario, would people also vibe code (the equivalent of) the PHP interpreter?
4 comments

I think a better comparison for the parent is probably left-pad.
I've been playing around with LLM red teaming different server stacks with known or intentionally vulns in there and seeing how much damage they can do.

The one situation where they really can't get anywhere profitable is a unikernel webapp. With no source and no shell they find the vuln but the worst they can do with it is possibly poison or exfiltrate data as a one off, or crash the server. Often they can't even figure that out. Can't even leave themselves a reliable way back in.

Of course the traditional problem with unikernels is that you have to port EVERYTHING you need yourself. But the cheapness of this is exactly what we're talking about so.

Looks like security through obscurity's back on the menu.

Obscurity as a tool in security has never left. It shouldn't be a tool you depend on by itself. Update your ssh server when there are patches available. Use strong keys or ssh certificates. Disallow old, broken key exchange methods. Having an allow list in your firewall ACLs helps. Maybe only allow ssh from your internal network and make users outside your network be on the VPN. Maybe even have dedicated bounce boxes between user networks and the production systems.

But putting ssh for those bounce boxes on a nonstandard port that doesn't even show up to a remote system within the network until they've port-knocked on another two or four ports in the proper order on top of all that does not hurt security. Using a separate internal DNS zone that nobody outside your network has access to resolve doesn't hurt. Having your firewall drop packets from invalid sources instead of rejecting them doesn't hurt.

These last few months, I have been building a capability-based language and runtime for fun based on the "port EVERYTHING" idea.

The language is restricted to permissions granted on startup and can only access the system via the runtime, which only supports a particular subset of linux syscalls. So, outside of the stdlib, whichever feature you need, you simply use an LLM to port an existing python/rust/JS/TS/Java library to the language and use it.

As the runtime has its own scheduler and GC, I have actually been wondering about the feasibility of skipping the linux kernel and making the runtime itself the "os." Given that so much modern hosting is actually done on virtual hardware, the drivers could be hosted within the runtime as well.

That's exciting! I'm interested to hear about the language design. I vibecoded a unikernel web server a few weeks ago, and I've been trying to extend it into a full capability-secure microkernel called KokalOS.
The language borrows syntax from Python (and a wee bit from Haskell) and is essentially syntactic sugar over facilities provided by the runtime:

- statically typed from end to end

- closed and open/extensible types

- closed types are immutable, open ones have two variants: immutable and mutable

- arrays have two variants: immutable and mutable

- no OOP/classes. inheritance is nominal and mainly exists to provide access to class membership (is X a Y?)

- functions operating on data

- UFCS exists to provide nice features like "apple".substr(...)

- first class functions and closures

- monomorphized generics

- tailcalls

- operator overloading

- modules and namespaces to control access

- erlang/beam style first class processes. So you `spawn` a function and communicate between processes using send/recv instead of async/await

Processes are completely isolated at the runtime level. Each has its own stack, heap, mailbox and GC.

The bytecode carries all type information. The VM will compile using AOT-on-load.

My own runtime-becomes-a-os idea is still just an idea. I haven't really pursued it with seriousness. Will probably do that once the language and runtime stabilize.

It sounds like you already have a pretty complete OS; you just don't have it running on bare metal (or on a hypervisor) yet. I hope I get a chance to see the language someday!
I will publish the code when done to a GH repo over here: https://github.com/orgs/bhashika-org-in

I started in March and have gone through nearly 300 spec revisions for the runtime and language. Thanks to LLMs, I think I will have something useful to share in 2027.

My problem is that I have ten things in the pipeline at any given moment and I switch between them as time permits. So things get delayed a bit.

> KokalOS

A bare bones microkernel?

What do you mean?
I was trying to guess the meaning of the name.
Obscurity in the sense that the bad guy doesn't have your code doesn't hurt, but I think the real win could be that they need to specifically target your system to find your vulnerabilities. That could be a lot of compute and time to dedicate to a single target. So that kind of obscurity changes the economics of it for them.
What sorts of vulns are they finding in unikernels? Logic bugs, that sort of thing, or are there areas where they could get that tiny scope to do anything at all?

The advantage there shouldn't be obscurity, so much as very limited attack surface in the whole exposed stack.

That sounds like a very reasonable thing to do, yes. If you ask Opus 5.5 to write you a dynamically typed interpreted language that can query a local SQL database, implicitly parse HTML form submissions, and be embedded in HTML templates interpreted by an Apache module, you'll probably have a usable alternative to PHP in 37 minutes. And if you ask it to do it in Rust with no unsafe, it won't have any memory error vulnerabilities.
You could have a new web server and database too. Maybe a new one every other day created from a cronjob so you aren't a stationary target.
I assume that was sarcastic but I think it would actually work fairly well? At least if the ends could justify paying for that many tokens.
No, I sincerely try to avoid sarcasm, and I try to remember to down vote it when I see it. It's tough to get tone across in a text forum though, so I understand the confusion.

Big picture, I think we should explore what's possible when software is disposable.

I didn't think it was sarcastic, but it's far enough outside the Overton window that I could see why someone would.
I was saying that you could just not have exploitable bugs, at least of the memory-safety variety that was on display in PHP2hell, not that you could mitigate the exploitability of the exploitable bugs you will inevitably have.

Which, probably, you will also have to do.

I suspect that a more effective mitigation to having exploitable bugs would be to have an LLM read all your HTTP requests and the actions the web server proposes to take in response and give a Jev-like approve/disapprove decision.

All good, but I suspect we're thinking about different aspects. If I understand correctly, you're pointing out that nobody is tied to legacy software any more - they can spend 37 minutes to re-implement from scratch in a safe(r) language.

My point is that everyone doing their own thing their own way means an attacker doesn't get the next thousand sites for free after finding a vulnerability in one site.

Having an LLM as sentry is a fun idea too.

Right, I agree.
Yeah I guess, if they liked PHP. Could make a new version of ColdFusion if that's your thing too.

Genetic monocultures like bananas are at risk from a single species of fungus.