CREATIVE CHAOS   ▋ blog

Completely Turing (misc)

PUBLISHED ON 25/04/2023 — EDITED ON 11/12/2023 — 247CTF, INFOSEC

Intro

Long time coming, another try at the 247CTF.com site. This time a Misc challenge named Completely Turing.

Instructions

We encoded the flag in a terse, but Turing complete programming language. Can you identify the valid characters required to extract the flag?

Howto

The challenge gives you one file completely_turing:

>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>[-]>[-]>[-]>[-]++++++++[-<++++++++++++++++>]<><<<[>>>[-]<[>+<-]<+[>+<-]<-[>+<-]>]>>>[-]<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<[-]>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>[>+<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<+>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>-]>[<+>-]<[<<+>>-]<[<[<+>-]>-[<+>-]<]<[-]+>[-]>[-]>[-]+++++++++[-<++++++++++++++>]<+><<<[>>>[-]<[>+<-]<+[>+<-]<-[>+<-]>]>>>[-]<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<[-]>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>[>+<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<+>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>-]>[<+>-]<[<<+>>-]<[<[<+>-]>-[<+>-]<]<[-]++>[-]>[-]>[-]+++++++++++[-<++++++++++++>]<+><<<[>>>[-]<[>+<-]<+[>+<-]<-[>+<-]>]>>>[-]<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<[-]>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>[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]<+[>+<-]<-[>+<-]>]>>>[-]<<<<<<<<[-]>>>>>>>[>+<<<<<<<<+>>>>>>>-]>[<+>-]<[<<+>>-]<[<[<+>-]>-[<+>-]<]<>[-]><>[-]<<[-]>[>+<<+>-]>[<+>-]<><[-]>[-]<<[>+>+<<-]>>[<<+>>-][-]++><<>>[-]>[-]<<[>[-]<<[>>+>+<<<-]>>[<<+>>-]+>[[-]<-<<->>>]<<-]<[-]>>[<<+>>-]<<[><[-]>[-]<>+++++++[-<++++++++++++>]<+++.>++++[-<++++>]<+.-------.>+++[-<++++++>]<+.>+++++++[-<------------>]<.>++++++++[-<+++++++++>]<+.++++++++++.>+++++++++[-<--------->]<--.>+++++++[-<++++++++++++>]<.------------.---.>++++++[-<----------->]<---.>+++++[-<+++++++++++++++>]<.------.>++++[-<+++++>]<.>++++++++[-<----------->]<-.>++++++++[-<++++++++>]<+.>+++[-<++++++>]<+.>+++++++[-<------------>]<.>++++++++[-<+++++++++>]<+.+++++.----------.+.>+++[-<++++++>]<+.>++++++++[-<----------->]<.[-]>[-]>[-]<<<[>>+>+<<<-]>>>[<<<+>>>-]<<>>[-]>[-]>[-]>[-]>[-]>[-]>[-]>[-]>[-]>[-]<<<<<<<<<<>>++++++++++<<[->+>-[>+>>]>[+[-<+>]>+>>]<<<<<<]>>[-]>>>++++++++++<[->-[>+>>]>[+[-<+>]>+>>]<<<<<]>[-]>>[>++++++[-<++++++++>]<.<<+>+>[-]]<[<[->-<]++++++[->++++++++<]>.[-]]<<++++++[-<++++++++>]<.[-]<<[-<+>]<<><[-]>[-]<>+++++++[-<+++++++++>]<.>++++[-<------------->]<-.[-]>[-]<<[>+>+<<-]>>[<<+>>-][-]>[-]><,><<<[>>>[-]<[>+<-]<+[>+<-]<-[>+<-]>]>>>[-]<<<<<<<[-]>>>>>>[>+<<<<<<<+>>>>>>-]>[<+>-]<[<<+>>-]<[<[<+>-]>-[<+>-]<]<[-]><,>[-]++++++++++><<[->-<]>[<+>[-]]<[[-]><,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-]<[-]>>[<<+>>-]<<]<[-]>[-]<<[>+>+<<-]>>[<<+>>-]<>[-]+<[>-<[-]]>[<+>-]<[[-]>[-]<>++++++++[-<+++++++++++>]<+.>+++[-<+++++++>]<+.++++++.>+++++++[-<------------>]<-.>++++++++[-<+++++++++>]<.-------.>+++[-<+++++++>]<.>++++[-<---->]<-.>++++++[-<----------->]<---.>++++++[-<+++++++++++>]<+++.+++++++++.++++++.>+++[-<----->]<.+++++++++++++.-------------.-.>++++++[-<----------->]<--.>++++++++[-<++++++++>]<+.+++++++++++++.>++++++[-<------------->]<.>++++++++[-<+++++++++>]<+.+++++.++++++++.>+++[-<------->]<.+++++++++++.---.-----.>++++++[-<----------->]<--.>+++++[-<+++++++++++++++>]<.------.>++++[-<+++++>]<.>++++++++[-<----------->]<-.>+++++++++[-<+++++++++>]<+.>++++[-<---->]<-.+++++++++++++.-------.--.>++++++[-<----------->]<--.>+++[-<------->]<--.[-]][-]>[-]<>+++++++[-<++++++++++++>]<.>+++++[-<++++++>]<.+++++++.>++++[-<---->]<.+++++.-------.>+++++++[-<---------->]<-.>+++++++[-<++++++++++++>]<.-----.>++++++[-<------------->]<-.>++++++[-<+++++++++++>]<++.+.--.++++++++++++.-----------.+.>++++++[-<----------->]<---.>+++++++[-<++++++++++++>]<.------------.---.>++++++[-<----------->]<---.>+++++++[-<++++++++++>]<.++++++.-----------.++++++.>+++++++[-<-------->]<-..>++++++[-<------>]<.>[-]><>[-]<<[-]>[>+<<+>-]>[<+>-]<><[-]>[-]<<[>+>+<<-]>>[<<+>>-][-]>[-]+++++[-<++++++++>]<><<>>[-]>[-]<<[>[-]<<[>>+>+<<<-]>>[<<+>>-]+>[[-]<-<<->>>]<<-]<[-]>>[<<+>>-]<<[><[-]>[-]>[-]<<<[>>+>+<<<-]>>>[<<<+>>>-][-]<[>>[-]<+[>+<-]<-[>+<-]>]>>[-]>[-]<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<[>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>+>+<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<-]>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>[<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<+>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>-]<[<<+>>-]<[<[<+>-]>-[<+>-]<][-]>[-]<<<<[>>>+>+<<<<-]>>>>[<<<<+>>>>-][-]++><<>>[-]>[-]<<[>+>+<<-]>[<+>-]>>[-]+<[>-<[-]]>[<[-]>[-]<>++++++[-<+++++++++++>]<+++.>+++++[-<+++++++++>]<..---.+++.>+++++++++[-<--------->]<-.+++++++++++++.-------------.>++++++[-<++++++>]<.>++++++[-<++++++>]<+.+++++++++++++.-------------.++++++++++.----------.++++++.-.>++++++[-<------------->]<.>++++++[-<+++++++++++>]<.>+++[-<+++++++>]<++.>++++++++[-<----------->]<-.>+++++++++[-<++++++++++>]<.>+++[-<------->]<.+++++++++++++.---.>++++++++++[-<---------->]<-.[]>-]<<<<>>[-]>[-]>[-]>[-]<<<<<[->->+<[->>>+>+<<<<]>>>>[-<<<<+>>>>]<>[-]+<[>-<[-]]>[<<+<[-<+>]>>>-]<<<<<]>>[<<+>>-]<[-]<[>>[-]<+[>+<-]<-[>+<-]>]>>[-]>[-]<<<<<<<<<[>>>>>>>>+>+<<<<<<<<<-]>>>>>>>>>[<<<<<<<<<+>>>>>>>>>-]<[<<+>>-]<[<[<+>-]>-[<+>-]<]<<>[<->-]<<>.<><<>[-]>[-]<<[>+>+<<-]>>+[<<+>>-]<[-]>[-]<<[>+>+<<-]>>[<<+>>-][-]>[-]+++++[-<++++++++>]<><<>>[-]>[-]<<[>[-]<<[>>+>+<<<-]>>[<<+>>-]+>[[-]<-<<->>>]<<-]<[-]>>[<<+>>-]<<]<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<

One can easily see that the pattern is of the programming language Brainfuck.

Lets try to run it in a virtual machine (Debian), first we need an interpreter:

$ apt install beef

Testing it with random inputs:

$ beef completely_turing
What is the key at index 0?
A
What is the key at index 1?
B
Trying to decode the flag..
?=DLaO�mplnmnlrjA<Am=oD;sjp@=@s;?nnm>@n�%
$ beef completely_turing
What is the key at index 0?
3
What is the key at index 1?
Z
You have entered an invalid key range!
Trying to decode the flag..
M%R4o7�U~T|U|T�RO$OUKWR#�R~(K(�#MV|UL(|n%

By brute forcing the search space keys, we are trying to find the valid range, in this case A-Z.

Next step is to input all possible permutations of the keys in the range (~1300). Doing that by hand is okay, but there is a better way. Probably there are easier and more clean ways, but this was the quickest for me:

# bash execute.sh | grep 247
from string import ascii_uppercase

for i in ascii_uppercase:
    for j in ascii_uppercase:
        print(repr("printf '"+i+"\n"+j+"\n' | beef completely_turing"))
python3 solution.py | tr -d '"' > execute.sh
bash execute.sh | grep 247

See Also