Skip to content

Add config.rejectPublicKeyAlgorithms#1264

Merged
twiss merged 13 commits intoopenpgpjs:masterfrom
larabr:algo-blacklist
Mar 25, 2021
Merged

Add config.rejectPublicKeyAlgorithms#1264
twiss merged 13 commits intoopenpgpjs:masterfrom
larabr:algo-blacklist

Conversation

@larabr
Copy link
Copy Markdown
Collaborator

@larabr larabr commented Mar 10, 2021

Changes:

  • add config.rejectPublicKeyAlgorithms to disallow using the given algos to verify, sign or encrypt new messages or third-party certifications
  • consider config.minRsaBits when signing, verifying and encrypting messages and third-party certifications, not just on key generation
  • when verifying a message, if the verification key is not found (i.e. not provided or too weak), the corresponding signature will have signature.valid=false (used to be signature.valid=null). signature.error will detail whether the key is missing/too weak/other.

Generating and verifying key certification signatures is still permitted in all cases.

@tomholub
Copy link
Copy Markdown
Contributor

Excellent!

Copy link
Copy Markdown
Member

@twiss twiss left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 Thanks, looks good! Small nitpicks below 😊

Comment thread src/key/factory.js Outdated
Comment thread src/key/user.js Outdated
Comment thread src/message.js Outdated
Comment thread src/message.js Outdated
Comment thread src/key/helper.js Outdated
Comment thread src/key/key.js Outdated
Comment thread src/key/key.js Outdated
@larabr larabr force-pushed the algo-blacklist branch 3 times, most recently from 292d04f to 2f04938 Compare March 15, 2021 12:56
Comment thread src/key/factory.js Outdated
Comment thread src/key/helper.js
Comment thread src/key/helper.js Outdated
Comment thread src/key/key.js Outdated
Comment thread src/key/key.js Outdated
@larabr larabr mentioned this pull request Mar 19, 2021
1 task
Comment thread src/key/helper.js Outdated
@twiss twiss merged commit 8a57246 into openpgpjs:master Mar 25, 2021
@larabr larabr deleted the algo-blacklist branch June 10, 2021 09:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants