sencode: a little better format of decode

It's not all that pointy anymore.
envelope: correctly return parsed envelope type