예제 #1
0
    def vnc_authentication(self, challenge):
        # Take in 16 bytes, encrypt with 3DES using the password as the key,
        # and send the response.

        response = generate_response(self.password, challenge)
        self.transport.write(response)

        return self.security_result, 4
예제 #2
0
    def vnc_authentication(self, challenge):
        # Take in 16 bytes, encrypt with 3DES using the password as the key,
        # and send the response.

        response = generate_response(self.password, challenge)
        self.transport.write(response)

        return self.security_result, 4
예제 #3
0
def check_password(challenge, response, password):
    password = password.ljust(8, "\x00")[:8]
    return generate_response(password, challenge) == response
예제 #4
0
def check_password(challenge, response, password):
    password = password.ljust(8, "\x00")[:8]
    return generate_response(password, challenge) == response