Pages

Thursday, May 26, 2016

ForgeRock OpenAM13 and Social Login Part:1 FaceBook

How to easily configure FaceBook with OpenAM 13

This is a quick guide to setting up FaceBook as social authentication modules for OpenAM 13. Prerequisites are a working OpenAM 13 environment. The other prerequisite is to have a developer account with Facebook.  These will be needed to obtain a clientID and client Secret that you will need to use when you configure the authentication modules.

Obtaining a Facebook ClientID and Secret
Go to developers.facebook.com. You might need to sign up to get access. Once authenticated click on the My Apps button next to your profile picture.


Next click on ‘Add a New App'


Select Website



You will need to enter an App Name as well as the Site URL. Note that an AppID will be assigned as part of the script that is supplied. This AppID will be shows again in next step, so no need to copy it yet. Click Next and continue. Click on the newly created application from the dashboard.



Here you will copy the App ID as well as the App Secret. You will need both of these when configuring FaceBook Authentication Module on OpenAM.

Configuring OpenAM 13

Now login to the OpenAM admin console at http://host:port/openam/console
Select the realm you intend on setting up social authentication module on.

Click on Configure Social Authentication:



Click on Configure FaceBook Authentication



Enter the FaceBook App ID and App Secret and click Create to continue. The Redirect URL is automatically populated.



Once created you will get a success message.



Expanding on the Authentication section and clicking on Modules will show a new ‘FacebookSocialAuthentication’ module. In addition a new Chain is also created using this new module named FaceBookSocialAuthenticationService.



Click on the module to look at some of the default settings.

Note two particular settings:




With these two settings, users who successfully authenticate against FaceBook will have a profile dynamically created in your data store. Your Facebook users will be pre-fixed with the identifier "facebook-“ as shown in the attribute mapper. You can modify it here if you which to remove or change that.

Testing Facebook Authentication

Simplest way to validate the Facebook authentication chain is to update the Authentication settings and make the chain the default Organization Configuration chain.

Test the authentication by going to http://host:port/openam. This should automatically redirect you to the FaceBook authentication.



Facebook will require you to consent to sharing some profile info



Once you are successfully authenticated at FaceBook you will be redirected back to OpenAM, have your profile dynamically created and logged into the console where you see your profile.



Logged in as the OpenAM admin user, if you search under subjects for the new Facebook created ID, you will see which attributes were shared from FaceBook.



And thats pretty much all it takes to setup the FaceBook authentication module for use by OpenAM. Of course you don’t need to set it up as the default Authentication chain used the the realm. It can simply appear as a icon on the login page. You can also access the authentication chain via REST to completely customize your user authentication look and feel.



Via REST using Postman


End

