<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def unlock_key(self, data):
 """ Access code to allow re-programming of your YubiKey. Supply data as either a raw bytestring, or a hexlified bytestring prefixed by 'h:'. The result, after any hex decoding, must be 6 bytes. """

        if data.startswith(b'h:'):
            new = binascii.unhexlify(data[2:])
        else:
            new = data
        if len(new) == 6:
            self.unlock_code = new
            if not self.access_code:
                # Don't reset the access code when programming, unless that seems
                # to be the intent of the calling program.
                self.access_code = new
        else:
            raise yubico_exception.InputError('Unlock key must be exactly 6 bytes')