hgarrereyn.bsky.social
@hgarrereyn.bsky.social
Regardless, I think 2025 is going to be an interesting year for CTF...
April 17, 2025 at 10:40 PM
While this was enough for us to solve nfuncs1, it was a bit too slow (and expensive for nfuncs2) and we ended up switching to a manual heuristic-recognition script, but failed to solve in time...
April 17, 2025 at 10:40 PM
It was surprisingly capable! Able to automatically recognize a function like the following as an AES S-box based key expansion, and write Python to solve it automatically.
April 17, 2025 at 10:40 PM
TLDR: we equipped o3-mini with access to Python and gave it the Binary Ninja HLIL representation of functions. We asked it to identify the user input constraints and subsequent XOR key for each function. Then validated its output, checking if the decoded function was sensible.
April 17, 2025 at 10:40 PM
Hmm is the solution to only give the llm tools when we think it will need to use them?
December 18, 2024 at 4:24 AM
Pretty neat! We can effectively prompt the LLM using code in a way that lets us extrapolate beyond the initial prompt in a programatic way.

I've packaged this up in a small POC: https://github.com/hgarrereyn/omni

TLDR:
from omni import Omni
o = Omni()
o.execute('''
# anything here
''')
November 30, 2024 at 7:21 PM
Finally, lets hypothesize a `Gif` object on which we can `add_frame`:
---------------------
g = Gif()
for i in range(10):
c = Canvas()
c.add_random_shapes(num=100)
r = c.render()
g.add_frame(r, ms=20)
g.save
('./out.gif')
---------------------
Producing:
November 30, 2024 at 7:21 PM
Now that we have this implementation however, we can adjust parameters without needing to invoke the LLM again:
---------------------
c = Canvas()
c.add_random_shapes(num=100)
c.draw
()
---------------------
November 30, 2024 at 7:21 PM
Let's hypothesize an API which places random shapes:
---------------------
c = Canvas()
c.add_random_shapes(num=5)
c.draw
()
---------------------
LLM is invoked to figure out what `add_random_shapes` should do, and we get:
November 30, 2024 at 7:21 PM
Now we introduce a new undefined api:
---------------------
...
t = Triangle(width=3, height=5)
t.set_origin(6,6)
t.set_color('blue')
...
c.add(t
)
---------------------
LLM is invoked to update the context code and we get:
November 30, 2024 at 7:21 PM
The existing context code can extrapolate to new usages:
---------------------
...
r2 = Rect(width=3, height=3)
r2.set_origin(2, 2)
r2.set_color('red')
r2.set_rotation(deg=10)
...
c.add(r2
)
---------------------
We don't need to invoke the LLM here, but can render:
November 30, 2024 at 7:21 PM
E.g. lets write the following:
---------------------
r = Rect(width=4, height=6)
r.set_origin(5, 4)
r.set_color('green')
r.set_rotation(deg=45)

c = Canvas()
c.add(r
)
c.draw
()
---------------------
LLM generates context code that allows us to render:
November 30, 2024 at 7:21 PM