-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Add root_certificate to add_torrent_params.
#7912
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
74e6331 to
70734b2
Compare
|
unfortunately the simulator doesn't support the SSL wrappers in boost.asio (yet). |
|
There is a test for the SSL feature already, which seem the most natural one to extend ( What happens if this field is set on a magnet link but the torrent turns out not to be an SSL torrent? (it should ideally be documented in the comment). Should the root certificate also be allowed to be passed on the magnet link URI as well? |
b54ec54 to
09754d7
Compare
|
Added a rudimentary test for success using metadata plugin in |
I could see it going both ways:
What is preferable to you? Another edge case is what if the root CAs don't match. Mismatch from either torrent file vs. add params, or metadata exchange. |
I don't see why not, the vast majority of root certs would fit in the 2048 character limit of a URL. |
|
I think the safest approach is to require it to be an SSL torrent if the certificate is specified. i.e. failing closed. |
|
I think this change warrants a note in |
09754d7 to
63b2a66
Compare
|
Added a testcase for when the seeding torrent does not have a certificate. It was already correct behaviour, as the handshake failed during peer connection before metadata exchange. Only outstanding thing is the python binding, is there a guide on building and testing it? Looks like support for magnet links will require:
I'm happy to take a stab at that, but maybe in a separate PR? Let me know your thoughts. |
63b2a66 to
052d03c
Compare
|
Had to remove the message check on the |
root_certificate to add_torrent_params.root_certificate to add_torrent_params.
|
Extending |
052d03c to
cbff507
Compare
|
Updated the target branch to master. |
This is so that a peer can join an ssl swarm with only a signed cert and infohash.
cbff507 to
f842797
Compare
|
@arvidn Should be good to go, fixed failing build and tests are passing locally. |
This is so that a peer can join an ssl swarm with only a signed cert and infohash.
Fixes #2192
@arvidn I couldn't get the simulator building with openssl, so I have no real way of testing this right now. Any guidance on how to solve that?