Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
CTF Search
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
CTF Search Team
CTF Search
Commits
0a54b6f5
Commit
0a54b6f5
authored
5 years ago
by
Timmy Chan
Browse files
Options
Downloads
Patches
Plain Diff
Fix debian image setup x86_64
parent
6902cee8
No related branches found
No related tags found
1 merge request
!5
Feat/cve linux kernel
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
exploitdb/ctfsetup/qemu/debian_image_setup.sh
+2
-2
2 additions, 2 deletions
exploitdb/ctfsetup/qemu/debian_image_setup.sh
exploitdb/ctfsetup/qemu/setup.py
+4
-3
4 additions, 3 deletions
exploitdb/ctfsetup/qemu/setup.py
with
6 additions
and
5 deletions
exploitdb/ctfsetup/qemu/debian_image_setup.sh
+
2
−
2
View file @
0a54b6f5
...
...
@@ -13,7 +13,7 @@ VERBOSE=1
DL_DIR
=
$1
#DL_DIR=~/ctf/qemu/debian_disks
ARCH
=
i386
ARCH
=
${
2
:-
i386
}
DISK_NAME
=
disk.img
...
...
@@ -103,6 +103,6 @@ EOF
cd
"
${
WORKING_DIR
}
"
||
exit
}
download_debian
$ARCH
download_debian
"
$ARCH
"
exit
This diff is collapsed.
Click to expand it.
exploitdb/ctfsetup/qemu/setup.py
+
4
−
3
View file @
0a54b6f5
...
...
@@ -46,7 +46,7 @@ def main(*args):
vm_directory
=
create_vm_directory
()
verbose_log
(
"
Setup VM image
"
)
setup_vm_disk_image
(
vm_directory
,
DEFAULT_ARCH
,
DEFAULT_OS
)
setup_vm_disk_image
(
vm_directory
,
**
kwargs
)
verbose_log
(
"
Configuring kernel
"
)
configure_kernel
(
**
kwargs
)
...
...
@@ -111,9 +111,10 @@ def create_vm_directory():
return
path
def
setup_vm_disk_image
(
parent_dir
,
arch
=
DEFAULT_ARCH
,
_os
=
DEFAULT_OS
):
def
setup_vm_disk_image
(
vm_directory
,
**
kwargs
):
args
=
f
"
{
str
(
vm_directory
)
}
{
kwargs
[
'
arch
'
]
}
"
try
:
simple_call_shell_command
(
"
bash debian_image_setup.sh
"
+
str
(
parent_dir
)
)
simple_call_shell_command
(
"
bash debian_image_setup.sh
"
+
args
)
except
subprocess
.
CalledProcessError
as
e
:
raise
Exception
(
"
Error in download_vm_disk_image()
"
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment