Skip to content

Ung 1067 verfication#17

Open
UBOK19 wants to merge 70 commits intomasterfrom
UNG-1067-verfication
Open

Ung 1067 verfication#17
UBOK19 wants to merge 70 commits intomasterfrom
UNG-1067-verfication

Conversation

@UBOK19
Copy link
Copy Markdown

@UBOK19 UBOK19 commented Apr 7, 2022

No description provided.

UBOK19 and others added 30 commits March 3, 2021 15:16
@UBOK19 UBOK19 requested a review from gruenwaldi April 7, 2022 12:03
Copy link
Copy Markdown

@gruenwaldi gruenwaldi left a comment

Choose a reason for hiding this comment

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

please check and work on comments

Comment thread examples/upp-anchoring-status.py Outdated
if r.status_code == 200:
logger.info("The UPP is known to the uBirch backend! (code: %d)" % r.status_code)

jobj = json.loads(r.content)
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

please rename jobj

Comment thread examples/EXAMPLES.md Outdated
- [Generating and managing a keypair](#generating-and-managing-a-keypair)
- [Registering a public key](#registering-a-public-key)
- [Gathering Data](#gathering-data)
- [Creating an UPP](#creating-an-upp)
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

it is a UPP , not an UPP. Please check the whole file

Comment thread examples/EXAMPLES.md Outdated
When working with `chained UPPs` it can be useful to check whether the chain is in order and valid. For
this task, the [`upp-chain-checker.py`](upp-chain-checker.py) can be used. It reads in a list of UPPs,
checks the signature of each UPP and compares the `prevsig` field with the `signature` of the last UPP.
If at any point something doesn't match up, it will print an error message alonge with the number of the
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

typo in alonge

Comment thread examples/upp-creator.py Outdated
logger.info("UPP [hex]: \"%s\"" % binascii.hexlify(self.upp).decode())

# try to write the upp
with open(self.output, "wb") as fd:
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

change fd to file

Comment thread examples/upp-sender.py Outdated

def store_response_upp(self) -> bool:
try:
with open(self.output, "wb") as fd:
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

change fd to file

Comment thread examples/upp-verifier.py


if __name__ == "__main__":
sys.exit(Main().run()) No newline at end of file
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

add newline

Comment thread examples/upp-verifier.py
try:
logger.info("Reading the input UPP from \"%s\"" % self.input)

with open(self.input, "rb") as fd:
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

see comment above

Comment thread examples/upp-sender.py Outdated


if __name__ == "__main__":
sys.exit(Main().run()) No newline at end of file
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

add newline


self.assertEqual(hashlib.sha256(b"UBIRCH").digest(), unpacked[3]) No newline at end of file
self.assertEqual(p.verfiy_signature(UUID(bytes=unpacked[1]), message), True)
self.assertEqual(hashlib.sha256(b"UBIRCH").digest(), unpacked[3])
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

look for legacy trackle test and comment it out

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.

2 participants