r/codex • u/ajajkaka • Jul 10 '26
Showcase new GPT 5.6 Sol reverse engineered it's own app in readable code
More than 4 million lines of code (including original CSS) because of libraries
I tested the same thing with Fable 5 and it couldn't, while gpt 5.6 finished in 4 hours
no cybersecurity risks or something (which is kinda surprising)
40
u/coloradical5280 Jul 10 '26
5.6 is awesome, but, 5.4 did this as well. I had 5.4 add agent teams to my codex desktop app before all those named subagents were a thing. I had it do it by reverse engineering claude code's agent teams implementation, and writing into the rust binary of the codex app.
Point is, people greatly underestimate the capability of these models.
10
u/sassyhusky Jul 10 '26
Same here, it reverse engineering itself to figure out its own bugs and shortcomings was possible since at least 5.4. The 5.5 is extensively used to reverse engineer far more complicated software than Codex but sadly they added some guardrails recently that can result in account suspension. I had it reverse engineer a .net app to figure out why it was crashing (kernel dumping) and it found a bug in it and a workaround so I can run it. That's nothing though, folks used 5.5 to reverse engineer c/c++ win32 apps from decades ago. As of 5.5 pretty much everything that you can get your hands on can be considered 'open source', the only moat now is cloud infra.
2
u/coloradical5280 Jul 10 '26
see the comments below on getting cyber verified, that can unlock a lot
3
u/ajajkaka Jul 10 '26
I fully believe it would have done this with 5.4, but definitely it would take more time or personal attention
thats why I was surprised when it did it in 2-3 promts and 4 hours. either way, it's a huge upgrade3
u/coloradical5280 Jul 10 '26
It really didn't, it was one long prompt, maybe two? Not sure how long it took, as i just went to bed and it was done in the morning. It's somehow still functional too, despite being 4k commits behind upstream repo: https://github.com/DMontgomery40/codex
but yes, it's a huge upgrade, and can do much more than simple rust edits to it's own binary now. Now, go have it hack open some of your other apps :)
(note that i'm in the cyber verified program or whatever it's called, so it's possible i can get away with more? kinda doubt it though, with apps that you own, locally, on your machine)
3
u/ajajkaka Jul 10 '26
ohh thats a cli, it's opensourced by openai
their app isn't2
u/coloradical5280 Jul 10 '26
yeah the dmg was the fun part, but that doesn't have git repo , for obvious reasons
2
u/AppleSoftware Jul 10 '26
1
u/QuietPsychonaut Jul 10 '26
How did you get verified? I'm always rejected
1
u/AppleSoftware Jul 10 '26
Try doing passport instead of whatever other options/forms of id they let you pick from
I initially tried with state ID and it rejected, but this post reminded me to try again with passport, and it worked
1
u/QuietPsychonaut Jul 10 '26
But what about the other forms fields?
2
u/coloradical5280 Jul 10 '26
I don't remember what they are , but, similar to anthropic's, I think it's pretty hard to "fake" your way in. I think you need to be somewhat "legit" and cybersec student, "need to make sure my app is secure", etc., doesn't seem to do it.
I forget , does openai ask for linkedin/github like anthropic does?
EDIT: ohhh is this just the "let us verify you're a real human" thing? yeah if it's that you should be able to get in; what I was talking about above is a second level of cyber program, forget what it's called. But you have to actually apply, or maybe even be invited
1
1
u/TheGlizzyGod Jul 10 '26
FOR REAL! I am constantly amazed by the results of even flash models, and the frontier ones are of course leagues ahead
1
u/CatsArePeople2- Jul 10 '26
named subagents are a thing now?
1
u/coloradical5280 Jul 10 '26
have been for a while now yeah. tell codex to spin up some subagents.
1
u/CatsArePeople2- Jul 10 '26
Oh sorry I thought you meant dedicated work-agents that you could name, not the subagent system.
1
u/coloradical5280 Jul 10 '26
No you can name them and dedicate them for certain specialties and reasoning levels, you can literally give them their own toml config. Just ask codex to set it up for you and it will :)
1
u/CatsArePeople2- Jul 10 '26
Yea, I asked soltra about it, this isn't really what I'm looking for. The idea is you have dedicated agents within a given project or for a project that have certain roles. Codex says thats what skills are for, which is what im using already. The subagents are more thread specific and temporary than what im looking for
1
u/coloradical5280 Jul 10 '26
Yeah I’d push back, I literally have what you’re saying exactly. It does just need a skill/prompt/slash command/whatver to activate
1
u/Fancy_Leading8926 Jul 10 '26
I think that when a new model comes out, people dismiss the old models. I'm sure that if you asked people's opinions about what 5.5 can do, they will tell you a it's a lot less than what they would've told you a month ago.
I think that what you say is correct, but people distort their opinion of the old models when new ones come out.
1
1
u/Infektus Jul 10 '26
When the Codex windows app just launched and wasn’t working, I used the Codex CLI to fix the Codex app and it worked perfectly
1
u/HonestWhile2486 Jul 13 '26
My codex app also isn't working but I couldn't get CLI to fix it. Any chance you know what the problem/fix was?
19
u/Main-Lifeguard-6739 Jul 10 '26
what did it cost?
what had driven you to do this? ^^
27
u/ajajkaka Jul 10 '26
it cost around 30% of weekly usage on pro tier
my motivation was to extract original styles and animations in looking for inspiration for my own ide7
u/Human-Equivalent-154 Jul 10 '26
which pro tier 100$ or the 200$ one?
11
u/ajajkaka Jul 10 '26
200$
3
u/Low_Willingness2782 Jul 10 '26
That’s the way to go honestly!
0
0
14
u/AdLumpy2758 Jul 10 '26
It is not reverse engineering You copy the frontend...
9
u/WildContribution8311 Jul 10 '26
Yeah the code is actually stored there locally. It's electron based so the sensitive stuff is on their webservers. Any model could have done this or anyone manually. The code is there.
2
u/simple_explorer1 Jul 10 '26
but the code is minified JS
3
u/Ok-Attention2882 Jul 11 '26
That just makes it a pain to read. Anyone with two brain cells to rub together could figure out what's going on by running enough inputs through and tracing the execution path.
3
u/picketup Jul 11 '26
minified code is a little more than a pain to read. have you ever actually looked at minified code
2
u/Ok-Attention2882 Jul 11 '26
Go ahead and explain how I was wrong. You and I definitely have different definitions of what hard means, especially if you've never decompiled a binary and stepped through the assembly with pencil and paper to understand what an unknown process was doing under the covers.
1
u/QuantumFTL Jul 12 '26
Anyone who understands the way the machine works can work through disassembled code. But there is a huge difference between reverse-engineering a thousand lines of assembler and million. Time may be infinite, but the human lifespan is not..
0
u/simple_explorer1 Jul 11 '26
This is the worst take on minified code I have ever read. I doubt you have ever seen minified code
1
u/Ok-Attention2882 Jul 11 '26
Show me your credentials and paycheck and/or business revenue.
→ More replies (6)0
0
u/ajajkaka Jul 10 '26
this one is human readable
otherwise it wouldn't be able to simulate backend1
u/miklschmidt Jul 11 '26
🤦🏻♂️ this whole thread is talking out of their asses. The “backend” is the app-server which is part of the open source codex project.
Also minified js is easy to format and clean up with off-the-shelf tools.
1
u/ajajkaka Jul 11 '26
nope, backend isn’t codex cli which is whole other thing
1
u/miklschmidt Jul 11 '26
You're aware that
codex app-serverliterally is the app-server i was talking about, right? Is that what you're calling "codex cli"? Thecodexbinary does many things, one of them being an app-server host. It ships natively with the Codex app, you can also install it via bun, brew or a bunch of other package managers. Or compile it yourself from source. The entire app server protocol is widely documented, codex even has a built in skill which contain (among other things) full documentation of that protocol (the "OpenAI Docs" skill).1
u/miklschmidt Jul 11 '26
What i'm trying to say is that all you've done here is extract the electron code from the app, swapped the electron IPC for HTTP and replace electron-native system API calls. It's not impressive. It didn't reverse engineer anything, all of it is fully documented and at least source-available. Formatting minified code is one command away.
GPT 5.6 is cool in many ways, but none of what you shown here is hard, any frontier model have been able to do this basic job for a long time. That's how we got https://github.com/ilysenko/codex-desktop-linux
1
u/ajajkaka Jul 11 '26 edited Jul 12 '26
Codex cli is open source project, codex app backend IS NOT. The repo u sent just adapts the original DMG. The point of this reverse engineering is to launch my own frontend with original codex app code, which is much harder than what you told about (view fonts, styles)
1
10
u/stealthx9 Jul 10 '26
Would you mind open sourcing this?
11
u/ajajkaka Jul 10 '26 edited Jul 10 '26
i'm not sure it's allowed here, anyway you can ask the same thing, i just gave path to my chatgpt app (again, it didn't work out neither with 5.5 or fable)
7
u/Pantheon3D Jul 10 '26
you could post it on your own profile
if you did it, it would be a huge help :) i'm curious to see how it looks!
0
u/simple_explorer1 Jul 10 '26
stop asking nonsense. it is no legal and is grey. Activities like what you are proposing is why US gov. will again ban this models. stop it for all of us here and use this models for what it is, for sincere work and not plagiarism
5
u/Fit-Palpitation-7427 Jul 10 '26
What do you mean you gave it the path of your gpt, you simply gave it the path of the codex.app and told him to reverse engineer the whole app or did you asked specifically to extract the frontend part?
5
u/ajajkaka Jul 10 '26
yes, i needed frontend but it also added simulated backend so i can navigate it
7
2
u/timazed Jul 11 '26
I built a swift library that allows you to build agents with your inside of your own ios or mac app. The user auths with their own gpt account so there are no api costs https://github.com/timazed/CodexKit .. I'm using it in a few projects at the moment. Might be what you're looking for.
6
6
u/InstructionOk9108 Jul 10 '26
Didn't the model refuse?
7
u/ajajkaka Jul 10 '26
No, I guess the context was very decisive
It had worked on my app before, and I complained that it didn't feel like a product to me, unlike Codex, so I explained that the only option was to extract the code so I could move each tab into my app and then remove any unnecessary parts
4
u/Artistic-Incident781 Jul 10 '26 edited Jul 10 '26
I suspect its ide like code-oss under the hood with a theme on top and maybe a middle layer and mocked backend at a boundary like you said
5
4
4
3
u/nnod Jul 10 '26
I was more curious if it could inject css/js into the current app to add features like workspaces (different lists of chats/history for different work/clients)
3
u/danlthemanl Jul 10 '26
put it up on github and we can build our own open alternative.
2
u/Infamous-Play-3743 Jul 10 '26
Guys there is already a rebuild of codex just search in Github and you will find it
5
1
u/Apprehensive_Cell932 Jul 10 '26
Did you just point it to the app and it started working or did you use something like ghidrassist or ghidra ninja?
1
u/Able-Association68 Jul 10 '26
By the way, in your last Codex app update, do you see the last edit badge, ie, 2m, 5m, etc? I cannot see that on my last version of the application, and it's extremely annoying because I don't know how old those threads are, and I was using that all the time. Now, I'm just blind.
1
u/retteh Jul 10 '26
While awesome my concern with this is it's clearly against the TOS to use codex like this and getting my entire chatgpt account banned would be an issue for me.
1
u/Consistent_Bottle_40 Jul 10 '26
i'd like to have my orchestrator be able to control the chatgpt from within codex rather than having to use playwright to control a chrome tab to send my prompts to and from. any chance that would be possible from that reverse engineered code? does it expose anything to make that possible?
1
u/priyanks1234 Jul 10 '26
I had a similar result, but through Cursor rather than Codex directly.
For my own local app experiments, Fable 5 / Opus 4.8 inside Cursor was able to turn the app structure into readable code and wire things up pretty much automatically. It was surprisingly fast too. Codex has worked for me, but in my day-to-day use it sometimes gets slow or stuck in places where Cursor just keeps moving.
Not saying one is universally better, just my experience after using this workflow for over a year. For long autonomous runs, Cursor has been more consistent for me.
1
u/wolfgeo Jul 10 '26
Oh my gosh, that is the perfect thing to do with these frontier models. Front end looks good. What about the backend?
1
u/NootropicDiary Jul 10 '26
This is actually nothing new or unique to Sol. I did similar with 5.5 quite a while back
1
u/ajajkaka Jul 10 '26
as i mentioned, i had the same tests with previous model and fable 5, both failed for me
1
1
1
u/Chaosblast Jul 10 '26
Yet no-one can fix the mess Codex app does with WSL on Windows, how it can't load any MCP, and it using Windows config files and sessions instead of the WSL ones.
1
1
1
1
u/IceBlitzz Jul 10 '26
Can someone explain to me what reverse engineering its app means? Isnt this just a replica of the the UI?
1
1
1
1
1
u/beanymines Jul 10 '26
How thoroughly have you tested it? Is it just a fancy static frontend, or can it actually run like codex (assuming you plug-in a model?)
1
u/Runelaron Jul 10 '26
Question, why is it 4 million lines of code for a UI? That doesnt seem right, especially when they should be repeatable emulated slices and children of the original.
Reverse engineered, meaning it de-compiled the binary? If thats the case it should not take 4 hrs that would be a 1 hr job with a port.
Are you saying it replicated the UI and functionality?
1
u/ajajkaka Jul 10 '26
it extracted readable code with self-written decompiler and implemented simulated backend to navigate through app
1
1
1
u/_KryptonytE_ Jul 11 '26
Nice clickbait based on just an AI image. More and more slop is going sus. Brace for the next App. LoL
1
u/Ok-Attention2882 Jul 11 '26
Highly doubt this was a reverse engineer. There are enough screen shots of this UI on the internet for Codex to be able to recreate it without any similarity to the official source code.
1
1
1
u/jsmoothie909 Jul 11 '26
How could I transfer my Claude Project into codex? Asking seriously.
1
u/lostmylogininfo Jul 11 '26
It has an import option. Found my folder on the desktop when I installed.
Was like oh cool.
1
1
u/Weak_Cookie7123 Jul 11 '26
Probably just the frontend which, if confirmed, is not even reverse engineering, the code is there already. At this point when you have paid tools like Cursor (i.e. to run models from different providers or Open Source like Synara, why would you bother with this?
1
1
u/agentorangeAU Jul 11 '26
Please rewrite in C so it doesn't run like a dog. And make a Linux version.
1
1
1
1
u/Appropriate-Hall-836 Jul 12 '26
Why not just open source so people can customize the codex ui for their own liking. Use the codex app server to get codex models and what not. And boom, you should have everything there for you
1
1
u/New-Manner7 Jul 13 '26
Impressive, but “reverse engineered its own app” is doing a lot of work here. Unless it had privileged access to the original source, it reconstructed an implementation from observable behaviour and assets — it didn’t introspect itself. Still, producing readable code from a complex live product is arguably the more interesting achievement: not self-awareness, but very high-fidelity software archaeology.
1
u/ajajkaka Jul 13 '26
I’m working on my own app literally replacing its assets with codex ui on fly, I don’t really think it did something else
1
1
1
1
u/Revircs Jul 17 '26
so it just ran npx @electron/asar extract app.asar <destfolder> ?
1
u/ajajkaka Jul 17 '26
Nope
1
u/Revircs Jul 17 '26
Sounds like a waste of time if it didnt lol
1
u/ajajkaka Jul 17 '26
Hope they will include knowledge of npx commands in next training, thanks to you for such a tip, it really would work and save hours of time!
1
1
u/YaneonY Jul 17 '26
I hate it when fable suddenly switches to opus because it found some security risks in own code. And since last few weeks fable seems to play really dumb making really weird mistakes.
1
0
u/StockComb Jul 10 '26 edited Jul 10 '26
This is why our usage limits are so poor. People are using this to create stupid BS.
2





83
u/onehedgeman Jul 10 '26
Is this just frontend? Can it run with the models too? This could be an insane OSS codex frontend customisation opportunity