UPDATE 
  cscart_lock_keys 
SET 
  expiry_at = UNIX_TIMESTAMP(NOW()) + 30, 
  token = 'Bre7PGkkzlepBYjuW/AYr/icPpu4pYA4ekWh0kKgkCE=' 
WHERE 
  key_id = 'fc5c1d608bf1575cab3843dccb5ac5a84cf3edac9577595d7a2e3f9c054fd9df' 
  AND (
    token = 'Bre7PGkkzlepBYjuW/AYr/icPpu4pYA4ekWh0kKgkCE=' 
    OR expiry_at <= UNIX_TIMESTAMP(NOW())
  )

Query time 0.00028