33 comments:

  1. Besides having opportunity to know a lot of people in a fast and easy way, social media also helped teenagers who have social or physical mobility restrictions to build and maintain relationships with their friends and families. new social media site Obama campaign had made 5 million "friends" on more than 15 social networking sites (3 million friends on Facebook itself) and posted nearly 2,000 YouTube videos which were watched over 80 million times.

    ReplyDelete
  2. In spite of the fact that it appears to be anything but difficult to sit for the tests, considering and planning is serious and capabilities to apply are stringent.ExcelR PMP Certification

    ReplyDelete
  3. Wow! Such an amazing and helpful post this is. I really really love it. It's so good and so awesome. I am just amazed. I hope that you continue to do your work like this in the future also first reseller panel

    ReplyDelete
  4. I think this is an informative post and it is very useful and knowledgeable. therefore, I would like to thank you for the efforts you have made in writing this article. piknow

    ReplyDelete
  5. So luck to come across your excellent blog. Your blog brings me a great deal of fun.. Good luck with the site.
    ExcelR pmp certification

    ReplyDelete
  6. Excellent article. Very interesting to read. I really love to read such a nice article. Thanks! keep rocking. see how to access your Hotmail mailbox

    ReplyDelete
  7. This particular papers fabulous, and My spouse and i enjoy each of the perform that you have placed into this. I’m sure that you will be making a really useful place. I has been additionally pleased. Good perform! Technosoups

    ReplyDelete
  8. Thank you for helping people get the information they need about TikTok. Great stuff as usual. Keep up the great work!!! Buy TikTok Likes UK

    ReplyDelete
  9. Thank you for your post, I look for such article along time, today i find it finally. this post give me lots of advise it is very useful for me. TikTok automation bot

    ReplyDelete
  10. I have read all the comments and suggestions posted by the visitors for this article are very fine,We will wait for your next article so only.Thanks! www.thetiktokguide.org

    ReplyDelete
  11. The apparatus additionally gives ongoing post measurements to keep refreshed with connections on social media.play online

    ReplyDelete
  12. So in case I'm selling tires on ebay, #tyres, #cartyres, #car, #tyres is acceptable, and for sports news, #sportsnews, #football #cricket, etc is acceptable. cheapest smm panel


    ReplyDelete
  13. That is really nice to hear. thank you for the update and good luck. Hotmail Login

    ReplyDelete
  14. As a heads up, on Facebook you host to utilize a third-gathering application to have the challenge and can't utilize the 'Offer' button, 'Similar to' fasten or require a remark so as to be entered to win.cheapest smm panel

    ReplyDelete
  15. I am glad you take pride in what you write. This makes you stand way out from many other writers that push poorly written content. buy cheap ig likes

    ReplyDelete
  16. Creating a professional network that could generate business opportunities requires time and discipline. To the uninitiated, mastering your website may appear such as a long, hard climb. Not until the habit of daily use is ingrained are you going to see and truly appreciate the power of LinkedIn as an excellent driver of business growth. Kennected

    ReplyDelete
  17. I am not suggesting that we ignore the fact that 15% of the respondents did indicate that click this over here now they use social networking sites to find out about particular brands or businesses.

    ReplyDelete
  18. PMP Certification Pune
    Great tips and very easy to understand. This will definitely be very useful for me when I get a chance to start my blog.

    ReplyDelete
  19. I wanted to leave a little comment to support you and wish you a good continuation. Wishing you the best of luck for all your blogging efforts.
    Data Analytics course Pune
    I like viewing web sites which comprehend the price of delivering the excellent useful resource free of charge. I truly adored reading your posting. Thank you!

    ReplyDelete
  20. I am genuinely thankful to the holder of this web page who has shared this wonderful paragraph at at this place
    tableau training in Guwahati

    ReplyDelete
  21. PMP Certification Pune
    Great post i must say and thanks for the information. Education is definitely a sticky subject. However, is still among the leading topics of our time. I appreciate your post and look forward to more.

    ReplyDelete
  22. I am constantly surprised by the amount of information accessible on this subject. What you presented was well researched and well written to get your stand on this over to all your readers. Thanks a lot my dear. hotmail login

    ReplyDelete
  23. In this downturned economy, individuals are endeavoring do-it-without anyone else's help activities and you can give the information that they have to finish their work in a cost-proficient and convenient way. get more twitter followers

    ReplyDelete
  24. Asking the right questions before hiring a Social Media manager will ensure you choose wisely and understand how they will benefit your business. Here are 21 questions you can ask a potential social media manage to improve your hiring process. Free TikTok Likes

    ReplyDelete
  25. Finding the right social sites to promote your business to maximise its potential is essential for business success, buy tiktok followers and this is where you should concentrate your efforts.

    ReplyDelete
  26. Customers have started using the social media platform as a point of interaction with a business. Many times, they won't contact the business directly but will go ahead to post an online comment. click over here now

    ReplyDelete
  27. Now using social media to improve the ROI (return on investment) for the above things is something you should be looking at doing. Let's say you spend the $5,000 to display at a local home show, but by luck of the draw end up in a corner behind the local loud mouth realtor and no one comes to see you. youtube likes

    ReplyDelete
  28. Research has shown, however, that e-commerce retailers are reaping the benefits of this new media channel (i.e., offering better customer service and increased sales) so it pays to use it. Trust Pilot Scraper

    ReplyDelete
  29. Attend The Data Analyst Course From ExcelR. Practical Data Analyst Course Sessions With Assured Placement Support From Experienced Faculty. ExcelR Offers The Data Analyst Course.
    Data Analyst Course

    ReplyDelete
  30. Amazing Article ! I would like to thank you for the efforts you had made for writing this awesome article. This article inspired me to read more. keep it up.
    Simple Linear Regression
    Correlation vs covariance
    data science interview questions
    KNN Algorithm
    Logistic Regression explained

    ReplyDelete
  31. Thanks for the blog filled with so many information. Stopping by your blog helped me to get what I was looking for. Now my task has become as easy as ABC. Mark Lutchman

    ReplyDelete
  32. Although many have signed up, however, there is always a question of how to make money with TikTok? And how do influencers and brands make money with TikTok? In this article, we will reveal how to earn and make money on TikTok. TikTok followers from InstaDean.com

    ReplyDelete
  33. Post your stories at a time you know is popular with your users, in order to make the most of the 24-hour cycle. tenocation.com

    ReplyDelete