Problem: stream_engine.cpp security can be downgraded

Solution: accept only the mechanism defined by the socket options.

I've not tested this yet, so it's a speculative fix.