(self)
return found
Checks if frida is running
Checks if frida is running
Checks if frida is running
def is_frida_running(self):
        """ Checks if frida is running
        """
        if not self.available():
            return False

        found = False
        pid = None

        if self._have_pidof:
            if self._alternate_frida_name:
                pid = self.su_cmd('pidof -s frida-server')
            else:
                pid = self.su_cmd('pidof -s frida')
            if pid:
                try:
                    pid = int(pid.join(pid.split()))  # remove \r\n
                    if pid:
                        return True
                except ValueError:
                    # no integer
                    pass

        if self._oreo_plus:
            result = self.su_cmd('ps -A | grep frida')
        else:
            result = self.su_cmd('ps | grep frida')

        if result:
            result = result.split()

            if 'frida' or 'frida-server' in result:
                found = True

        return found
def is_frida_running ( self ) : if not self . available ( ) : return False found = False pid = None if self . _have_pidof : if self . _alternate_frida_name : pid = self . su_cmd ( 'pidof -s frida-server' ) else : pid = self . su_cmd ( 'pidof -s frida' ) if pid : try : pid = int ( pid . join ( pid . split ( ) ) ) # remove \r\n if pid : return True except ValueError : # no integer pass if self . _oreo_plus : result = self . su_cmd ( 'ps -A | grep frida' ) else : result = self . su_cmd ( 'ps | grep frida' ) if result : result = result . split ( ) if 'frida' or 'frida-server' in result : found = True return found