View Issue Details

IDProjectCategoryView StatusLast Update
0002856GNUnetobsoletepublic2024-05-03 12:02
ReporterMatthias Wachs Assigned ToMatthias Wachs Due Date
PrioritynormalSeverityminorReproducibilityhave not tried
Status closedResolutionfixed 
Product VersionGit master 
Target Version0.10.0Fixed in Version0.10.0 
Summary0002856: Handling of Friend-only HELLO messages
DescriptionWith 0002676 we introduced a F2F mode for HELLO messages.

Peerinfo supports this mode, but there are issues to be discussed regarding peerinfo service handling of HELLO messages.
TagsNo tags attached.

Activities

Matthias Wachs

2013-04-05 14:01

reporter   ~0007038

Changing from public -> f2f:

when a peer does that, it changes it's HELLO to FRIEND-HELLO
When it now changes back to public mode, it creates a new HELLO, that will be atm merged with the FRIEND-HELLO what results in a FRIEND-HELLO

gnunet-peerinfo-service.c: 520

Matthias Wachs

2013-04-05 14:03

reporter   ~0007039

Leaking host ids:

The friend-only flag is included in the HELLO message itself
But peerinfo service can have a peerid without a HELLO. If this id was created in F2F it's possible that it's leaked

Matthias Wachs

2013-04-05 14:10

reporter   ~0007040

Peerinfo service handles own's HELLO in the same way as other peer's HELLO

A peer's own HELLO is not added with all the other's peer in the same hashmap under the peer's id and query it by using it own peer id

Matthias Wachs

2013-04-05 14:14

reporter   ~0007041

Discussion:
peerinfo service uses a:
struct HostEntry
{

  /**
   * Identity of the peer.
   */
  struct GNUNET_PeerIdentity identity;

  /**
   * Hello for the peer (can be NULL)
   */
  struct GNUNET_HELLO_Message *hello;

};

Should we store both a private and a public HELLO in the struct?

How do we handle the peer id as public/friend only itself?

Christian Grothoff

2013-04-06 23:32

manager   ~0007042

PeerIdentity's themselves don't have to be secret, they're pretty meaningless to anyone. I think extending the 'struct HostEntry' with a third member for the friend-hello should be fine.

Matthias Wachs

2013-04-08 07:56

reporter   ~0007043

When leaking ids is not a problem that's fine for me.

Implementation idea:

struct HostEntry
{
  struct GNUNET_PeerIdentity identity;
  struct GNUNET_HELLO_Message *hello;
  struct GNUNET_HELLO_Message *friend_hello;
}

Discussion:

When client asks for friend hello and we have both public and friend:
- Do merge them? (IMHO yes)
When a client asks for a friend and we have a public do we return it?

IMHO yes to both questions since the include_friend flag in peerinfo api semantically means: "Do you public only or in addition friend only info?"

How do we serialize them to disc?
ATM hellos are written to disc using peer id as filename
- Append a suffix ".public" and ".friend"?

Christian Grothoff

2013-04-08 09:15

manager   ~0007044

Yes, we merge. If we just have a public one, we return the public one.

Serialize to disk: I think we should NOT use two files (high overhead), we can just write both HELLOs one after the other to the same file.

Matthias Wachs

2013-04-08 11:04

reporter   ~0007045

Sounds reasonable to me

Matthias Wachs

2013-04-10 11:29

reporter   ~0007046

Implemented with 26832.

Issue History

Date ModifiedUsernameFieldChange
2013-04-05 13:57Matthias WachsNew Issue
2013-04-05 14:01Matthias WachsNote Added: 0007038
2013-04-05 14:03Matthias WachsNote Added: 0007039
2013-04-05 14:10Matthias WachsNote Added: 0007040
2013-04-05 14:14Matthias WachsNote Added: 0007041
2013-04-05 14:14Matthias WachsStatusnew => feedback
2013-04-06 23:32Christian GrothoffNote Added: 0007042
2013-04-08 07:56Matthias WachsNote Added: 0007043
2013-04-08 07:56Matthias WachsStatusfeedback => new
2013-04-08 09:15Christian GrothoffNote Added: 0007044
2013-04-08 11:04Matthias WachsNote Added: 0007045
2013-04-10 11:29Matthias WachsNote Added: 0007046
2013-04-10 11:29Matthias WachsStatusnew => resolved
2013-04-10 11:29Matthias WachsResolutionopen => fixed
2013-04-12 10:42Christian GrothoffAssigned To => Matthias Wachs
2013-04-12 10:42Christian GrothoffProduct Version => Git master
2013-04-12 10:42Christian GrothoffFixed in Version => 0.10.0
2013-04-12 10:42Christian GrothoffTarget Version => 0.10.0
2013-12-24 19:55Christian GrothoffStatusresolved => closed
2024-05-03 12:02Christian GrothoffCategorypeerinfo service => obsolete