Stripe Payment Issues: cannot set the keys

Hi all,
I recently set up the Sharestribe 10.3, but when copy and paste public keys and private keys to set up the payment, always showing: they don’t like correct real keys. But Actually they are the right ones I copy/paste from stripe. Any help will be great appreciated.

Here is the screenshot (I remove part of the keys in this screenshot)

Hi,

Are you running Sharetribe in a production rails environment? Make sure you check your config/config.yml and check the stripe_private_key_pattern and stripe_publishable_key_pattern values for the production environment. They should be as follows:

  stripe_private_key_pattern: "\\Ask_live_.{24,200}\\z"
  stripe_publishable_key_pattern: "\\Apk_live_.{24,200}\\z"

The values changed at some earlier release, and perhaps you have old configuration for those. For reference, see the config/config.defaults.yml and adapt your configuration from there.

Also, please rotate your Stripe keys as soon as possible, as you revealed the secret key in the screenshot you posted.

Cheers,
Boyan

Hi Boyan,

It works by following your instructions. Thank you so much for your help.

Zheng