I am looking for a list of typical mistakes someone can make when implementing digital signatures for a software. And of course why they are mistakes and how an attacker could take advantage of them.
I do not mean implementing the crypto itself but applying/using a library (like GPG or something alike) in your own project.
What I thought of so far:
- Using weak algorithms for encryption and/or hashing. -> Attacker could fake a valid signature because he is able to find collisions.
- Wrong handling of public keys (for example a application just downloads a public key it needs for verification of a unknown signature). -> Man in the Middle attackers could replace the downloaded public key with their own and the application would verify files of the attacker.
- Signatures are not verified correctly (for example the software just tests if there is a signature, not if its valid.) -> Attacker could use "fake" signatures.
Are those possible mistakes to make? Are the implications correct?
Please give me your ideas on the topic.
Thanks in advance!
EDIT: This is for an assignment in a security class. So i just want to collect some ideas. They to not have to fit a specific system, protocol or software. Just some mistakes one could make in practice.