Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
142 commits
Select commit Hold shift + click to select a range
d6876e2
Fix warnings and setup configs
sukhman-sukh Jan 9, 2025
54170c2
Adds feature: Limit the max amount of tries on challenge
Aryan51203 Jan 11, 2025
fa5817b
Code formatting
Aryan51203 Jan 11, 2025
8ddc848
Fix: Bug in challenge solve status
Aryan51203 Jan 11, 2025
5f647ea
Adds feature: Chain challenges to create pre requisite challenges
Aryan51203 Jan 11, 2025
477093c
feat: adds paid hints
SomyaChawla0250 Jan 11, 2025
7881c23
Changes to copy from move in setup script
Aryan51203 Jan 14, 2025
d26aed0
Add deploy feature for multi instance and reset-database command
sukhman-sukh Jan 14, 2025
749cc37
PR fixes
Aryan51203 Jan 15, 2025
f0bfafd
Add container and image management feature for remote
sukhman-sukh Jan 15, 2025
09c1fa9
Add remote container/image filter and removal
sukhman-sukh Jan 29, 2025
66e5e2c
Serve static files
sukhman-sukh Jan 31, 2025
8102509
Add health checker for local and remote challs
sukhman-sukh Feb 3, 2025
b9c9367
Fix remote containers filter function
sukhman-sukh Feb 3, 2025
72a952d
Fix static file serving
sukhman-sukh Feb 3, 2025
3244a4b
Fix edgecases
sukhman-sukh Feb 3, 2025
7821d53
Fix chal.ServerDeployed and AdditionalLinks
sukhman-sukh Feb 3, 2025
ec12b6a
Update pkg/notify/main.go
sukhman-sukh Feb 3, 2025
7409bbc
Change strings to global var
sukhman-sukh Feb 3, 2025
66a8154
Merge branch 'master' into multiple_servers
sukhman-sukh Feb 3, 2025
fea3b19
Merge branch 'multiple_servers' into serve_static_files
sukhman-sukh Feb 3, 2025
ea4ad13
Change paid hints logic, updated handler to display hints
ayu-ch Feb 3, 2025
3ecaeaa
Fix free redeem on post
ayu-ch Feb 4, 2025
363ceaf
SMTP integration
Aryan51203 Feb 4, 2025
c546f91
Adds SMTP toml creation and email-template path
Aryan51203 Feb 4, 2025
2ec0e45
Add deployed links
sukhman-sukh Feb 4, 2025
9fbcf72
Adds path creation for email template
Aryan51203 Feb 4, 2025
02d3c30
Fix error which returns every attempt as solved
ayu-ch Feb 4, 2025
5cf4fc1
SMTP changes for IITR
Aryan51203 Feb 4, 2025
bc6184e
Route change for sending OTP
Aryan51203 Feb 4, 2025
eef8477
Fix bug in err handling in otp
Aryan51203 Feb 4, 2025
fcf2a4a
feat: implement logging for cheating attempts in cheat.log
v1bh475u Feb 4, 2025
05816c2
Fixes invalid certificate bug in SMTP
Aryan51203 Feb 4, 2025
2f331ce
Change from json to postform
Aryan51203 Feb 4, 2025
7446900
Merge branch 'Additional-Features' into somya/dev
sukhman-sukh Feb 4, 2025
f1f365b
Merge pull request #376 from sdslabs/serve_static_files
sukhman-sukh Feb 4, 2025
7e9b054
Merge pull request #374 from sdslabs/somya/dev
sukhman-sukh Feb 4, 2025
ab3014f
Merge branch 'master' into Additional-Features
sukhman-sukh Feb 4, 2025
9cb755e
Fix remote container's filter
sukhman-sukh Feb 4, 2025
de1ca59
Merge pull request #387 from sdslabs/dynamic-flags
sukhman-sukh Feb 5, 2025
5e8ace9
Merge branch 'multiple_servers' into Additional-Features
sukhman-sukh Feb 5, 2025
02264e8
Add cron job for regular backups
sukhman-sukh Feb 5, 2025
8df1ff9
Adds option to disable SMTP
Aryan51203 Feb 5, 2025
1cee8b6
PR review fixes for fail solve limit pointer
Aryan51203 Feb 5, 2025
8c070fc
Deletes vendor folder from git
Aryan51203 Feb 5, 2025
4dcd3cc
Formatting changes
Aryan51203 Feb 5, 2025
5049769
Merge pull request #388 from sdslabs/backup_cron_job
sukhman-sukh Feb 5, 2025
4dd2f6d
Adds warning message for max attempt limit set to 0
Aryan51203 Feb 5, 2025
b26b5bb
Removes empty line in utils.go
Aryan51203 Feb 5, 2025
58eeb8f
Adds dummy route
Aryan51203 Feb 5, 2025
10182cc
Fix edgecases
sukhman-sukh Feb 10, 2025
0afd728
Fix PreviousAttempt error
ayu-ch Feb 10, 2025
2073b62
Merge pull request #391 from sdslabs/multiple_servers
ayu-ch Feb 10, 2025
abe6a70
DB_migration
sukhman-sukh Feb 10, 2025
48a3d70
minor fix
v1bh475u Feb 11, 2025
3eca70f
feat: add leaderboard endpoint and improve error handling in API
v1bh475u Feb 11, 2025
a725f66
feat: add LEADERBOARD_SIZE
v1bh475u Feb 11, 2025
5332ef1
feat: add user score query functions
v1bh475u Feb 11, 2025
22f6608
feat: add user score query functions
v1bh475u Feb 11, 2025
5e240d8
chore: update dependencies to use PostgreSQL driver and latest GORM v…
v1bh475u Feb 11, 2025
22ef4e9
Add backup and reset db
sukhman-sukh Feb 12, 2025
9398c1f
Fix backup and reset db
sukhman-sukh Feb 12, 2025
e53e126
Fix database edgecases
sukhman-sukh Feb 12, 2025
ad89733
Merge branch 'bl4ze/dev' into SMTP-Integration
sukhman-sukh Feb 12, 2025
98743b3
Merge pull request #386 from sdslabs/SMTP-Integration
sukhman-sukh Feb 12, 2025
cd16ee2
adds forget password feature
SomyaChawla0250 Feb 12, 2025
2385b10
fix: remove psql & revert to sqlite
v1bh475u Feb 12, 2025
6be1361
fix: update statement
v1bh475u Feb 12, 2025
220deca
Merge branch 'bl4ze/dev' into leaderboard-sqlite
sukhman-sukh Feb 12, 2025
94ab063
Add challenge flag submission log file
sukhman-sukh Feb 12, 2025
ebb829d
Adds trimming and lowercase to certain fields
Aryan51203 Feb 12, 2025
b5ddd79
feat: add leaderboard freeze and unfreeze functionality
v1bh475u Feb 13, 2025
14db8b1
subracts score and solves data for purged challenge
SomyaChawla0250 Feb 13, 2025
5681059
Fixes token auth in forget password route
Arshdeep54 Feb 13, 2025
226687c
Merge pull request #395 from sdslabs/purge-fix
v1bh475u Feb 13, 2025
c8a2b47
Add service_docker type chall
sukhman-sukh Feb 13, 2025
e52324d
Merge pull request #394 from sdslabs/leaderboard-sqlite
sukhman-sukh Feb 13, 2025
e73c8dd
Merge pull request #396 from sdslabs/forget_password
v1bh475u Feb 13, 2025
eafe804
Merge branch 'bl4ze/dev' into service_docekr
v1bh475u Feb 13, 2025
c8f2eab
Merge pull request #397 from sdslabs/service_docekr
v1bh475u Feb 13, 2025
c6e24c1
Adds route for send otp for forgot password
Aryan51203 Feb 13, 2025
c40f436
Fixes error handling in smtp routes
Aryan51203 Feb 13, 2025
0f75330
Merge pull request #401 from sdslabs/forget_password
Aryan51203 Feb 13, 2025
a70cb14
Add endpoint to retrieve user count with role=contestant
v1bh475u Feb 13, 2025
5e012e5
minor bug fix
v1bh475u Feb 13, 2025
5e11a87
Fix static serve
sukhman-sukh Feb 13, 2025
8c42090
minor fix
sukhman-sukh Feb 13, 2025
f3cc089
minor fix
sukhman-sukh Feb 13, 2025
3494034
skip email verif on debug mode
sukhman-sukh Feb 28, 2025
c85e783
Skip email verification on debug mode
DarkPhoenix42 Feb 28, 2025
f701a12
Merge branch 'bl4ze/dev' into db_migration
DarkPhoenix42 Feb 28, 2025
3566072
Revert "Merge pull request #394 from sdslabs/leaderboard-sqlite"
sukhman-sukh Feb 28, 2025
5617c53
Remove leaderboard freeze api route
sukhman-sukh Feb 28, 2025
740719a
Revert "Add service_docker type chall"
sukhman-sukh Feb 28, 2025
4897cf2
Revert service_docker PR
sukhman-sukh Feb 28, 2025
205d9fc
fix: update errors as per convention
v1bh475u Mar 1, 2025
4090bdc
feat: add field for service config file name
v1bh475u Mar 1, 2025
c576137
mod: remove DOCKER CHALLENGE TYPE
v1bh475u Mar 1, 2025
e5976fa
feat: make servicefile and dockerfile optional fields
v1bh475u Mar 1, 2025
70732dc
mod: update mod and sum files
v1bh475u Mar 1, 2025
345f9af
refactor
v1bh475u Mar 1, 2025
a44ff20
mod: rename service_config to xinetd_conf
v1bh475u Mar 1, 2025
514a6ba
refactor
v1bh475u Mar 1, 2025
97df88a
feat: add XinetdConf field to BeastBareDockerfile and update entrypoi…
v1bh475u Mar 1, 2025
458f106
fix(stageChallenge): correct condition for Dockerfile deletion
v1bh475u Mar 1, 2025
7be6af4
update(static-chall): add static_dir to challenge_env
v1bh475u Mar 1, 2025
805db68
add(xinetd-service): sample chal with user xinetd.conf
v1bh475u Mar 1, 2025
afb19df
add(service): sample chal without author provided xinetd.conf
v1bh475u Mar 1, 2025
51fb2a5
update(dependencies): upgrade gorm and sqlite driver versions
v1bh475u Mar 1, 2025
c1a5c73
Add flag to db
sukhman-sukh Mar 14, 2025
978daa4
fix(challenge-config): loosen up constraints on config file
v1bh475u Apr 15, 2025
027cdd1
update: examples
v1bh475u Apr 15, 2025
e82d4c3
update(README): add descriptions of new challenges
v1bh475u Apr 15, 2025
a22fac1
mod: update dependencies and fix bugs
v1bh475u Apr 15, 2025
cc1f428
refactor: rename example challenge name for better understanding
v1bh475u Apr 16, 2025
7e15644
fix: correct link for bare docker challenge in README
v1bh475u Apr 16, 2025
22f1cc5
fix: correct typo in error log message for remote container search
v1bh475u Apr 16, 2025
cc4bf9b
fix: append challenge names to list in HandleAll function
v1bh475u Apr 17, 2025
f20f0f2
feat: migrate to postgres and refactor database models and queries fo…
DarkPhoenix42 Apr 17, 2025
6469113
Add leaderboard freeze feature
sukhman-sukh Mar 14, 2025
03e10a3
Fix adminleaderboard cache
sukhman-sukh Mar 14, 2025
c96531c
Add hide/unhide
sukhman-sukh Mar 17, 2025
f7543e8
Fixed leaderboard
sukhman-sukh Apr 18, 2025
a3af524
Merge pull request #411 from sdslabs/leaderboard-sqlite
sukhman-sukh Jun 5, 2025
508e4ed
Merge branch 'bl4ze/dev' into chall-type-separation
sukhman-sukh Jun 5, 2025
925bd33
Merge pull request #409 from sdslabs/chall-type-separation
sukhman-sukh Jun 5, 2025
4509816
Update core/database/database.go
sukhman-sukh Aug 13, 2025
edd4ed9
Merge branch 'bl4ze/dev' into add_flag_to_db
sukhman-sukh Aug 13, 2025
1fabc67
Merge pull request #410 from sdslabs/add_flag_to_db
sukhman-sukh Aug 13, 2025
c223106
Add graceful shutdown to db
sukhman-sukh Aug 13, 2025
5ba2c8f
Fix database init errors
sukhman-sukh Aug 13, 2025
abc8670
Merge branch 'bl4ze/dev' into db_migration
sukhman-sukh Aug 13, 2025
7695654
Add backup and reset db
sukhman-sukh Feb 12, 2025
4a8d8af
feat: migrate to postgres and refactor database models and queries fo…
DarkPhoenix42 Apr 17, 2025
7b3d0c2
Fix database init errors
sukhman-sukh Aug 13, 2025
0b132d9
Fix flags
sukhman-sukh Aug 13, 2025
eaebedd
Merge pull request #413 from sdslabs/db_migration
sukhman-sukh Aug 13, 2025
5166f5c
Make JSON Responses compatible
sukhman-sukh Aug 14, 2025
03d5104
Add graph support to beast backend
sukhman-sukh Aug 15, 2025
6873293
Resolve copilot suggestions
sukhman-sukh Aug 16, 2025
5b6da93
Merge pull request #420 from sdslabs/frontend_compatibilty_fixes
sukhman-sukh Aug 16, 2025
48dc9ff
Add cache invalidation to graph
sukhman-sukh Aug 16, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,4 @@ site/
ubuntu-bionic-18.04-cloudimg-console.log
target/
.vscode/
vendor/
4 changes: 3 additions & 1 deletion _examples/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,9 @@
* [PHP Web challenge](./web-php)
* [PHP Web challenge with MySQL](./web-php-mysql)
* [Challenge with Static files only](./static-chall)
* [Xinted Service challenge](./xinetd-service)
* [Xinted Service challenge with custom xinetd config](./xinetd-service)
* [Service challenge with auto-generated xinetd config](./service)
* [A bare challenge using docker](./bare-docker)

