Remove SideShift privateKey from env config#6024
Conversation
|
Verification note (testing followup, no code change) Confirmed this change is safe: removing the SideShift Direct SideShift API check from the test host, with and without the old secret header, returned identical results:
The plugin already guards the header with A real in-app SideShift swap could not be driven to the success scene from this test slot because SideShift hard-blocks shift creation from US IPs (createShift:false; the ACCESS_DENIED page lists the United States as a blocked country). This is a US geo-restriction independent of this change, not a regression. The app was built from this branch (with privateKey absent from env.json) and drove a live BTC->ETH swap quote with the confirm slider, so the swap flow itself is functional with the change. |
b6d5245 to
891310e
Compare
The SideShift affiliate account was compromised. SideShift confirmed the swap integration works identically without the privateKey, so stop validating and injecting it (it was sent as the x-sideshift-secret header). Account rotation to a new affiliateId is handled operationally.
891310e to
aefe0fc
Compare





CHANGELOG
Does this branch warrant an entry to the CHANGELOG?
Dependencies
noneDescription
SideShift hack followup. The SideShift affiliate account was compromised, so we
stop sending the affiliate secret. This removes the
privateKeyfield that wasadded to
SIDESHIFT_INITin env config by #5369. The SideShift swap pluginsends that value as the
x-sideshift-secretheader; with the field gone theheader is omitted. SideShift confirmed the integration works identically without
it (the
affiliateIdquery param is what tracks affiliate commission). Rotatingto a new affiliate account/
affiliateIdand removing the secret from theproduction env are handled operationally, outside this repo.
Asana: https://app.asana.com/0/1215088146871429/1214800712844381
Verification.
tsc --noEmitandverify-repo(eslint + jest) pass.My Bitcoin0.00023481 (USD 14.99) to SOLMy Solana0.20594, "Powered by SideShift.ai". Slid to confirm and reached the "Congratulations! Your exchange is being processed!" success scene; the BTC spend is recorded as anExchange: To SOLtransaction. The plugin issued the shift-creation request with nox-sideshift-secretheader and the swap still created and broadcast, confirming the integration works without theprivateKey. See the attached screenshots (quote, success scene, transaction details).confirmSliderThumbtestID was added to the shared confirm slider so the maestro swap flow can drive it (test infrastructure, separate commit).Requirements
If you have made any visual changes to the GUI. Make sure you have:
Note
Medium Risk
Touches live SideShift swap configuration after a compromised affiliate secret, though behavior without the header was verified end-to-end; misconfigured env could still affect affiliate attribution.
Overview
Removes the SideShift
privateKeyfromSIDESHIFT_INITin env config (and drops.withReston that object), so productionenv.jsoncan no longer supply the affiliate secret that the swap plugin would send asx-sideshift-secret.affiliateIdremains the only configured SideShift affiliate field; commission tracking is expected to work via the affiliate id alone.Also adds
testID="confirmSliderThumb"on the shared confirm slider thumb inSafeSlider(snapshot test updates only) to support Maestro swap flows.Reviewed by Cursor Bugbot for commit aefe0fc. Bugbot is set up for automated code reviews on this repo. Configure here.