4 ms·
I was not bullish on AI generated code until last week. Last week I asked GPT to write a C version of dirbuster using the POSIX api. It returned a nearly corre
by r3trohack3r 4y ago
I was not bullish on AI generated code until last week.
Last week I asked GPT to write a C version of dirbuster using the POSIX api. It returned a nearly correct solution (paths weren’t prefixed with /).
Then I asked it to rewrite the program using threads. And again, it kicked out a nearly correct solution (same path bug).
For each it gave me instructions for compiling and told me how to run the binary.
Then I asked it for a word list, and it gave me a GitHub repo to clone and told me how to use it with the binary I just compiled.
Then I described the behavior of the service I was scanning (always returns 200 with status=ok when another service would have returned 404) and asked it for a git diff of the threaded version of the program that worked with this service.
Then I described the missing / prefix and it gave me a gif diff for that too.
In both cases the git diff was valid.
And, after applying the git diff and running the binary against the word list, the program scanned the service finding the /ping endpoint.
- moffkalast 4y agoPuts on whoever's not gonna be pair coding with LLMs.
- awb 4y agoI can’t imagine not coding with AI after just a week or two of experimenting. For complex tasks, I define the function signature and the dependencies and it does it with minor fixes needed. Most times I can copy/paste the error message and it’ll fix it. Worst case scenario is it hallucinates a function and I have to remind it that that function doesn’t exist.