To test any of the above challenges, cd to \_example directory and use the below command:

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,16 @@ ssh_key = "ssh-rsa AAAAB3NzaC1y"
[challenge.metadata]
name = "docker-type"
flag = "FLAG{r3GEx_i5_3vi1!!}"
type = "docker"
hints = ["simple_hint_1", "simple_hint_2"]
type = "bare"
points = 200

[[challenge.metadata.hints]]
text = "simple_hint_1"
points = 10

[[challenge.metadata.hints]]
text = "simple_hint_2"
points = 20

[challenge.env]
docker_context = "docker-file"
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
90 changes: 71 additions & 19 deletions _examples/example.config.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,60 @@ scripts_dir = "$HOME/.beast/scripts"
# Base OS image that beast allows the challenges to use.
allowed_base_images = ["ubuntu:18.04", "ubuntu:16.04", "debian:jessie"]

# The sidecar that we support with beast, currently we only support two MySQL and
# MongoDB.
available_sidecars = ["mysql", "mongodb"]

# For authentication purposes beast uses JWT based authentication, this is the
# key used for encrypting the claims of a user. Keep this strong.
jwt_secret = "beast_jwt_secret_SUPER_STRONG_0x100010000100"

#Health Prober, if active, starts a health prober on a thread which checks for
#deployed challenges, containers and servers after every ticker_frequency period
health_prober = false

