Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SF Inspector with a Connected App in Firefox #137

Closed
kkorynta opened this issue Aug 16, 2023 · 10 comments
Closed

SF Inspector with a Connected App in Firefox #137

kkorynta opened this issue Aug 16, 2023 · 10 comments
Assignees
Labels
bug Something isn't working

Comments

@kkorynta
Copy link

Is your feature request related to a problem? Please describe.
We have API access controls in salesforce where we force users to authenticate through a Connected App. Our Firefox users are unable to authenticate following similar instructions here: https://github.com/tprouvot/Salesforce-Inspector-reloaded/wiki/How-to#use-sf-inspector-with-a-connected-app

Describe the solution you'd like
I'd like for our Firefox users to be able to continue to use their browser of choice.

Describe alternatives you've considered
Alternative is to force them into Chrome.

Additional context
It looks like firefox "extension Ids" are different per user/machine.

@kkorynta kkorynta added the enhancement New feature or request label Aug 16, 2023
@tprouvot
Copy link
Owner

Hi @kkorynta,
I'll check tomorrow if I can make it work with Firefox, could you share the extension Id for you ? I'll compare it to mine tomorrow

@kkorynta
Copy link
Author

kkorynta commented Aug 16, 2023

@tprouvot
When I go to the Data Export tab, this is what appears:
moz-extension://7d3f32d2-10c4-4fc0-a854-8d4e659b4c0a/data-export.html?host=<orgdomain>.my.salesforce.com

One of the users I was testing with had this produced:
moz-extension://85a2a7d4-af97-447d-a195-cadcfa2eb425/data-export.html?host=<orgdomain>.my.salesforce.com

If I hit generate token, I get this interesting URL:

https://<orgdomain>.my.salesforce.com/services/oauth2/authorize?
response_type=token
&client_id=<clientId>
&redirect_uri=
chrome-extension://salesforceinspector@reloaded/data-export.html?host=<orgdomain>.my.salesforce.com%26

@tprouvot
Copy link
Owner

Hi @kkorynta,
I have the same behaviour as yours, the extension id changes depending on the user's installation.

I updated the extension on the firefox store and tried to set an extension id without success.
It looks like we can't have a unique extension id on firefox, I have to explore other options.

And you're right, the redirect url contains "chrome-extension" since the functionality was designed only on chrome so I have to detect browser to build the url.

From now I have no other solution to migrate to chrome.

@tprouvot tprouvot added bug Something isn't working and removed enhancement New feature or request labels Aug 18, 2023
@kkorynta
Copy link
Author

Thank you for taking the time to look into this. I'll keep an eye out if it becomes possible in the future.

@tprouvot
Copy link
Owner

Hi @kkorynta,
I fixed the hardcoded part, which opens a new dirty workaround depending on your team size.

Now the generate token url is fixed, you would be able to create a connected app for each user (since we have different extension id for each install)
What size is your team ?

FYI the fixed is not deployed on the firefox store but can be if this workaround suits your for the moment

@kkorynta
Copy link
Author

kkorynta commented Aug 18, 2023

@tprouvot
The full team is about 15-20 users + folks on the finance side of the house. There's maybe about 5 of them that use Firefox.

With this workaround, could we have multiple callback URLs listed instead of a connected app for each user? That's how I configured the Chrome side of it to work for each of our pipeline environments.

If we could swing that, then that would work. We can just document the Ids for now and then inform them of what happens if they uninstall.

@kkorynta kkorynta reopened this Aug 18, 2023
@tprouvot
Copy link
Owner

Yep that could work 👍
I'll release the new version at the beginning of the week and update related documentation for Firefox if it works !

@kkorynta
Copy link
Author

You're the best. Tyvm!!

@tprouvot
Copy link
Owner

Hey @kkorynta,
I've submitted the new version on firefox store, it should be available during the day ! 🚀

@tprouvot
Copy link
Owner

@kkorynta Extension updated on the store
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants