UPDATE 
  cscart_lock_keys 
SET 
  expiry_at = UNIX_TIMESTAMP(NOW()) + 30, 
  token = '88PM4Hm7W09frnxehVAF/CNFFDzjk3b7GnOZgJC7lEU=' 
WHERE 
  key_id = '1a20802010af1735425373b6271d4bbb41573bc3bb26bd2eb4ca53eabebf10df' 
  AND (
    token = '88PM4Hm7W09frnxehVAF/CNFFDzjk3b7GnOZgJC7lEU=' 
    OR expiry_at <= UNIX_TIMESTAMP(NOW())
  )

Query time 0.00033