# The frequency for any periodic event in beast, the value is provided in seconds.
# This is currently only used for health check periodic durations.
ticker_frequency = 3000


# Container default resource limits for each challenge, this can be
# Overridden by challenge configuration beast.toml file.
default_cpu_shares = 1024
default_memory_limit = 1024
default_pids_limit = 100

# List of ip addresses of all the servers where challenge could be deployed for
# balanced load accross servers.
[available_servers]
# [available_servers."host"]
[available_servers."192.168.1.1"]
# IP-address/Hostname of the server
host = "192.168.1.1"

# Username to be used for ssh connection
username = "user1"

# Path to private SSH key for interacting with the server.
ssh_key_path = "/path/to/your/private/key1"

# Status of remote server to be used
# If it is set to false then that remote server will not be used
active = false

[available_servers.localhost]
# IP-address/Hostname of the server
host = "localhost"

# Username to be used for ssh connection (Leave empty for localhost)
username = "user1"

# Path to private SSH key for interacting with the server. (Leave empty for localhost)
ssh_key_path = "/path/to/your/private/key1"

# Status of remote server to be used
active = true


# To allow beast to send notification to a notification channel povide this webhook URL
# We are also working on implmeneting notification using IRC.
Expand All @@ -31,30 +80,14 @@ service_name = "discord"
# If it is false then notification will not be sent on this URL
active = false

