InsomniHack ’17 – Cryptoquizz

It was the First CTF of the year 2017 , Team Bi0s was ready and so was R3x. The Team finished 34th Globally and 1st in India.

The python script R3x used for getting the flag was:



from telnetlib import Telnet
import sys
dict1={'Daniel J. Bernstein ?':'1971',
        'Mihir Bellare ?':'1962',
        'Mitsuru Matsui ?':'1961',
        'Michael O. Rabin ?':1931,
        'Alex Biryukov ?':1969,
        'Amos Fiat ?':1956,
        'Ronald Cramer ?':1968,
        'Yehuda Lindell ?':1971,
        'Alan Turing ?':1912,
	'Donald Davies ?':1924,
	'Don Coppersmith ?':1950,
	'Ron Rivest ?':1947,
	'Amit Sahai ?':1974,
	'Eli Biham ?':1960,
	'Phil Rogaway ?':1962,
	'Lars Knudsen ?':1962,
	'Jim Massey ?':1934,
	'Whitfield Diffie ?':1944,
	'Horst Feistel ?':1915,
	'Niels Ferguson ?':1965,
	'Rafail Ostrovosky ?':1963,
	'Shai Halevi ?':1966,
	'Neal Koblitz ?':1948,
	'Dan Boneh ?':1969,
	'Gillis Brassad ?':1955,
	'Daniel Bleichenbacher ?':1964,
	'Douglas Stinson ?':1956,
	'Martin Hellman ?':1945,
	'Bart Preneel ?':1963,
	'Markus Jakobsson ?':1968,
	'Serge Vaudenay ?':1968,
	'Nigel P. Smart ?':1967,
	'Oded Goldreich ?':1957,
	'Wang Xiaoyun ?':1966,
	'Jacques Stern ?':1949,
	'Ueli Maurer ?':1960,
	'Moni Naor ?':1961,
	'Paul van Oorschot ?':1962,
	'Ralph Merkle ?':1952,
	'Scott Vanstone ?':1947,
	'Victor S. Miller ?':1947,
	'Paul Kocher ?':1973,
	'Adi Shamir ?':1952,
	'Gilles Brassard ?':1955,
	'Paulo Barreto ?':1965,
	'Taher Elgamal ?':1955,
	'Silvio Micali ?':1954,
	 'Claus-Peter Schnorr ?':1943,
	'Shafi Goldwasser ?':1958,
	 'Kaisa Nyberg ?':1948,
	'Jacques Patarin ?':1965}
HOST='quizz.teaser.insomnihack.ch'
PORT=1031
tn = Telnet(HOST, PORT)
final_str=''

def main():
	startup()
	
def startup():
	i=0
	while(i<8):
		data=tn.read_until('of ',3.0)
		str_=tn.read_until('?',3.0)
		print str_
		tn.write((str(dict1[str_])+'\n').encode('ascii'))
		i=i+1
	final=tn.read_all()
	print final
main()

R3x used the Telnet module to connect to the address and a dictionary to store the names and the dates of birth of the people mentioned in the challenge.

After Running the script the flag we get

INS{GENUINE_CRYPTOGRAPHER_BUT_NOT_YET_A_PROVEN_SKILLED_ONE}

Leave a comment