Compare commits

..

12 Commits
v1.11 ... v1.13

Author SHA1 Message Date
ab53094f90 updating TODO 2015-06-27 22:53:28 -04:00
cab43beffc adding ipxe notes 2015-06-27 22:02:07 -04:00
8de80fde9d adding iPXE, fixing changed package name 2015-06-27 21:07:24 -04:00
1503f55f5b adding iPXE 2015-06-26 22:32:25 -04:00
e97cda244e adding newer wps breaking stuffs 2015-06-25 16:02:56 -04:00
aa68cd49fb oops- *don't* remove machine-id. 2015-06-07 15:20:41 -04:00
71a2e1ad88 fixing split arch 2015-05-21 15:31:49 -04:00
32c39ff7e1 finalized split-iso. working 2015-05-21 02:47:36 -04:00
56806ba880 yeah, fuck NetworkManager, use --purgebuild 2015-05-20 23:55:54 -04:00
7f62dbb3ee disabling acpidump- no longer in repos 2015-05-15 14:05:25 -04:00
812e861152 adding apacman.conf 2015-05-15 13:53:16 -04:00
e601e50570 updating TODO 2015-05-15 02:48:35 -04:00
13 changed files with 125 additions and 17 deletions

2
.gitignore vendored
View File

@@ -23,3 +23,5 @@
/screenlog* /screenlog*
/logs /logs
*.swp *.swp
*.lck
#src/ipxe/src/

5
.gitmodules vendored Normal file
View File

@@ -0,0 +1,5 @@
[submodule "src/ipxe"]
path = src/ipxe
url = git://git.ipxe.org/ipxe.git
[submodule "ipxe"]
branch = master

2
TODO
View File