# The sidecar that we support with beast, currently we only support two MySQL and
# MongoDB.
available_sidecars = ["mysql", "mongodb"]


# The frequency for any periodic event in beast, the value is provided in seconds.
# This is currently only used for health check periodic duration.s
ticker_frequency = 3000


# Container default resource limits for each challenge, this can be
# Overridden by challenge configuration beast.toml file.
default_cpu_shares = 1024
default_memory_limit = 1024
default_pids_limit = 100


# Configuration corresponding to the remote repository used by beast
# We use ssh authentication mechanism for interacting with git repository.
[[remote]]

# URL of the remote git repository, this should be user@host:<git_repository> format
url = "[email protected]:sdslabs/hack-test.git"



# Name of the remote
name = "hack-test"

Expand All @@ -68,10 +101,26 @@ ssh_key = "$HOME/.beast/secrets/key.priv"
# If it is set to false then that remote git repository will not be used
active = false

[mail_config]
from = "[email protected]"
password = "your-email-password"
smtpHost = "smtp.example.com"
smtpPort = "587"

# Configuration to connect to Postgresql database
[psql_config]

user = "beast"
password = "12345678"
dbname = "beast"
host = "localhost"
port = "5432"
sslmode = "prefer"

# The following fields are required only while hosting a competition on beast
# This section contains information about the competition to be hosted
# Structure of the sections with the acceptable fields are:
[[competition_info]]
[competition_info]
# Required Fields

