Esempio n. 1
0
 def findCipherCtx(self, maxNum=3):
   ''' '''
   outs=haystack.findStruct(self.pid, ctypes_openssl.EVP_CIPHER_CTX, maxNum=maxNum)
   if outs is None:
     log.error("The session_state has not been found. maybe it's not OpenSSH ?")
     return None,None
   #
   return outs
Esempio n. 2
0
 def findActiveSession(self, maxNum=1):
   ''' '''
   outs=haystack.findStruct(self.pid, ctypes_openssh.session_state, debug=False)
   if outs is None:
     log.error("The session_state has not been found. maybe it's not OpenSSH ?")
     return None,None
   elif len(outs) > 1:
     log.warning("Mmmh, we found multiple session_state(%d). That is odd. I'll try with the first one."%(len(outs)))
   #
   session_state,addr=outs[0]
   return session_state, addr
Esempio n. 3
0
 def findCipherCtx(self, maxNum=3):
     ''' '''
     outs = haystack.findStruct(self.pid,
                                ctypes_openssl.EVP_CIPHER_CTX,
                                maxNum=maxNum)
     if outs is None:
         log.error(
             "The session_state has not been found. maybe it's not OpenSSH ?"
         )
         return None, None
     #
     return outs