These routes relate to retrieving all the completed checks (regardless of type) for either all teams or a specific team. These checks will have slightly different information, which are defined in each of their own pages. For each type, see Service, Attacker, Inject, and Manual checks.
Gets all checks for all teams.
Example request:
GET /teams/checks HTTP/1.1
Host: example.com
Accept: application/json, text/javascript
Cookie: userid=admin
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
[
{
'id': 'MongoDBUp',
'description': 'Checks whether MongoDB is up.',
'type': 'service',
'timestamp': datetime.now() - timedelta(hours=5),
'team_id': '1',
'score': 0
},
{
'id': 'RemovedFiles',
'description': 'Checks whether each team removed certain files.',
'type': 'inject',
'inject_number': 5,
'time_to_check': datetime.now() - timedelta(hours=5, minutes=5),
'timestamp': datetime.now() - timedelta(hours=5),
'team_id': '2',
'score': 0
},
{
'id': 'MySecurityHole',
'description': 'Checks whether my security hole is still there.',
'machine': 'Redis',
'type': 'attacker',
'timestamp': datetime.now() - timedelta(hours=1, minutes=52),
'team_id': '3',
'score': -5
},
{
'id': 'BoardPresentation',
'description': 'The teams present to a board on what they did.',
'comments': 'This team did great! They definitely deserve full points!',
'type': 'manual',
'inject_number': '107',
'timestamp': datetime.now() - timedelta(hours=4),
'team_id': '6',
'score': 10
}
]
Requires Authentication: Yes
Allowed Roles: Administrator
Gets all checks for a specific team.
Example request:
GET /teams/1/checks/ HTTP/1.1
Host: example.com
Accept: application/json, text/javascript
Cookie: userid=admin
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
[
{
'id': 'MongoDBUp',
'description': 'Checks whether MongoDB is up.',
'type': 'service',
'timestamp': datetime.now() - timedelta(hours=5),
'team_id': '1',
'score': 0
},
{
'id': 'RemovedFiles',
'description': 'Checks whether each team removed certain files.',
'type': 'inject',
'inject_number': 5,
'time_to_check': datetime.now() - timedelta(hours=5, minutes=5),
'timestamp': datetime.now() - timedelta(hours=5),
'team_id': '2',
'score': 0
},
{
'id': 'MySecurityHole',
'description': 'Checks whether my security hole is still there.',
'machine': 'Redis',
'type': 'attacker',
'timestamp': datetime.now() - timedelta(hours=1, minutes=52),
'team_id': '3',
'score': -5
},
{
'id': 'BoardPresentation',
'description': 'The teams present to a board on what they did.',
'comments': 'This team did great! They definitely deserve full points!',
'type': 'manual',
'inject_number': '107',
'timestamp': datetime.now() - timedelta(hours=4),
'team_id': '6',
'score': 10
}
]
Requires Authentication: Yes
Allowed Roles: Administrator