# Name of the competition
Expand All @@ -96,3 +145,6 @@ prizes = ""

# Absolute path of logo file. Default logo dir is in the "BEAST_GLOBAL_DIR/assets/"
logo_url = ""

# Dynamic scoring for challenges
dynamic_score = false
26 changes: 26 additions & 0 deletions _examples/service/beast.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
[author]
name = "fristonio"
email = "[email protected]"
ssh_key = "ssh-rsa AAAAB3NzaC1y"

[challenge.metadata]
name = "service"
flag = "CTF{sample_flag}"
type = "service"
points = 100
maxAttemptLimit = 10

[[challenge.metadata.hints]]
text = "simple_hint_1"
points = 10

[[challenge.metadata.hints]]
text = "simple_hint_2"
points = 20


[challenge.env]
apt_deps = ["gcc", "socat"]
setup_scripts = ["setup.sh"]
service_path = "pwn"
ports = [10004]
29 changes: 29 additions & 0 deletions _examples/service/pwn_me.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
#include <stdio.h>
#include <unistd.h>

int sample()
{ FILE *ptr_file;
char buf[100];

ptr_file = fopen("flag.txt","r");
if (!ptr_file)
return 1;

while (fgets(buf,100, ptr_file)!=NULL)
fprintf(stderr, "%s",buf);
fclose(ptr_file);
return 0;
}

void test()
{ char input[50];
printf("Please enter your name: ");
gets(input);
sleep(1);
fprintf(stderr, "ECHO: %s\n",input);
}

int main()
{ test();
return 0;
}
3 changes: 3 additions & 0 deletions _examples/service/setup.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
set -e

gcc -o pwn pwn_me.c
20 changes: 14 additions & 6 deletions _examples/simple/beast.toml
Original file line number Diff line number Diff line change
@@ -1,16 +1,24 @@
[author]
name = "fristonio"
email = "[email protected]"
ssh_key = "ssh-rsa AAAAB3NzaC1y"
name = "hi"
email = "[email protected]"
ssh_key = "hi"

[challenge.metadata]
name = "simple"
flag = "BACKDOOR{SAMPLE_FLAG}"
type = "bare"
hints = ["simple_hint_1", "simple_hint_2"]
points = 100

[[challenge.metadata.hints]]
text = "simple_hint_1"
points = 10

[[challenge.metadata.hints]]
text = "simple_hint_2"
points = 20

