This was changed in cryptography 3.1. Most places in typeshed were already correct, fixed few remaining omissions.
See discussion in #2491 Co-authored-by: Ivan Levkivskyi <ilevkivskyi@dropbox.com>