From 04f49f9cf37bc61e2cd6874fb1698dac16841a49 Mon Sep 17 00:00:00 2001 From: Astro Date: Tue, 13 Dec 2011 22:15:21 +0100 Subject: [PATCH 1/4] index: joker pics --- index.html | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/index.html b/index.html index 25576ec..0abed91 100644 --- a/index.html +++ b/index.html @@ -36,6 +36,7 @@ +
  • 0
    @@ -45,6 +46,7 @@ +
  • 0
    @@ -54,6 +56,7 @@ +
  • @@ -101,6 +104,7 @@ +

    @@ -111,6 +115,7 @@ +
    @@ -121,6 +126,7 @@ +
    From d856eb861caa0a30ac515825e63f5bcf18e8ef89 Mon Sep 17 00:00:00 2001 From: Astro Date: Tue, 13 Dec 2011 23:05:26 +0100 Subject: [PATCH 2/4] fix ingame joker display --- quiz.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/quiz.js b/quiz.js index 30de9f0..0fb4a6f 100644 --- a/quiz.js +++ b/quiz.js @@ -208,8 +208,10 @@ function updateScores() { $('#players .player'+i+' .score').text(playerScores[i]); $('#scoreboard dt.p' + i).text(playerNames[i]); $('#players li.player'+i+' span.name').text(playerNames[i]); - for(var joker in (playerJokers[i] || {})) - $('#scoreboard dd.p' + i).find('.' + joker).hide(); + for(var joker in (playerJokers[i] || {})) { + $('#players .player' + i + ' .' + joker).hide(); + $('#scoreboard dd.p' + i + ' .' + joker).hide(); + } } else { $('#scoreboard dl dt.p' + i).hide(); $('#scoreboard dl dd.p' + i).hide(); From f844c42f358945a2828b97cc90a5b93fd41dd215 Mon Sep 17 00:00:00 2001 From: Frank Becker Date: Tue, 13 Dec 2011 23:13:00 +0100 Subject: [PATCH 3/4] add data as webroot to static files --- tools/questions2json.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/tools/questions2json.py b/tools/questions2json.py index b9f2acc..54b8021 100755 --- a/tools/questions2json.py +++ b/tools/questions2json.py @@ -39,6 +39,7 @@ class Question(yaml.YAMLObject): """Represents a question """ yaml_tag = u"!Question" + web_root = "data" # {round_no1: [tier1, tier2, ...], round_no2: [tier1, ...]} registered_questions = {} @@ -58,7 +59,7 @@ class Question(yaml.YAMLObject): } def __init__(self, question=u"", tier=0, answers=[], game_round=0, - media=("", "", ""), media_path=""): + media=("", "", ""), media_path="data", web_root="data"): """docstring for __init__ @question - the Question @rank - number of the question in the game @@ -74,6 +75,7 @@ class Question(yaml.YAMLObject): self.game_round = game_round self.media = media self.media_path = media_path + self.web_root = web_root def __type_by_extension(self, media_file): """returns the media type looked up by it's extension @@ -115,10 +117,11 @@ class Question(yaml.YAMLObject): for f in self.media['question']: q_data[self.__type_by_extension( os.path.sep.join(os.path.join([self.media_path, f])) - )] = f + )] = os.sep.join([self.web_root, f]) return q_data def gen_explanation(): - return {'explanation': self.media['explanation']} + return {'explanation': [os.sep.join([self.web_root, expl]) \ + for expl in self.media['explanation']]} def k_not_found(): raise KeyError("Media keyword not found") From 8e0c6a8760e79c744133ee76d0b80d636b7a1756 Mon Sep 17 00:00:00 2001 From: Frank Becker Date: Tue, 13 Dec 2011 23:13:13 +0100 Subject: [PATCH 4/4] round data updated --- 2011-28c3/round_1.json | 74 +++++++++++++++++++++--------------------- 2011-28c3/round_2.json | 40 +++++++++++------------ 2011-28c3/round_3.json | 40 +++++++++++------------ 2011-28c3/round_4.json | 40 +++++++++++------------ 4 files changed, 97 insertions(+), 97 deletions(-) diff --git a/2011-28c3/round_1.json b/2011-28c3/round_1.json index 1ababdb..4c26da0 100644 --- a/2011-28c3/round_1.json +++ b/2011-28c3/round_1.json @@ -3,9 +3,9 @@ "tier": 100, "text": "What is leathal doses of radioactivity that causes death with 100% probability within 14 days after exposition (LD100/14)? (1 Gray (Gy) == 1 Sievert (Sv))", "explanation": [ - "pix/a_fukushima.jpg" + "data/pix/a_fukushima.jpg" ], - "image": "pix/q_fukushima.jpg", + "image": "data/pix/q_fukushima.jpg", "answers": [ { "text": "> 6 mGy" @@ -26,9 +26,9 @@ "tier": 150, "text": "Why did Saxony (German State) not use the Bundestrojaner (governmental trojan horse)?", "explanation": [ - "pix/a_bundestrojaner.jpg" + "data/pix/a_bundestrojaner.jpg" ], - "image": "pix/q_bundestrojaner.jpg", + "image": "data/pix/q_bundestrojaner.jpg", "answers": [ { "text": "Technically not capable of doing so.", @@ -49,9 +49,9 @@ "tier": 225, "text": "Which of the following organizations has not yet been blocked by paypal?", "explanation": [ - "pix/a_paypal.gif" + "data/pix/a_paypal.gif" ], - "image": "pix/q_paypal4.jpg", + "image": "data/pix/q_paypal4.jpg", "answers": [ { "text": "Wikileaks" @@ -72,9 +72,9 @@ "tier": 337, "text": "How did Russian bloggers try to get attention for their demonstrations against election fraud during the recent elections in russia?", "explanation": [ - "pix/a_russian.jpg" + "data/pix/a_russian.jpg" ], - "image": "pix/q_russian.jpg", + "image": "data/pix/q_russian.jpg", "answers": [ { "text": "Multi-Million-Rubel-Ad-Campain." @@ -95,10 +95,10 @@ "tier": 506, "text": "Which of the following countries voted against a loosening of cluster munition restrictions at the UN?", "explanation": [ - "pix/a_cluster1.jpg", - "pix/a_cluster2.jpg" + "data/pix/a_cluster1.jpg", + "data/pix/a_cluster2.jpg" ], - "image": "pix/q_cluster.jpg", + "image": "data/pix/q_cluster.jpg", "answers": [ { "text": "Austria", @@ -119,9 +119,9 @@ "tier": 759, "text": "What is the definition of 1 Uhl?", "explanation": [ - "pix/a_uhl.jpg" + "data/pix/a_uhl.jpg" ], - "image": "pix/q_uhl.jpg", + "image": "data/pix/q_uhl.jpg", "answers": [ { "text": "Unit of a scale that describes the need of censorship for a certain website." @@ -142,9 +142,9 @@ "tier": 1139, "text": "Which new investigation tool did Henrik Kaspersen, one of the founding fathers of the Convention on Cybercrime, demand during its 10th birthday to improve the work against cyber crime?", "explanation": [ - "pix/a_cybercrime.jpg" + "data/pix/a_cybercrime.jpg" ], - "image": "pix/q_cybercrime.png", + "image": "data/pix/q_cybercrime.png", "answers": [ { "text": "Email bombs" @@ -165,9 +165,9 @@ "tier": 1709, "text": "How many days in a row has Belgium been run by a caretaker administration since the last government resigned in April 2010?", "explanation": [ - "pix/a_belgium.jpg" + "data/pix/a_belgium.jpg" ], - "image": "pix/q_belgium.gif", + "image": "data/pix/q_belgium.gif", "answers": [ { "text": "415 days" @@ -188,9 +188,9 @@ "tier": 2563, "text": "How many 1st notifications have been sent during the first 12 months of the French Three-Strikes-Law (Hadopi) being active?", "explanation": [ - "pix/q_hadopi.jpg" + "data/pix/q_hadopi.jpg" ], - "image": "pix/q_hadopi.png", + "image": "data/pix/q_hadopi.png", "answers": [ { "text": "~600k", @@ -211,9 +211,9 @@ "tier": 3844, "text": "What do you see on the following picture?", "explanation": [ - "pix/a_brain.jpg" + "data/pix/a_brain.jpg" ], - "image": "pix/q_brain.png", + "image": "data/pix/q_brain.png", "answers": [ { "text": "Reconstructed picture from brain activity", @@ -234,9 +234,9 @@ "tier": 5555, "text": "How many weeks did it take to bring kernel.org back up after it has been hacked in end of August 2011?", "explanation": [ - "pix/a_kernel.jpg" + "data/pix/a_kernel.jpg" ], - "image": "pix/q_kernel.gif", + "image": "data/pix/q_kernel.gif", "answers": [ { "text": "~ 1 week" @@ -257,9 +257,9 @@ "tier": 7531, "text": "What was the main purpose of the Virus that infected the US Air Force drone fleet September 2011?", "explanation": [ - "pix/a_drone.jpg" + "data/pix/a_drone.jpg" ], - "image": "pix/q_drone.jpg", + "image": "data/pix/q_drone.jpg", "answers": [ { "text": "Programming new false targets" @@ -280,9 +280,9 @@ "tier": 0, "text": "How did the US Airforce cyber security departement learn about the virus infected drones?", "explanation": [ - "pix/a_drone2.jpg" + "data/pix/a_drone2.jpg" ], - "image": "pix/q_drone2.jpg", + "image": "data/pix/q_drone2.jpg", "answers": [ { "text": "Advanced intrusion detection mechanisms" @@ -303,9 +303,9 @@ "tier": 0, "text": "Which of the following terms does not autocomplete anymore in Google search since January 2011?", "explanation": [ - "pix/a_autocomplete.jpg" + "data/pix/a_autocomplete.jpg" ], - "image": "pix/q_autocomplete.jpg", + "image": "data/pix/q_autocomplete.jpg", "answers": [ { "text": "torrent", @@ -326,9 +326,9 @@ "tier": 0, "text": "Which of the following CAs did not yet publish news about security problems this year?", "explanation": [ - "pix/q_ca4.jpg" + "data/pix/q_ca4.jpg" ], - "image": "pix/q_ca4.jpg", + "image": "data/pix/q_ca4.jpg", "answers": [ { "text": "Diginotar" @@ -349,9 +349,9 @@ "tier": 0, "text": "What is the new TLD for \"The Republic of South Sudan\"?", "explanation": [ - "pix/a_sudan.png" + "data/pix/a_sudan.png" ], - "image": "pix/q_sudan.png", + "image": "data/pix/q_sudan.png", "answers": [ { "text": ".su" @@ -372,9 +372,9 @@ "tier": 0, "text": "Which of the following companies announced via Twitter that they will tell the Police details about London rioters?", "explanation": [ - "pix/a_london.jpg" + "data/pix/a_london.jpg" ], - "image": "pix/q_london.jpg", + "image": "data/pix/q_london.jpg", "answers": [ { "text": "Cash and Carry (by publishing video footage)" @@ -395,9 +395,9 @@ "tier": 0, "text": "Which of the following cities is helping to create 100 new hackerspaces in itself?", "explanation": [ - "pix/a_hackspace.jpg" + "data/pix/a_hackspace.jpg" ], - "image": "pix/q_hackspace.jpg", + "image": "data/pix/q_hackspace.jpg", "answers": [ { "text": "Berlin" diff --git a/2011-28c3/round_2.json b/2011-28c3/round_2.json index 891c6ba..ae22a20 100644 --- a/2011-28c3/round_2.json +++ b/2011-28c3/round_2.json @@ -3,9 +3,9 @@ "tier": 100, "text": "Who was awarded the Pwnie award this year?", "explanation": [ - "pix/a_target.jpg" + "data/pix/a_target.jpg" ], - "image": "pix/q_target.png", + "image": "data/pix/q_target.png", "answers": [ { "text": "Sony", @@ -29,9 +29,9 @@ "tier": 150, "text": "How many female Porn stars have their own WP article?", "explanation": [ - "videos/question1.webm" + "data/videos/question1.webm" ], - "image": "pix/question1.png", + "image": "data/pix/question1.png", "answers": [ { "text": 448 @@ -52,9 +52,9 @@ "tier": 225, "text": "How many user-related data records (name, address, birth date) did the Saxon State retriev after it cought about > 1 mio cell phone connection records?", "explanation": [ - "videos/question1.webm" + "data/videos/question1.webm" ], - "image": "pix/question1.png", + "image": "data/pix/question1.png", "answers": [ { "text": 540 @@ -75,9 +75,9 @@ "tier": 337, "text": "What did Google do after it received a secret court order to hand over Jacob Applebaums e-mails?", "explanation": [ - "videos/question1.webm" + "data/videos/question1.webm" ], - "image": "pix/question1.png", + "image": "data/pix/question1.png", "answers": [ { "text": "hand over the data", @@ -98,9 +98,9 @@ "tier": 506, "text": "Who controls american drones in Afghanistan part time?", "explanation": [ - "videos/question1.webm" + "data/videos/question1.webm" ], - "image": "pix/question1.png", + "image": "data/pix/question1.png", "answers": [ { "text": "Iran Army" @@ -121,9 +121,9 @@ "tier": 759, "text": "To what degree Libre Office is compatible to MS Office documents?", "explanation": [ - "videos/question1.webm" + "data/videos/question1.webm" ], - "image": "pix/question1.png", + "image": "data/pix/question1.png", "answers": [ { "text": "It can run the same viruses?", @@ -145,9 +145,9 @@ "tier": 1139, "text": "How much money makes MS by patent bribing Android manufactures a year?", "explanation": [ - "videos/question1.webm" + "data/videos/question1.webm" ], - "image": "pix/question1.png", + "image": "data/pix/question1.png", "answers": [ { "text": "$1 billion" @@ -168,9 +168,9 @@ "tier": 1709, "text": "Which company delivers software that could reboot by a IPv6 ping in 2011?", "explanation": [ - "videos/question1.webm" + "data/videos/question1.webm" ], - "image": "pix/question1.png", + "image": "data/pix/question1.png", "answers": [ { "text": "Microsoft" @@ -191,9 +191,9 @@ "tier": 2563, "text": "How much money has HP spent in CEO pay-offs since 2005?", "explanation": [ - "videos/question1.webm" + "data/videos/question1.webm" ], - "image": "pix/question1.png", + "image": "data/pix/question1.png", "answers": [ { "text": "$10 mio" @@ -214,9 +214,9 @@ "tier": 3844, "text": "Which network protocol was used to demonstrate a PoC to control the engines of a Boing 747 starting from the video entertainment system?", "explanation": [ - "videos/question1.webm" + "data/videos/question1.webm" ], - "image": "pix/question1.png", + "image": "data/pix/question1.png", "answers": [ { "text": "ssh" diff --git a/2011-28c3/round_3.json b/2011-28c3/round_3.json index b5a203a..19435ac 100644 --- a/2011-28c3/round_3.json +++ b/2011-28c3/round_3.json @@ -3,9 +3,9 @@ "tier": 100, "text": "What was the reason for human loss at Pukkelpop music festival in Belgium?", "explanation": [ - "videos/question1.webm" + "data/videos/question1.webm" ], - "image": "pix/question1.png", + "image": "data/pix/question1.png", "answers": [ { "text": "stormy wind" @@ -26,9 +26,9 @@ "tier": 150, "text": "Which country does not have a net neutrality law?", "explanation": [ - "videos/question1.webm" + "data/videos/question1.webm" ], - "image": "pix/question1.png", + "image": "data/pix/question1.png", "answers": [ { "text": "Belgium" @@ -49,9 +49,9 @@ "tier": 225, "text": "What is the gain in round trip time by the new $300 mio EU-US cable (first in 10 years)?", "explanation": [ - "videos/question1.webm" + "data/videos/question1.webm" ], - "image": "pix/question1.png", + "image": "data/pix/question1.png", "answers": [ { "text": "6s" @@ -72,9 +72,9 @@ "tier": 337, "text": "Which App was pulled off the Apple app store this year after massive protests?", "explanation": [ - "videos/phonestory.webm" + "data/videos/phonestory.webm" ], - "image": "pix/van_gogh_ipad.jpg", + "image": "data/pix/van_gogh_ipad.jpg", "answers": [ { "text": "Phone Story" @@ -95,9 +95,9 @@ "tier": 506, "text": "Which App wasn't removed from the Apple app store this year?", "explanation": [ - "videos/question1.webm" + "data/videos/question1.webm" ], - "image": "pix/question1.png", + "image": "data/pix/question1.png", "answers": [ { "text": "Phone Story" @@ -118,9 +118,9 @@ "tier": 759, "text": "Why does the German SPD politician Sebastian Edathy wants the data retention law?", "explanation": [ - "videos/question1.webm" + "data/videos/question1.webm" ], - "image": "pix/question1.png", + "image": "data/pix/question1.png", "answers": [ { "text": "to catch who send him a plastic pussy", @@ -141,9 +141,9 @@ "tier": 1139, "text": "What was not patented to our knowledge?;Snowman;Snowball;Patenting;Geotracking;1;", "explanation": [ - "videos/question1.webm" + "data/videos/question1.webm" ], - "image": "pix/question1.png", + "image": "data/pix/question1.png", "answers": [ { "text": "Snowman", @@ -164,9 +164,9 @@ "tier": 1709, "text": "Which country did not get his copyright law dictated by the US?", "explanation": [ - "videos/question1.webm" + "data/videos/question1.webm" ], - "image": "pix/question1.png", + "image": "data/pix/question1.png", "answers": [ { "text": "Canada" @@ -187,9 +187,9 @@ "tier": 2563, "text": "Which country did not get his copyright law dictated by the US?", "explanation": [ - "videos/question1.webm" + "data/videos/question1.webm" ], - "image": "pix/question1.png", + "image": "data/pix/question1.png", "answers": [ { "text": "Canada" @@ -210,9 +210,9 @@ "tier": 3844, "text": "What vendor/project did not violate the GPL?", "explanation": [ - "videos/question1.webm" + "data/videos/question1.webm" ], - "image": "pix/question1.png", + "image": "data/pix/question1.png", "answers": [ { "text": "AVM" diff --git a/2011-28c3/round_4.json b/2011-28c3/round_4.json index b8a5260..743288b 100644 --- a/2011-28c3/round_4.json +++ b/2011-28c3/round_4.json @@ -3,9 +3,9 @@ "tier": 100, "text": "What company does this org chart show?", "explanation": [ - "pix/organigram.png" + "data/pix/organigram.png" ], - "image": "pix/orgchart-ms.png", + "image": "data/pix/orgchart-ms.png", "answers": [ { "text": "Google" @@ -26,9 +26,9 @@ "tier": 150, "text": "What programming language Fefe isn't able to read?", "explanation": [ - "videos/question1.webm" + "data/videos/question1.webm" ], - "image": "pix/question1.png", + "image": "data/pix/question1.png", "answers": [ { "text": "C" @@ -49,9 +49,9 @@ "tier": 225, "text": "Which city is going to support founding of 100 hackerspaces?", "explanation": [ - "pix/shanghai.jpg" + "data/pix/shanghai.jpg" ], - "image": "pix/question1.png", + "image": "data/pix/question1.png", "answers": [ { "text": "Paris" @@ -72,9 +72,9 @@ "tier": 337, "text": "Who did not die this year?", "explanation": [ - "pix/anonymous-sun.jpg" + "data/pix/anonymous-sun.jpg" ], - "image": "pix/question1.png", + "image": "data/pix/question1.png", "answers": [ { "text": "Steve Jobs" @@ -95,9 +95,9 @@ "tier": 506, "text": "Which programming language can calculate?", "explanation": [ - "pix/shanghai.jpg" + "data/pix/shanghai.jpg" ], - "image": "pix/question1.png", + "image": "data/pix/question1.png", "answers": [ { "text": "PHP" @@ -118,9 +118,9 @@ "tier": 759, "text": "How many babies were given away in Spain between and the 90-es?", "explanation": [ - "pix/shanghai.jpg" + "data/pix/shanghai.jpg" ], - "image": "pix/question1.png", + "image": "data/pix/question1.png", "answers": [ { "text": "PHP" @@ -141,9 +141,9 @@ "tier": 1139, "text": "How many Mrs USA finalists think evolution should be taught in school?", "explanation": [ - "pix/shanghai.jpg" + "data/pix/shanghai.jpg" ], - "image": "pix/question1.png", + "image": "data/pix/question1.png", "answers": [ { "text": "PHP" @@ -164,9 +164,9 @@ "tier": 1709, "text": "What could not be used to exploit Win systems in 2011?", "explanation": [ - "videos/question1.webm" + "data/videos/question1.webm" ], - "image": "pix/question1.png", + "image": "data/pix/question1.png", "answers": [ { "text": "TXT file" @@ -187,9 +187,9 @@ "tier": 2563, "text": "What animal did the US army use in Western Berlin for intruder alarm?", "explanation": [ - "videos/question1.webm" + "data/videos/question1.webm" ], - "image": "pix/question1.png", + "image": "data/pix/question1.png", "answers": [ { "text": "goose", @@ -210,9 +210,9 @@ "tier": 3844, "text": "What was the most common password?", "explanation": [ - "videos/question1.webm" + "data/videos/question1.webm" ], - "image": "pix/question1.png", + "image": "data/pix/question1.png", "answers": [ { "text": "goose",