2019 juni examen

Theorie


DE VOLGENDE 3 VRAGEN WAREN EXACT HETZELFDE OP HET HEREXAMEN!

Praktijk

Praktijkexamen 1

echo | openssl s_client -connect facebook.com:443 | openssl x509 -text -noout | grep -o 'DNS' | wc -l

 

cat /usr/share/dict/dutch | grep -P '^[a-zA-Z]{11}$' | grep -vP '(.).*\1'
cat /etc/debconf.conf | grep -vP '^#'

 

tshark -r ftp_bruteforce.pcap -Y 'ftp.request.command == USER' -T fields -e ‘ftp.request.arg’ | sort -u

 

alfa.key matches to beta.crt gamma.key matches to delta.crt

for key in $(ls -1 *.key); do for crt in $(ls -1 *.crt); do if [ [ $(openssl rsa -in $key -noout -modulus | md5sum) == $(openssl x509 -in $crt -noout 
 -modulus | md5sum) ]]; then echo $key matches $crt; fi; done; done

--> er is een bestand '/home/logs' op leia waar je dit mee kan testen

Praktijkexamen 2

Words with 14 letters: bedrijfsomvang ... Words with 15 letters: ...

for foo in 14 15 16; do echo -e "Words with $foo letters:" && grep -P "^.{$foo}$" /usr/share/dict/dutch | grep -Pv '(.).*\1';done

secret 'mysecret' using the Diffie Hellman algorithm. Alice wants to display the contents of the file directly on her screen in stead of storing it locally and then opening it. Use a suitable encryption algorithm. The data is sent over a medium which only allows ASCII text. Alice is logged in on debbie and Bob on the virtual machine.

the 5 IP adresses that contacted the web server the most. The apache log is located in /home/log. Create a correct oneliner. The output should look something like this: (count IPs) 8000 10.10.10.10 ... 82 81.30.45.89

cat /home/logs/apache_google.log | awk '{print $1}' | sort | uniq -c | sort -rn | head -5

Praktijkexamen 3

grep -P '^([a-zA-Z])([a-zA-Z])[a-zA-Z]\2\1$' /usr/share/dict/dutch
echo | openssl s_client -connect wiki.uclllabs.be:443 2>/dev/null | openssl x509 -fingerprint -serial -pubkey -noout
mkdir -p ~/temp/dir1/dir2/dir3

Revision #1
Created 17 June 2021 12:05:34 by Jasper G.
Updated 3 December 2021 22:13:08 by Jasper G.