Commit 300107d1 authored by Antek Grzanka's avatar Antek Grzanka

Mergeeee

parents 36bc42a7 cd7ba07b
File added
File added
File added
#include <stdio.h>
int main(){
int haslo;
char flaga[] = "KYN2016_JesteInzyniere";
printf("Podaj hasło\r\n");
scanf("%i", &haslo);
if(haslo == 887449753){
printf("Flaga to %s \r\n", flaga);
}
else{
printf("Haslo nieprawidlowe\r\n");
}
return 0;
}
#include <stdio.h>
int main(){
int haslo;
//MiEstasIngeniero
int signs[24] = {
0x4b, //K
0x59, //Y
0x4e, //N
0x32, //2_
0x30, //0
0x31, //1
0x36, //6
0x5f, //_
0x4d, //M
0x69, //i
0x45, //E
0x73, //s
0x74, //t
0x61, //a
0x73, //s
0x49, //I
0x6e, //n
0x67, //g
0x65, //e
0x6e, //n
0x69, //i
0x65, //e
0x72, //r
0x6f, //o
};
printf("Podaj hasło\r\n");
scanf("%i", &haslo);
if(haslo - 73 == 12974832135345){
int i;
printf("Flaga to: ");
for(i=0; i<24; i++){
printf("%c", signs[i]);
}
printf("\r\n");
}
else{
printf("Haslo nieprawidlowe\r\n");
}
return 0;
}
#include <stdio.h>
int main(){
int haslo;
//MiEstasIngeniero
int signs[23] = {
0x1b, //K
0x29, //Y
0x1e, //N
0x02, //2
0x00, //0
0x01, //1
0x06, //6
0x2f, //_
0x13, //C
0x3f, //o
0x36, //f
0x31, //a
0x3e, //n
0x39, //i
0x35, //e
0x27, //W
0x43, //s
0x44, //t
0x35, //e
0x33, //c
0x4a, //z
0x3e, //n
0x35, //e
};
printf("Podaj hasło\r\n");
scanf("%i", &haslo);
if(haslo + 5 > 16857168782345 && haslo +6 < 16857168782345){
int i;
printf("Flaga to: ");
for(i=0; i<23; i++){
printf("%c", 0x30 + signs[i]);
}
printf("\r\n");
}
else{
printf("Haslo nieprawidlowe\r\n");
}
return 0;
}
......@@ -10,8 +10,8 @@ dbName: db
startupConfiguration:
domainName: "ctf.krakyournet.pl"
port: 80
schema: "http"
port: 443
schema: "https"
digestMethod: "MD5"
......@@ -127,7 +127,7 @@ textTasks:
webTasks:
- name: "PHP taki bezpieczny"
description: "Strona w budowie. Jest już w sieci, ale nikt nie miał czasu jej dobrze skonfigurować i zabezpieczyć. Czy czujesz się na siłach żeby znaleźć błędy?"
url: "http://52.29.190.67"
url: "http://52.29.190.67/"
level: 3
flags:
- value: "KYN2016_WartoSieGlowic"
......@@ -183,4 +183,4 @@ webTasks:
points: 2
- value: "KYN2016_LaoreetAliquet"
description: "SQLInjection"
points: 3
\ No newline at end of file
points: 3
package com.telephoners.krakyournet.ctf.beans;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
public class Flag {
private String value;
......@@ -16,12 +16,12 @@ public class Flag {
this.points = points;
}
// @JsonIgnore //TODO!!
@JsonProperty(access = JsonProperty.Access.WRITE_ONLY)
public String getValue() {
return value;
}
// @JsonIgnore //TODO!!
@JsonProperty(access = JsonProperty.Access.WRITE_ONLY)
public void setValue(String value) {
this.value = value;
}
......
......@@ -52,9 +52,11 @@ public class SolutionsRepository extends Repository<Solution>
private boolean isAlreadySubmittedSolution(Solution solution)
{
return !datastore.find(Solution.class)
.filter("flag.value", solution.getFlag().getValue())
.asList()
List<Solution> solutions = datastore.find(Solution.class)
.filter("flag.value", solution.getFlag().getValue()) //todo: do not filter by field
.filter("team.name", solution.getTeam().getName()) //todo: whole object instead
.asList();
return !solutions
.isEmpty();
}
......
......@@ -40,7 +40,11 @@
app.factory('AppSettings', ['$http', function($http) {
// fallback into defaults, if everything fails, world collapses, hell freezes and /startup will not resolve
<<<<<<< HEAD
var domainName = '52.25.28.64', port = 8080, schema = "http";
=======
var domainName = 'ctf.krakyournet.pl', port = "https", schema = 443;
>>>>>>> origin/master
return {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment