Created
November 20, 2021 12:12
-
-
Save rcastellotti/e46c651f69dff25c3decef03e515cbd7 to your computer and use it in GitHub Desktop.
Download every HAC (Handbook of Applied Cryptography) chapter
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
url="https://cacr.uwaterloo.ca/hac/about/" | |
mkdir hac | |
cd hac | |
wget -O "00 TOC.pdf" "${url}toc3.pdf" | |
wget -O "01 Overview of cryptograpy.pdf" "${url}chap1.pdf" | |
wget -O "02 Mathematics Background.pdf" "${url}chap2.pdf" | |
wget -O "03 Number-Theoretic Reference Problems.pdf" "${url}chap3.pdf" | |
wget -O "04 Public-Key Parameters.pdf" "${url}chap4.pdf" | |
wget -O "05 Pseudorandom bits and Sequences.pdf" "${url}chap5.pdf" | |
wget -O "06 Stream Ciphers.pdf" "${url}chap6.pdf" | |
wget -O "07 Block Ciphers.pdf" "${url}chap7.pdf" | |
wget -O "08 Public-Key Encryption.pdf" "${url}chap8.pdf" | |
wget -O "09 Hash Functions and Data Integrity.pdf" "${url}chap9.pdf" | |
wget -O "10 Identification and Entity Authentication.pdf" "${url}chap10.pdf" | |
wget -O "11 Digital Signatures.pdf" "${url}chap11.pdf" | |
wget -O "12 Key Estabilishment Protocols.pdf" "${url}chap12.pdf" | |
wget -O "13 Key Management Techniques.pdf" "${url}chap13.pdf" | |
wget -O "14 Efficient Implementation.pdf" "${url}chap14.pdf" | |
wget -O "15 Patents and Standards.pdf" "${url}chap15.pdf" | |
wget -O "16 Bibliography of Papers from Selected Cryptographic Forums.pdf" "${url}appendix.pdf" | |
wget -O "17 References.pdf" "${url}references.pdf" | |
wget -O "18 Index.pdf" "${url}index.pdf" | |
# check if command exists and fail otherwise | |
command -v pdfunite >/dev/null 2>&1 | |
if [[ $? -ne 0 ]]; then | |
echo "Pdfunite required to merge pdfs!" | |
exit 1 | |
fi | |
pdfunite *.pdf hac.pdf |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment