Files
metasploit-gs/lib/rex/proto/thrift/error.rb
T
2023-09-11 14:37:38 -04:00

22 lines
586 B
Ruby

module Rex::Proto::Thrift::Error
# Base class of Thrift-specific errors.
class ThriftError < Rex::RuntimeError
end
# Raised when trying to parse a frame that is invalid.
class InvalidFrameError < ThriftError
def initialize(msg='Invalid Thrift frame data was received and could not be parsed.')
super(msg)
end
end
# Raised when an unexpected reply is received.
class UnexpectedReplyError < ThriftError
attr_reader :reply
def initialize(reply, msg='An unexpected Thrift reply was received.')
@reply = reply
super(msg)
end
end
end