{"action":"created","issue":{"url":"https://api.github.com/repos/mirleft/ocaml-nocrypto/issues/67","labels_url":"https://api.github.com/repos/mirleft/ocaml-nocrypto/issues/67/labels{/name}","comments_url":"https://api.github.com/repos/mirleft/ocaml-nocrypto/issues/67/comments","events_url":"https://api.github.com/repos/mirleft/ocaml-nocrypto/issues/67/events","html_url":"https://github.com/mirleft/ocaml-nocrypto/issues/67","id":79972676,"number":67,"title":"Correct way to reseed Fortuna.g","user":{"login":"marklrh","id":3656079,"avatar_url":"https://avatars.githubusercontent.com/u/3656079?v=3","gravatar_id":"","url":"https://api.github.com/users/marklrh","html_url":"https://github.com/marklrh","followers_url":"https://api.github.com/users/marklrh/followers","following_url":"https://api.github.com/users/marklrh/following{/other_user}","gists_url":"https://api.github.com/users/marklrh/gists{/gist_id}","starred_url":"https://api.github.com/users/marklrh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/marklrh/subscriptions","organizations_url":"https://api.github.com/users/marklrh/orgs","repos_url":"https://api.github.com/users/marklrh/repos","events_url":"https://api.github.com/users/marklrh/events{/privacy}","received_events_url":"https://api.github.com/users/marklrh/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-05-23T22:34:18Z","updated_at":"2015-05-27T06:02:48Z","closed_at":null,"body":"Hi,\r\n\r\nI am writing a module that provides nonce during OAuth. [Here](https://github.com/marklrh/otter/blob/master/xen/oauth_mirage.ml#L21) is my implementation so far.\r\n\r\nThe reason I need to remove alpha-numeric is stated in OAuth RFC and is irrelevant here. \r\n\r\nI am not sure if I reseed the prng correct. Is there a more formal way to reseed prng?"},"comment":{"url":"https://api.github.com/repos/mirleft/ocaml-nocrypto/issues/comments/105767806","html_url":"https://github.com/mirleft/ocaml-nocrypto/issues/67#issuecomment-105767806","issue_url":"https://api.github.com/repos/mirleft/ocaml-nocrypto/issues/67","id":105767806,"user":{"login":"hannesm","id":228456,"avatar_url":"https://avatars.githubusercontent.com/u/228456?v=3","gravatar_id":"","url":"https://api.github.com/users/hannesm","html_url":"https://github.com/hannesm","followers_url":"https://api.github.com/users/hannesm/followers","following_url":"https://api.github.com/users/hannesm/following{/other_user}","gists_url":"https://api.github.com/users/hannesm/gists{/gist_id}","starred_url":"https://api.github.com/users/hannesm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hannesm/subscriptions","organizations_url":"https://api.github.com/users/hannesm/orgs","repos_url":"https://api.github.com/users/hannesm/repos","events_url":"https://api.github.com/users/hannesm/events{/privacy}","received_events_url":"https://api.github.com/users/hannesm/received_events","type":"User","site_admin":false},"created_at":"2015-05-27T06:02:48Z","updated_at":"2015-05-27T06:02:48Z","body":"Since mirage-2.5.0 (released only to https://github.com/mirage/mirage-dev so far), the mirage tool emits the runes to seed and hookup the entropy sources - https://github.com/mirage/mirage/blob/master/lib/mirage.ml#L2443\r\n\r\nSince nocrypto-0.4.0, you can use on unix: `Nocrypto_entropy_lwt.initialize ()` (described https://github.com/mirleft/ocaml-nocrypto/blob/master/lwt/nocrypto_entropy_lwt.mli#L10, it will use `/dev/urandom` to periodically refeed during the lwt event loop), on xen `Nocrypto_entropy_xen.initialize ()` (described https://github.com/mirleft/ocaml-nocrypto/blob/master/xen/nocrypto_entropy_xen.mli, it will use various available entropy sources (RDRAND/RDSEED/RTDSC; implemented in https://github.com/mirage/mirage-entropy) and refeed during the main event loop).\r\n\r\nThere is no need to manually create and reseed your Fortuna instance."}}