go-pfcp icon indicating copy to clipboard operation
go-pfcp copied to clipboard

UserPlaneIPInformation Parsing ErrUnexpectedEOF

Open gmtstephane opened this issue 3 years ago • 0 comments

Hi, I am tryring to parse UserPlane Information from the Setup Association Response provided by Traveling VPP : https://github.com/travelping/upg-vpp

I got this payoad : []uint8 len: 13, cap: 1456, [41,0,192,168,1,120,6,97,99,99,101,115,115]

I do not really understund the condition l< offset-n , since l=n from above, this mean the offset must be 0 in my case. In my opinion, offset+n must be < l in order to remain in the array size.

Parsing works great without this Eof check.

https://github.com/wmnsk/go-pfcp/blob/1f550ddf039396cf3b89ae6f4123ba8534d93efa/ie/user-plane-ip-resource-information.go#L150-L162

Thanks you

gmtstephane avatar Dec 21 '21 15:12 gmtstephane