UPDATE 
  cscart_lock_keys 
SET 
  expiry_at = UNIX_TIMESTAMP(NOW()) + 30, 
  token = 'GhH3BZI4roCkAIVvNqQTXBU4dX8a/zVP9q2kzb2mM3s=' 
WHERE 
  key_id = 'c8d3bc4de9346f80c9756d3a8bdf9371a8a0281e47d3ace4a2f384d0d4a06a24' 
  AND (
    token = 'GhH3BZI4roCkAIVvNqQTXBU4dX8a/zVP9q2kzb2mM3s=' 
    OR expiry_at <= UNIX_TIMESTAMP(NOW())
  )

Query time 0.00021