[challenge.env]
apt_deps = ["gcc", "socat"]
setup_scripts = ["setup.sh"]
run_cmd = "socat tcp-l:10001,fork,reuseaddr exec:./pwn"
ports = [10001]
run_cmd = "socat tcp-l:10005,fork,reuseaddr exec:./pwn"
ports = [10005]
18 changes: 16 additions & 2 deletions _examples/static-chall/beast.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,19 @@ ssh_key = "ssh-rsa AAAAB3NzaC1y"
name = "static-chall"
flag = "BACKDOOR{SAMPLE_FLAG}"
type = "static"
hints = ["static_hint_1", "static_hint_2"]
tags = ["easy"]
points=150

[[challenge.metadata.hints]]
text = "simple_hint_1"
points = 10

[[challenge.metadata.hints]]
text = "simple_hint_2"
points = 20

maxPoints = 100
minPoints = 50
tags = ["easy", "web"]

[challenge.env]
static_dir = "static"
13 changes: 11 additions & 2 deletions _examples/web-php-mysql/beast.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,17 @@ ssh_key = "ssh-rsa AAAAB3NzaC1y"
name = "web-php-mysql"
flag = "CTF{sample_flag}"
type = "web:php:7.1:cli"
sidecar = "mysql"
hints = ["web-php-mysql_hint_1", "web-php-mysql_hint_2"]
points = 200
maxAttemptLimit = 10

[[challenge.metadata.hints]]
text = "simple_hint_1"
points = 10

[[challenge.metadata.hints]]
text = "simple_hint_2"
points = 20


[challenge.env]
apt_deps = ["gcc", "php*-mysql"]
Expand Down
12 changes: 11 additions & 1 deletion _examples/web-php/beast.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,17 @@ ssh_key = "ssh-rsa AAAAB3NzaC1y"
name = "web-php"
flag = "BACKDOOR{SAMPLE_WEB_FLAG}"
type = "web:php:7.1:cli"
hints = ["web_hint_1", "web_hint_2"]
maxAttemptLimit = 3
points = 200

[[challenge.metadata.hints]]
text = "simple_hint_1"
points = 10

[[challenge.metadata.hints]]
text = "simple_hint_2"
points = 20


[challenge.env]
ports = [10002]
Expand Down
21 changes: 17 additions & 4 deletions _examples/xinetd-service/beast.toml
Original file line number Diff line number Diff line change
@@ -1,16 +1,29 @@
[author]
name = "fristonio"
email = "contact+fristonio@sdslabs.co.in"
name = "contact"
email = "[email protected]"
ssh_key = "ssh-rsa AAAAB3NzaC1y"

[challenge.metadata]
name = "xinetd-service"
flag = "CTF{sample_flag}"
flag = "CTF{not_the_flag}"
type = "service"
hints = ["xinetd_hint_1", "xinetd_hint_2"]
points = 500
maxAttemptLimit = 10

[[challenge.metadata.hints]]
text = "simple_hint_1"
points = 10

[[challenge.metadata.hints]]
text = "simple_hint_2"
points = 20

preReqs = ["simple", "web-php"]


[challenge.env]
apt_deps = ["gcc", "socat"]
setup_scripts = ["setup.sh"]
xinetd_config = "ctf.xinetd"
service_path = "pwn"
ports = [10003]
18 changes: 18 additions & 0 deletions _examples/xinetd-service/ctf.xinetd
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
service xinetd-service
{
disable = no
socket_type = stream
protocol = tcp
wait = no
user = beast
type = UNLISTED
port = 10003
bind = 0.0.0.0
server = /bin/sh
server_args = -c cd${IFS}/challenge;exec${IFS}/challenge/pwn
banner_fail = /etc/banner_fail
# Options below are for safety mainly
#per_source = 10 # max instances per source at once
rlimit_cpu = 5 # max cpu seconds
#rlimit_as = 1024M # addr space resource limit
}
1 change: 1 addition & 0 deletions _examples/xinetd-service/flag.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
CTF{not_the_flag}
2 changes: 2 additions & 0 deletions _examples/xinetd-service/pwn_me.c
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ int sample()

void test()
{ char input[50];
printf("Please enter your name: ");
fflush(stdout);
gets(input);
sleep(1);
fprintf(stderr, "ECHO: %s\n",input);
Expand Down
Loading