{"action":"created","issue":{"url":"https://api.github.com/repos/litecoin-association/LoafWallet/issues/2","labels_url":"https://api.github.com/repos/litecoin-association/LoafWallet/issues/2/labels{/name}","comments_url":"https://api.github.com/repos/litecoin-association/LoafWallet/issues/2/comments","events_url":"https://api.github.com/repos/litecoin-association/LoafWallet/issues/2/events","html_url":"https://github.com/litecoin-association/LoafWallet/pull/2","id":123301671,"number":2,"title":"Fix BRMerkleBlock's isValid for litecoin","user":{"login":"peritus","id":11022,"avatar_url":"https://avatars.githubusercontent.com/u/11022?v=3","gravatar_id":"","url":"https://api.github.com/users/peritus","html_url":"https://github.com/peritus","followers_url":"https://api.github.com/users/peritus/followers","following_url":"https://api.github.com/users/peritus/following{/other_user}","gists_url":"https://api.github.com/users/peritus/gists{/gist_id}","starred_url":"https://api.github.com/users/peritus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/peritus/subscriptions","organizations_url":"https://api.github.com/users/peritus/orgs","repos_url":"https://api.github.com/users/peritus/repos","events_url":"https://api.github.com/users/peritus/events{/privacy}","received_events_url":"https://api.github.com/users/peritus/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-12-21T15:45:04Z","updated_at":"2015-12-21T17:12:05Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/litecoin-association/LoafWallet/pulls/2","html_url":"https://github.com/litecoin-association/LoafWallet/pull/2","diff_url":"https://github.com/litecoin-association/LoafWallet/pull/2.diff","patch_url":"https://github.com/litecoin-association/LoafWallet/pull/2.patch"},"body":"This implements POW check for litecoin, which caused the \"invalid block header\" messages."},"comment":{"url":"https://api.github.com/repos/litecoin-association/LoafWallet/issues/comments/166362548","html_url":"https://github.com/litecoin-association/LoafWallet/pull/2#issuecomment-166362548","issue_url":"https://api.github.com/repos/litecoin-association/LoafWallet/issues/2","id":166362548,"user":{"login":"voisine","id":316879,"avatar_url":"https://avatars.githubusercontent.com/u/316879?v=3","gravatar_id":"","url":"https://api.github.com/users/voisine","html_url":"https://github.com/voisine","followers_url":"https://api.github.com/users/voisine/followers","following_url":"https://api.github.com/users/voisine/following{/other_user}","gists_url":"https://api.github.com/users/voisine/gists{/gist_id}","starred_url":"https://api.github.com/users/voisine/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/voisine/subscriptions","organizations_url":"https://api.github.com/users/voisine/orgs","repos_url":"https://api.github.com/users/voisine/repos","events_url":"https://api.github.com/users/voisine/events{/privacy}","received_events_url":"https://api.github.com/users/voisine/received_events","type":"User","site_admin":false},"created_at":"2015-12-21T17:12:05Z","updated_at":"2015-12-21T17:12:05Z","body":"If I might make a recommendation, it's always good practice to parse and re-serialize any input received from an untrusted source. This is why we reconstruct the block header and hash that to get _blockHash rather than just hashing the first 80bytes of the received message. I recommend you calculate _powHash with: _powHash = d.SCRYPT;\r\n\r\n"}}