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
V0.6 short invites #1571
Merged
Merged
V0.6 short invites #1571
Changes from 1 commit
Commits
Show all changes
48 commits
Select commit
Hold shift + click to select a range
720d5ea
Implement libretroshare short invites support
G10h4ck bde6235
Fix windows compilation
G10h4ck dac7643
Merge pull request #1565 from G10h4ck/short_invites_v2
csoler 56e591f
added a flag in peerState specific to short invites, and several chec…
csoler 4eb6b0b
fixed uninitialized memory read for variable mRsEventsHandle
csoler 8fddb55
fixed stupid bug that crashed the code in a different place
csoler 3a799ba
added optional display of short invites in places with certificates
csoler 4bd5aaa
added parsing of short invites in connect friend wizard (not working …
csoler fb52f67
fixed up addign friend from short invite
csoler 76cf64f
fixed compilation
csoler a7141cb
removed unused startWizard and loadCert code in HomePage
csoler 6294aef
removed unused intro page from ConnectFriendWizard
csoler 0c510a5
removed unused RsId and Fof pages from ConnectFriendWizard
csoler c0436b7
removed unused Email page from ConnectFriendWizard
csoler a55e824
removed unused FriendRequest page from ConnectFriendWizard
csoler a04079d
removed unused Cert page from ConnectFriendWizard
csoler 1f56ef3
removed unused Cert page from ConnectFriendWizard
csoler 38434f2
removed unused Cert page from ConnectFriendWizard
csoler 57a5485
fixed adding friend with short invite
csoler 805f753
fixed parsing of short invite
csoler 6114d97
removed CIRCLES-related dead code from friendlist
csoler e132ce7
attempt to add SSL-only friends in FriendList - does not work yet
csoler 9312d0c
converted short invites to compact PGP format for increased robustness
csoler a52451b
moved SSL part of friend list into a separate function
csoler daec6b3
arranged to show PGP id for friends from short invite. Name not avail…
csoler 6419b03
merged upstream/master
csoler dd90314
fixed missing type conversion
csoler c8064e1
fixed missing parameter in jsonapi declaration
csoler 3a58aa4
add special profile item for not yet validated peer from short invite
csoler bbf92bd
fixed remanent bug due causing the deletion of rsEvent
csoler b0c7f8f
fixed display of non validated nodes without fingerprint
csoler a20ec1a
fixed exchange of PGP keys in binary format and update of PGP signatu…
csoler bea6769
removed unused code from p3gossipdiscovery
csoler b4fe1d4
started documenting p3GossipDiscovery
csoler 32b4312
improved security checks in authssl by verifying that the supplied PG…
csoler 44d6cb7
finished documentation/review of discovery
csoler 654d760
fixed comments from review of PR
csoler 4fabf3d
renamed skip_signature_validation into more appropriate skip_pgp_sign…
csoler ed864f9
removed some debug info about PGP signature validation, and added the…
csoler 6919711
restricted check for matching PGP ids to short invites only, since ot…
csoler 9c7edff
fixed bug caused by shadowing a variable
csoler 19ced52
fixed bug caused by wrong reading of disc flag
csoler 9b78447
used RsInfo instead of std::cerr in authssl.cc
csoler cdeee01
removed dependency of FriendDialog on RsAutoUpdatePage which is not n…
csoler 282d2d3
added missing notifications when adding friends
csoler a04d56e
fixed wrong default value for showUnconnected nodes
csoler d055887
removed some dead code
csoler 24781a7
removed unused mOthersList from PeerMgr
csoler File filter
Filter by extension
Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In case we get an unknown field we should just print a warning and ignore it, just in case we decide to add some new field in newer versions, so we can stay compatible with the past versions. Did you remember we had to do the same change on old certs? Maybe we need to add filed length too for achieving that?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree on the principle. In this case I had an invite that did not parse and therefore the parser is actually going through the entire data byte by byte. This is the consequence of not storing the size of each field (which we actually do in RS certificate format) in which case it's more easy to distinguish random data (that has inconsistent size) from correct field with unknown tag (that has consistent size). So it seems to me that because we cannot decide, it's safer to return false otherwise, when parsing random data you'd easily end up with a random supposedly valid SSL id and PGP fingerprint.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Another way to see the problem is that if you have 1 unknown field in the middle of the invite, the parser will not be able to skip it. It will instead try to interpret each and every byte in this field as a potential tag. That's likely to make the parsing completely wrong and even prevent the correct reading of the remaining fields. It seems to me that it would be safer to add sizes (which is 1 byte most of the time in the 1-2-5 encoding).