mirror of
https://github.com/kforney/pentest-distro-builder.git
synced 2024-11-22 01:50:56 -07:00
Move hook to config folder.
Former-commit-id: 891a966bdc
Former-commit-id: b1f759ff281a060a67d5b130590254996bd0e677
This commit is contained in:
parent
b4023c977a
commit
927a6a85cd
6 changed files with 18 additions and 29 deletions
|
@ -5,13 +5,14 @@ This script automates the process of building the most common pentesting Linux d
|
|||
## Running
|
||||
|
||||
Just clone the repository, then make whatever changes you wish to make.
|
||||
* .deb files in the debs/ folder will be installed into the image.
|
||||
* Files in the filesystem/ folder will be copied to the system.
|
||||
* Add any .deb files to the debs/ folder that you want installed into the image.
|
||||
* Add any files to the filesystem/ folder that you want on the final system.
|
||||
* Add any extra software from the repository you wish to install to the config/software.list.chroot file.
|
||||
* Add any commands you want to have run during the build process to the config/pentest-distro-builder.chroot file.
|
||||
|
||||
When you're ready to build, run `sudo ./runme.sh` . Once it's complete, the finished image will be copied to the images/ folder.
|
||||
|
||||
If you run the script without any options, it will build whichever OS you are currently running, and prompt for which desktop environment and repository you wish to use. If you wish, however, you can manually specify these options instead:
|
||||
If you run the script without any options, it will build whichever OS you are currently running, and prompt for which desktop environment and repository you wish to use. If you wish, however, you can manually specify these options instead (for example, to script an image to be built nightly or weekly):
|
||||
|
||||
* -u
|
||||
* Unattended mode (skip the menu, required for the other options to function)
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
#!/bin/sh
|
||||
|
||||
#Populate root's home folder from /etc/skel
|
||||
cp -ru /etc/skel/* /root/
|
||||
cp -r /etc/skel/* /root/
|
||||
|
||||
#Time to git stuff...
|
||||
cd /root/
|
||||
|
@ -9,12 +9,13 @@ git clone https://github.com/Veil-Framework/Veil.git
|
|||
git clone https://github.com/leebaird/discover.git
|
||||
git clone https://github.com/trustedsec/ptf
|
||||
|
||||
#Enable our desired services
|
||||
ssh-keygen -t rsa -N "" -f ~/.ssh/id_rsa
|
||||
|
||||
#Enable our desired services
|
||||
systemctl enable ssh
|
||||
systemctl enable cups
|
||||
systemctl enable apache2
|
||||
systemctl enable mysql
|
||||
systemctl enable postgresql
|
||||
systemctl enable tor
|
||||
systemctl enable cockpit.socket
|
||||
systemctl enable cockpit.socket
|
|
@ -28,4 +28,6 @@ cherrytree
|
|||
libreoffice
|
||||
gimp
|
||||
audacity
|
||||
vlc
|
||||
vlc
|
||||
gedit
|
||||
gedit-plugins
|
||||
|
|
|
@ -5,6 +5,9 @@ set -o pipefail # Bashism
|
|||
|
||||
parrot_mirror=http://archive.parrotsec.org/parrot
|
||||
|
||||
public_mirror=http://deb.parrotsec.org/parrot
|
||||
|
||||
|
||||
# Detect target architecture and filter args
|
||||
if [ ! $arch ]; then
|
||||
arch=$(dpkg --print-architecture)
|
||||
|
@ -107,7 +110,7 @@ lb config noauto \
|
|||
--mirror-bootstrap "$parrot_mirror" \
|
||||
--mirror-chroot "$parrot_mirror" \
|
||||
--mirror-debian-installer "$parrot_mirror" \
|
||||
--mirror-binary "$parrot_mirror" \
|
||||
--mirror-binary "$public_mirror" \
|
||||
--iso-application "Parrot" \
|
||||
--iso-publisher "Parrot Project" \
|
||||
--iso-volume "ParrotSec" \
|
||||
|
|
|
@ -1,20 +0,0 @@
|
|||
#!/bin/sh
|
||||
|
||||
#Populate root's home folder from /etc/skel
|
||||
cp -ru /etc/skel/* /root/
|
||||
|
||||
#Time to git stuff...
|
||||
cd /root/
|
||||
git clone https://github.com/Veil-Framework/Veil.git
|
||||
git clone https://github.com/leebaird/discover.git
|
||||
git clone https://github.com/trustedsec/ptf
|
||||
|
||||
#Enable our desired services
|
||||
ssh-keygen -t rsa -N "" -f ~/.ssh/id_rsa
|
||||
systemctl enable ssh
|
||||
systemctl enable cups
|
||||
systemctl enable apache2
|
||||
systemctl enable mysql
|
||||
systemctl enable postgresql
|
||||
systemctl enable tor
|
||||
systemctl enable cockpit.socket
|
4
runme.sh
4
runme.sh
|
@ -74,6 +74,7 @@ Kali)
|
|||
cp ./debs/*.deb build/live-build-config/kali-config/variant-$DESKTOP/packages.chroot/
|
||||
cp -rv filesystem/* ./build/live-build-config/kali-config/common/includes.chroot/
|
||||
cp config/software.list.chroot ./build/live-build-config/kali-config/variant-$DESKTOP/package-lists/
|
||||
cp config/pentest-distro-builder.chroot ./build/live-build-config/kali-config/common/hooks/live/
|
||||
|
||||
if [ $REPO != "default" ];
|
||||
then
|
||||
|
@ -90,11 +91,12 @@ Parrot)
|
|||
cp ./debs/*.deb build/parrot-build/templates/parrot-variant-$DESKTOP/packages.chroot/
|
||||
cp -rv filesystem/* ./build/parrot-build/templates/common/includes.chroot/
|
||||
cp config/software.list.chroot ./build/parrot-build/templates/parrot-variant-$DESKTOP/package-lists/
|
||||
cp config/pentest-distro-builder.chroot ./build/parrot-build/templates/common/hooks/normal/
|
||||
|
||||
if [ $REPO != "default" ];
|
||||
then
|
||||
sed -i "s|archive.parrotsec.org|$REPO|g" ./build/parrot-build/auto/config
|
||||
sed -i "s|deb.parrotsec.org|$REPO|g" ./build/parrot-build/templates/common/archives/parrot.list
|
||||
#sed -i "s|deb.parrotsec.org|$REPO|g" ./build/parrot-build/templates/common/archives/parrot.list
|
||||
fi
|
||||
|
||||
cd build/parrot-build
|
||||
|
|
Loading…
Reference in a new issue