• Jose Cunha
  • NEWBIE
  • 0 Points
  • Member since 2018

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 2
    Questions
  • 2
    Replies
Hi all,

I'm wondering if there's any way to obtain Guest User's IP Address within an @AuraEnabled method called by a LWC sitting on a Community.

I tried different approaches and they all failed short, let me please tell you why:

- ApexPages.currentPage().getHeaders(): It has only to do with VisualForce pages, which is not the case.

- Auth.SessionManagement.getCurrentSession(): It raises exception due to the fact that Guest users do not have sessions.

- Any sort of JS only solutions (e.g. https://api.ipify.org/): The idea behind this solution is to make a request to an external server, which is responsible to return client's ip. Then call any @AuraEnabled method to inform what IP was. Well, this seems too brittle to me. First because it introduces another point of failure (let's assume the external server is down - difficult but not impossible), second because it's to easy to dodge the second request with any arbitrary IP.

Is there any other solution I might be missing?

Thanks,
Jose
We have an existing community that relies on an external IdP for SSO.
We wanted to spin up another community that cannot share the same IdP just for now.
I was wondering if this new community can have their users authenticated against the internal customer user base (they won't be that many for now), then later we change to the existing Idp.
There's of course a requirement to do not impact the existing community whatsoever.

Thanks
Hello,

I'm facing an issue with the SuperBadge "App Customization Specialist"

I'm trying to check my Report challenge but I get this error message : User-added image

And this is how i've created it : 

User-added image

Do you have any idea ? 

Thanks,
Guillaume
Hi Team,

I'm encountering an error while following the Gus at Work module. I'm being prompted to log in to AppExchange when trying to install Agile Accelerator. However, the authentication page leads to a "URL no longer exists" error

User-added image

User-added image

User-added image