UPDATE 
  cscart_lock_keys 
SET 
  expiry_at = UNIX_TIMESTAMP(NOW()) + 30, 
  token = 'yhg/HBnQFD5Yf4ezCyj48ilK7kI8XEE2EsFfSYguz/o=' 
WHERE 
  key_id = 'df429397a1de60516d54b54b632bf79c0b62753a823c6d4a7261b5630749d4a4' 
  AND (
    token = 'yhg/HBnQFD5Yf4ezCyj48ilK7kI8XEE2EsFfSYguz/o=' 
    OR expiry_at <= UNIX_TIMESTAMP(NOW())
  )

Query time 0.00068