@@ -17,6 +17,7 @@
-autodetection/configuration of network. DHCP is currently running by default, but does it need to support IPv6? if so, how would the user configure their network? -autodetection/configuration of network. DHCP is currently running by default, but does it need to support IPv6? if so, how would the user configure their network?
-WISH: support iPXE? would save on ISO file size (letting us create MUCH bigger squash systems), but the downside is we lose EFI support and it requires a working network configuration- which defeats the purpose of a diagnostic disc. -WISH: support iPXE? would save on ISO file size (letting us create MUCH bigger squash systems), but the downside is we lose EFI support and it requires a working network configuration- which defeats the purpose of a diagnostic disc.
-SECURE SSH: https://stribika.github.io/2015/01/04/secure-secure-shell.html -SECURE SSH: https://stribika.github.io/2015/01/04/secure-secure-shell.html
-DISABLE NETWORKMANAGER AND "fi.w1.wpa_supplicant1"??? keeps spawning wpa_supplicant (and thusly killing networking proper)
## Building ## ## Building ##
@@ -30,6 +31,7 @@
-does gummiboot? loader? wtfever it's called support splash backgrounds? can i implement that differently somehow? -does gummiboot? loader? wtfever it's called support splash backgrounds? can i implement that differently somehow?
-Host-specific chroot customizations (i.e. -J in <chroot>/etc/makepkg.conf -Host-specific chroot customizations (i.e. -J in <chroot>/etc/makepkg.conf
-strip out/remove unnecessary and orphan packages (e.g. gcc, make, automake, etc.) -strip out/remove unnecessary and orphan packages (e.g. gcc, make, automake, etc.)
-incorporate iPXE image building for "mini-iso's/mini-img's"
__________________________________________________________ __________________________________________________________
FOOTNOTES: FOOTNOTES:

View File

@@ -30,7 +30,7 @@ BASEDIR="$(pwd)"
ISODIR="${BASEDIR}/iso" ISODIR="${BASEDIR}/iso"
# Where source code is kept. # Where source code is kept.
SRCDIR="${BASEDIR}/src" SRCDIR="${BASEDIR}/extrasrc"
# Where we mount for chroots etc. # Where we mount for chroots etc.
MOUNTPT="/mnt/${UXNAME}" MOUNTPT="/mnt/${UXNAME}"

View File

@@ -2,7 +2,7 @@
# We need to install all X drivers. # We need to install all X drivers.
abs abs
acpi acpi
acpidump #acpidump
afflib afflib
aircrack-ng aircrack-ng
apr apr
@@ -16,6 +16,7 @@ autopsy
autossh autossh
beep beep
bin86 bin86
bind-tools
binutils binutils
bluez-utils bluez-utils
bonnie++ bonnie++
@@ -60,7 +61,7 @@ djohn
dmidecode dmidecode
dnssec-anchors dnssec-anchors
dnstracer dnstracer
dnsutils #dnsutils #replaced by bind-tools, https://www.archlinux.org/packages/extra/x86_64/bind-tools/
dos2unix dos2unix
dosfstools dosfstools
dropbear dropbear
@@ -235,14 +236,14 @@ psmisc
pv pv
pwgen pwgen
pxz pxz
pyrit pyrit-svn
python2-gnuplot python2-gnuplot
python2-pyx python2-pyx
rarcrack rarcrack
rcracki_mt rcracki_mt
rdiff-backup rdiff-backup
read-edid read-edid
reaver reaver-wps-fork-t6x-git
rename rename
rfkill rfkill
rp-pppoe rp-pppoe
@@ -319,7 +320,7 @@ vpnc
weplab weplab
whdd whdd
whois whois
wifite wifite-mod-pixiewps-git
wipe wipe
wireshark-cli wireshark-cli
wpscrack wpscrack

View File

@@ -0,0 +1,57 @@
#
# /etc/apacman.conf
#
# See the apacman.conf(5) manpage for options
#
# GENERAL OPTIONS
#
#auronly=1
#buildonly=1
#cachevcs=1
#ignorearch=1
#needed=1
noconfirm=1
noedit=1
#noaur=1
#noconfirm=1
#noedit=1
#nofail=1
#preview=1
#purgebuild=1
#quiet=1
#skipcache=1
skipinteg=1
#skiptest=1
#warn=1
tmpdir=/var/tmp/apacman
TMPDIR=/var/tmp/apacman
#
# CONFIGURATION
#
#tmpdir="/tmp/apacmantmp-$UID"
#makepkgconf="/etc/makepkg.conf"
#usermakepkgconf="$HOME/.makepkg.conf"
#pacmanconf="/etc/pacman.conf"
#downdir="/var/cache/pacman/pkg"
#savedir="/var/cache/apacman/pkg"
#editor="nano -w"
editor="vim"
#RPCURL="https://aur.archlinux.org/rpc.php?type"
#PKGURL="https://aur.archlinux.org"
#ABSURL="rsync.archlinux.org"
#
# COLORIZATION
#
COLOR1='\e[1;39m'
COLOR2='\e[1;32m'
COLOR3='\e[1;35m'
COLOR4='\e[1;36m'
COLOR5='\e[1;34m'
COLOR6='\e[1;33m'
COLOR7='\e[1;31m'

View File

@@ -0,0 +1,3 @@
#!/bin/bash
sed -i -e 's/any/x86_64/g' ${1}

View File

@@ -43,6 +43,11 @@ function will_it_blend () {
local BUILDDIR="${BUILDDIR}${ARCHSUFFIX}" local BUILDDIR="${BUILDDIR}${ARCHSUFFIX}"
# now let's build the squashed image... and generate some checksums as well to verify download integrity. # now let's build the squashed image... and generate some checksums as well to verify download integrity.
# are we building split-arch ISOs?
if [[ "${MULTIARCH}" == "n" ]];
then
rm -rf ${ARCHBOOT}
fi
mkdir -p ${ARCHBOOT}/${AIROOT} mkdir -p ${ARCHBOOT}/${AIROOT}
if [ ! -f "${ARCHBOOT}/${AIROOT}/airootfs.sfs" ] || [ "${CHROOTDIR}/root/.bash_history" -nt "${ARCHBOOT}/${AIROOT}/airootfs.sfs" ]; if [ ! -f "${ARCHBOOT}/${AIROOT}/airootfs.sfs" ] || [ "${CHROOTDIR}/root/.bash_history" -nt "${ARCHBOOT}/${AIROOT}/airootfs.sfs" ];

View File

@@ -59,11 +59,23 @@ EOF
# create the embedded efiboot FAT stuff # create the embedded efiboot FAT stuff
# how big should we make the disk? # how big should we make the disk?
echo "Generating the EFI embedded FAT filesystem..." echo "Generating the EFI embedded FAT filesystem..."
FTSIZE=$(du -sc ${TEMPDIR}/{boot,EFI,loader} | tail -n1 | awk '{print $1}') # are we building split-arch ISOs?
FATSIZE=$((${FTSIZE} + 64)) # let's give a little wiggle room if [[ "${MULTIARCH}" == "n" ]];
${RACECAR_CHK}truncate -s "${FATSIZE}"K ${TEMPDIR}/EFI/${DISTNAME}/efiboot.img then
rm -f ${TEMPDIR}/EFI/${DISTNAME}/efiboot.img
fi
# now we need to calculate the space for various files we're going to include...
FATSIZE=$(stat --format="%s" ${TEMPDIR}/boot/${UXNAME}.64.kern) # EFI/BDISK/bdisk.efi
FATSIZE=$((${FATSIZE} + $(stat --format="%s" ${TEMPDIR}/boot/${UXNAME}.64.img))) # EFI/BDISK/bdisk.img
FATSIZE=$((${FATSIZE} + $(stat --format="%s" ${BASEDIR}/root.x86_64/usr/lib/prebootloader/PreLoader.efi))) # EFI/boot/bootx64.efi
FATSIZE=$((${FATSIZE} + $(stat --format="%s" ${BASEDIR}/root.x86_64/usr/lib/prebootloader/HashTool.efi))) # EFI/boot/HashTool.efi
FATSIZE=$((${FATSIZE} + $(stat --format="%s" ${BASEDIR}/root.x86_64/usr/lib/gummiboot/gummibootx64.efi))) # EFI/boot/loader.efi
FATSIZE=$((${FATSIZE} + $(stat --format="%s" ${TEMPDIR}/EFI/shellx64_v1.efi)))
FATSIZE=$((${FATSIZE} + $(stat --format="%s" ${TEMPDIR}/EFI/shellx64_v2.efi)))
FATSIZE=$((${FATSIZE} + $(du -sb ${TEMPDIR}/loader | tail -n1 | awk '{print $1}'))) # loader/* (okay so i cheated a little here.)
FATSIZE=$((${FATSIZE} + 786432)) # let's give a little wiggle room; 768k should do it. -_-
${RACECAR_CHK}truncate -s "${FATSIZE}" ${TEMPDIR}/EFI/${DISTNAME}/efiboot.img
${RACECAR_CHK}mkfs.vfat -F 32 -n ${DISTNAME}_EFI ${TEMPDIR}/EFI/${DISTNAME}/efiboot.img >> "${LOGFILE}.${FUNCNAME}" 2>&1 ${RACECAR_CHK}mkfs.vfat -F 32 -n ${DISTNAME}_EFI ${TEMPDIR}/EFI/${DISTNAME}/efiboot.img >> "${LOGFILE}.${FUNCNAME}" 2>&1
#${RACECAR_CHK}mkfs.vfat -F32 -s2 -n ${DISTNAME}_EFI ${TEMPDIR}/EFI/${DISTNAME}/efiboot.img >> "${LOGFILE}.${FUNCNAME}" 2>&1
mkdir -p ${SRCDIR}/efiboot mkdir -p ${SRCDIR}/efiboot
mount ${TEMPDIR}/EFI/${DISTNAME}/efiboot.img ${SRCDIR}/efiboot mount ${TEMPDIR}/EFI/${DISTNAME}/efiboot.img ${SRCDIR}/efiboot
mkdir -p ${SRCDIR}/efiboot/EFI/${DISTNAME} mkdir -p ${SRCDIR}/efiboot/EFI/${DISTNAME}
@@ -99,7 +111,7 @@ EOF
cp ${BASEDIR}/root.x86_64/usr/lib/prebootloader/PreLoader.efi ${SRCDIR}/efiboot/EFI/boot/bootx64.efi cp ${BASEDIR}/root.x86_64/usr/lib/prebootloader/PreLoader.efi ${SRCDIR}/efiboot/EFI/boot/bootx64.efi
cp ${BASEDIR}/root.x86_64/usr/lib/prebootloader/HashTool.efi ${SRCDIR}/efiboot/EFI/boot/. cp ${BASEDIR}/root.x86_64/usr/lib/prebootloader/HashTool.efi ${SRCDIR}/efiboot/EFI/boot/.
cp ${BASEDIR}/root.x86_64/usr/lib/gummiboot/gummibootx64.efi ${SRCDIR}/efiboot/EFI/boot/loader.efi # TODO: can i use syslinux.efi instead? cp ${BASEDIR}/root.x86_64/usr/lib/gummiboot/gummibootx64.efi ${SRCDIR}/efiboot/EFI/boot/loader.efi # TODO: can i use syslinux.efi instead?
cp ${TEMPDIR}/EFI/shellx64_v* ${SRCDIR}/efiboot/EFI/. cp ${TEMPDIR}/EFI/shellx64_v{1,2}.efi ${SRCDIR}/efiboot/EFI/.
umount ${SRCDIR}/efiboot umount ${SRCDIR}/efiboot
echo "EFI configuration complete..." echo "EFI configuration complete..."

View File

@@ -38,7 +38,7 @@ function mentos {
local NEWKERN=$(curl -s "${MIRROR}" | grep linux | awk '{print $3}' | cut -f2 -d\" | egrep '^linux-[0-9].*pkg.tar.xz$' | cut -f2 -d"-") local NEWKERN=$(curl -s "${MIRROR}" | grep linux | awk '{print $3}' | cut -f2 -d\" | egrep '^linux-[0-9].*pkg.tar.xz$' | cut -f2 -d"-")
for x in $(find ${i}/etc/ -type f -iname "*.pacorig");do mv -f ${x} ${x%.pacorig} ; done for x in $(find ${i}/etc/ -type f -iname "*.pacorig");do mv -f ${x} ${x%.pacorig} ; done
${CHROOTCMD} ${i}/ bash -c "${RACECAR_CHK}apacman --noconfirm --noedit --skipinteg -S --needed --ignore linux ${PKGLIST}" >> "${LOGFILE}.${FUNCNAME}" 2>&1 ${CHROOTCMD} ${i}/ bash -c "${RACECAR_CHK}apacman --noconfirm --noedit --skipinteg -S --needed --purgebuild --ignore linux ${PKGLIST}" >> "${LOGFILE}.${FUNCNAME}" 2>&1
for x in $(find ${i}/etc/ -type f -iname "*.pacorig");do mv -f ${x} ${x%.pacorig} ; done for x in $(find ${i}/etc/ -type f -iname "*.pacorig");do mv -f ${x} ${x%.pacorig} ; done
${CHROOTCMD} ${i}/ /usr/bin/bash -c "mkinitcpio -p linux" >> "${LOGFILE}.${FUNCNAME}" 2>&1 ${CHROOTCMD} ${i}/ /usr/bin/bash -c "mkinitcpio -p linux" >> "${LOGFILE}.${FUNCNAME}" 2>&1
#${CHROOTCMD} ${i}/ bash -c "apacman --noconfirm --noedit --skipinteg -S --needed ${PKGLIST}" #${CHROOTCMD} ${i}/ bash -c "apacman --noconfirm --noedit --skipinteg -S --needed ${PKGLIST}"
@@ -53,7 +53,7 @@ function mentos {
PKGLIST=$(sed -e '/^[[:space:]]*#/d ; /^[[:space:]]*$/d' ${BASEDIR}/extra/packages.32 | tr '\n' ' ') PKGLIST=$(sed -e '/^[[:space:]]*#/d ; /^[[:space:]]*$/d' ${BASEDIR}/extra/packages.32 | tr '\n' ' ')
if [ -n "${PKGLIST}" ]; if [ -n "${PKGLIST}" ];
then then
${CHROOTCMD} ${CHROOTDIR32}/ bash -c "yes '' | ${RACECAR_CHK}apacman --noconfirm --noedit --skipinteg -S --needed ${PKGLIST}" >> "${LOGFILE}.${FUNCNAME}" 2>&1 ${CHROOTCMD} ${CHROOTDIR32}/ bash -c "yes '' | ${RACECAR_CHK}apacman --noconfirm --noedit --skipinteg -S --needed --purgebuild ${PKGLIST}" >> "${LOGFILE}.${FUNCNAME}" 2>&1
fi fi
for x in $(find ${CHROOTDIR32}/etc/ -type f -iname "*.pacorig");do mv -f ${x} ${x%.pacorig} ; done for x in $(find ${CHROOTDIR32}/etc/ -type f -iname "*.pacorig");do mv -f ${x} ${x%.pacorig} ; done
@@ -62,7 +62,7 @@ function mentos {
PKGLIST=$(sed -e '/^[[:space:]]*#/d ; /^[[:space:]]*$/d' ${BASEDIR}/extra/packages.64 | tr '\n' ' ') PKGLIST=$(sed -e '/^[[:space:]]*#/d ; /^[[:space:]]*$/d' ${BASEDIR}/extra/packages.64 | tr '\n' ' ')
if [ -n "${PKGLIST}" ]; if [ -n "${PKGLIST}" ];
then then
${CHROOTCMD} ${CHROOTDIR64}/ bash -c "yes '' | ${RACECAR_CHK}apacman --noconfirm --noedit --skipinteg -S --needed ${PKGLIST}" >> "${LOGFILE}.${FUNCNAME}" 2>&1 ${CHROOTCMD} ${CHROOTDIR64}/ bash -c "yes '' | ${RACECAR_CHK}apacman --noconfirm --noedit --skipinteg -S --needed --purgebuild ${PKGLIST}" >> "${LOGFILE}.${FUNCNAME}" 2>&1
fi fi
for x in $(find ${CHROOTDIR64}/etc/ -type f -iname "*.pacorig");do mv -f ${x} ${x%.pacorig} ; done for x in $(find ${CHROOTDIR64}/etc/ -type f -iname "*.pacorig");do mv -f ${x} ${x%.pacorig} ; done
#${CHROOTCMD} ${CHROOTDIR64}/ bash -c "apacman --noconfirm --noedit --skipinteg -S --needed ${PKGLIST}" #${CHROOTCMD} ${CHROOTDIR64}/ bash -c "apacman --noconfirm --noedit --skipinteg -S --needed ${PKGLIST}"

View File

@@ -94,10 +94,10 @@ function mkchroot {
echo "Local: ${LOCSUM64}" echo "Local: ${LOCSUM64}"
echo "Remote: ${CKSUM64}" echo "Remote: ${CKSUM64}"
echo "Fetching fresh copy." echo "Fetching fresh copy."
curl -o latest.64.tar.gz "${RLSDIR}/${CURRLS64}" >> "${LOGFILE}.${FUNCNAME}" 2>&1 curl -o latest.64.tar.gz "${RLSDIR}/${CURRLS64}"
fi fi
else else
curl -o latest.64.tar.gz "${RLSDIR}/${CURRLS64}" >> "${LOGFILE}.${FUNCNAME}" 2>&1 curl -o latest.64.tar.gz "${RLSDIR}/${CURRLS64}"
fi fi
if [ -f "latest.32.tar.gz" ]; if [ -f "latest.32.tar.gz" ];
@@ -154,6 +154,12 @@ EOF
for i in ${CHROOTDIR32} ${CHROOTDIR64}; for i in ${CHROOTDIR32} ${CHROOTDIR64};
do do
# Disable NetworkManager. Fuck that shit.
ln -s /dev/null ${i}/etc/systemd/system/NetworkManager.service
ln -s /dev/null ${i}/etc/systemd/system/NetworkManager-dispatcher.service
# Remove the machine-id file so it's automatically generated.
# NOTE: this kind of fucks things up presently.
#rm -f ${i}/etc/machine-id
# Prep pacman # Prep pacman
echo "Prepping ${i}. This will take a while..." echo "Prepping ${i}. This will take a while..."
echo -n "...Key initializing..." echo -n "...Key initializing..."

1
src/ipxe Submodule

Submodule src/ipxe added at d73982f098

14
src/ipxe-efi Normal file
View File

@@ -0,0 +1,14 @@
http://ipxe.org/download#efi
"
iPXE supports the EFI and UEFI environments, as well as the standard PC BIOS. You can build an EFI driver ROM using the .efirom image format. For example:
make bin-i386-efi/808610de.efirom # 32-bit driver ROM
make bin-x86_64-efi/808610de.efirom # 64-bit driver ROM
"
http://ipxe.org/efi/vision