Rfc6810 bis

pull request for reviewing code
allocate entry on the stack?