[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
Re: [tor-bugs] #16582 [Tor]: Distinguish ENOENT from other error cases when loading keys.
#16582: Distinguish ENOENT from other error cases when loading keys.
------------------------+--------------------------------
Reporter: nickm | Owner:
Type: defect | Status: needs_review
Priority: major | Milestone: Tor: 0.2.7.x-final
Component: Tor | Version:
Resolution: | Keywords:
Actual Points: | Parent ID: #16530
Points: |
------------------------+--------------------------------
Comment (by teor):
That makes much more sense - I've just checked, and the ed25519 code
doesn't use file_status.
In particular, ed_key_init_from_file and load_ed_keys assume every file
loading error is an ENOENT, and go and create new keys (and certificates!)
Is the plan to make this consistent with the key-handling code for other
key types?
In particular, after #13111, the following cases cause keys to be created:
* ENOENT - an absent key file (file_status FN_NOENT)
* a zero-length key file (file_status FN_EMPTY)
--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/16582#comment:4>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
_______________________________________________
tor-bugs mailing list
tor-bugs@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs