{"action":"opened","issue":{"url":"https://api.github.com/repos/jlouis/curve_tun/issues/1","labels_url":"https://api.github.com/repos/jlouis/curve_tun/issues/1/labels{/name}","comments_url":"https://api.github.com/repos/jlouis/curve_tun/issues/1/comments","events_url":"https://api.github.com/repos/jlouis/curve_tun/issues/1/events","html_url":"https://github.com/jlouis/curve_tun/issues/1","id":58981693,"number":1,"title":"Server does not verify nounces","user":{"login":"krestenkrab","id":137385,"avatar_url":"https://avatars.githubusercontent.com/u/137385?v=3","gravatar_id":"","url":"https://api.github.com/users/krestenkrab","html_url":"https://github.com/krestenkrab","followers_url":"https://api.github.com/users/krestenkrab/followers","following_url":"https://api.github.com/users/krestenkrab/following{/other_user}","gists_url":"https://api.github.com/users/krestenkrab/gists{/gist_id}","starred_url":"https://api.github.com/users/krestenkrab/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/krestenkrab/subscriptions","organizations_url":"https://api.github.com/users/krestenkrab/orgs","repos_url":"https://api.github.com/users/krestenkrab/repos","events_url":"https://api.github.com/users/krestenkrab/events{/privacy}","received_events_url":"https://api.github.com/users/krestenkrab/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-02-25T22:38:13Z","updated_at":"2015-02-25T22:38:13Z","closed_at":null,"body":"CurveZMQ requires that the server validate that message nounces are increasing by one for each individual message. Perhaps it would be a good idea to do the same here.  I pressume that this guards agains replay attack, as well as ensures against lost messages; it also ensures that client that might expose their keys indirectly by reusing nounces would be declined connectivity.\r\n\r\nI'd suggest that some initial counter is established in the initial exchange, and then going forward these are required to be increasing by 1 for each successive message, perhaps modulus the counter size so that the initial value can be any random number in the range."}}