fixed matchrules option, added protection from incomming message for unsupported methods, more typechecking of incomming and outgoing messages