Skip to content

Fixes for #1820 - Handle invalid node certificates (storage and discovery)#2280

Merged
cygnusv merged 4 commits intonucypher:blue-oyster-mushroomsfrom
KPrasch:fistro
Sep 23, 2020
Merged

Fixes for #1820 - Handle invalid node certificates (storage and discovery)#2280
cygnusv merged 4 commits intonucypher:blue-oyster-mushroomsfrom
KPrasch:fistro

Conversation

@KPrasch
Copy link
Member

@KPrasch KPrasch commented Sep 21, 2020

Based on #2265
Closes #1820

@KPrasch KPrasch requested review from cygnusv, derekpierre and jMyles and removed request for jMyles September 21, 2020 22:43
@cygnusv cygnusv force-pushed the blue-oyster-mushrooms branch from cf8913f to 395135f Compare September 22, 2020 07:56
@KPrasch KPrasch changed the title [WIP] Fixes for #1820 - Handle invalid node certificates (storage and discovery) Fixes for #1820 - Handle invalid node certificates (storage and discovery) Sep 22, 2020
@KPrasch KPrasch marked this pull request as ready for review September 22, 2020 16:30
try:
certificate_filepath = self.node_storage.store_node_certificate(certificate=stranger_certificate)
except InvalidNodeCertificate:
return False # that was easy
Copy link
Member

Choose a reason for hiding this comment

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

Duh!

Copy link
Member

@derekpierre derekpierre left a comment

Choose a reason for hiding this comment

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

🎸

# Sanity check:
# Validate the checksum address inside the cert as a consistency check against
# nodes that may have been altered on the disk somehow.
read_certificate_pseudonym(certificate=certificate)
Copy link
Member

Choose a reason for hiding this comment

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

👍

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