Keycloak - Identity and Access Management for Modern Applications: Harness the power of Keycloak, OpenID Connect, and OAuth 2.0 to secure applications
, Second Edition
A beginners’ guide to Keycloak focussed on understanding Identity and Access Management
Implement authentication and authorization in applications using Keycloak 22
Utilize Keycloak in securing applications developed by you and the existing applications in your enterprise
Description
The second edition of Keycloak - Identity and Access Management for Modern Applications is an updated, comprehensive introduction to Keycloak and its updates.
In this new edition, you will learn how to use the latest distribution of Keycloak. The recent versions of Keycloak are now based on Quarkus, which brings a new and improved user experience and a new admin console with a higher focus on usability. You will see how to leverage Spring Security, instead of the Keycloak Spring adapter while using Keycloak 22. As you progress, you’ll understand the new Keycloak distribution and explore best practices in using OAuth. Finally, you'll cover general best practices and other information on how to protect your applications.
By the end of this new edition, you’ll have learned how to install and manage the latest version of Keycloak to secure new and existing applications using the latest features.
Who is this book for?
This book is for developers, sysadmins, security engineers, or anyone who wants to leverage Keycloak and its capabilities for application security. Basic knowledge of app development, authentication, and authorization is expected.
What you will learn
Understand how to install, configure, and manage the latest version of Keycloak
Discover how to obtain access tokens through OAuth 2.0
Utilize a reverse proxy to secure an application implemented in any programming language or framework
Safely manage Keycloak in a production environment
Secure different types of applications, including web, mobile, and native applications
Discover the frameworks and third-party libraries that can expand Keycloak
This book provides a thorough understanding of Keycloak, OAuth 2.0, and OpenID Connect (OIDC), delving into the intricacies of each concept and their practical applications. The author employs a practical approach by developing a simple web application to illustrate the implementation of Keycloak's OAuth protocol. Every endpoint and token is meticulously examined, ensuring that readers gain a solid foundation in authentication and authorization mechanisms.
Feefo Verified review
Anil SaldanhaDec 15, 2023
5
Keycloak is a very important open source IAM software developed by passionate developers at RedHat. This project has been developed over many years with great community feedback. One limitation with the software has been rectified with the first edition (limitation was there were no books written about it).Keycloak is an excellent solution for DIY version of Okta, Microsoft Azure AD, AWS Cognito etc where you have full control over costs, features and deployment.This book is an excellent addition to your personal library of technical books. If you use Keycloak (either the open source version or RedHat SSO), you should have a copy of this book (and future revisions).IAM is a complicated subject. There are a plethora of standards, technologies and configuration. Since it is an integral part of security and doorway to your applications, it is extremely important to understand the theory and configuration associated with Keycloak.At a high level, I deeply appreciate the authors placing topics of Keycloak in separate sections namely Installation, Application Security, Application Integration, Configuration etc. This is handy when you need to quickly refer to the book.My personal favorite chapter is 13 where the authors describe mechanisms to extend Keycloak. In the field, I have had difficulties over the years getting to understand the methods to write Keycloak custom providers for authentication with third party security systems as well as Keycloak limitations such as the SAML attribute profile.Majority of production administrators will appreciate chapters 9, 10,11 and 12.Chapter 8 tackles the difficult subject of Authorization. Coverage is given to RBAC, GBAC and ABAC. This chapter is critical for developers.I do not see sections dedicated to Keycloak in various cloud systems (primarily AWS). I understand that this is tricky because cloud installations are changing and content can get dated. I hope the authors can online references to supplements covering cloud based deployments. Using Quarkus as the base provides opportunities for cloud based deployments.Chapter 4 is brilliant where the authors describe OpenID Connect based authentication. This is important for modern applications.
Amazon Verified review
SRPSep 03, 2023
5
I have a keen interest in all things Zero Trust, and as you might appreciate, Identity, Authentication and Authorization are some of the core tenets of Zero Trust.For those new to IAM or who have yet to come across Keycloak, Keycloak is an open-source Identity and Access Management (IAM) tool; the Keycloak project will be 10 years "young" in 2024!The book was very straightforward to follow, and the generous servings of assessments and practical examples throughout the book helped me reinforce the learnings of the various topics.The first couple of chapters will help you get a deeper understanding of Keycloack and will help you get started with deploying Keycloak and getting ready to begin securing your applications. The authors have made the deployment job very easy by providing concise instructions for deploying Keycloak on Docker.The following block of chapters (esp. 3 - 8) covers essential standards (and integration of) OAuth 2.0 for Authorization), OpenID Connect (for Authentication), JSON Web Tokens (JWT), and Security Assertion Markup Language 2.0 (SAML 2.0) with Keycloak. I was pleased to see each chapter's depth on these topics; I am sure that someone who is interested or is a practitioner of IAM will find value in the way standards and the integration aspects have been covered.The remainder of the book is about getting your Keyclock production-ready with clear steps on hardening, integrating, managing and maintaining the Keycloak deployment.Overall, it is a fantastic book; it deserves 5 of 5!
Amazon Verified review
Dr Ram Kumar GJan 10, 2024
5
Recently, I had the opportunity to read the book "𝗞𝗲𝘆𝗰𝗹𝗼𝗮𝗸 - 𝗜𝗱𝗲𝗻𝘁𝗶𝘁𝘆 𝗮𝗻𝗱 𝗔𝗰𝗰𝗲𝘀𝘀 𝗠𝗮𝗻𝗮𝗴𝗲𝗺𝗲𝗻𝘁 𝗳𝗼𝗿 𝗠𝗼𝗱𝗲𝗿𝗻 𝗔𝗽𝗽𝗹𝗶𝗰𝗮𝘁𝗶𝗼𝗻𝘀" authored by Stian Thorgersen & Pedro Igor Craveiro e Silva published by Packt.This book is an essential guide to learn about hashtag#Keycloak which is an open source identity and access management solution. Written in an easy to follow language with apt diagrams, this book covers the finer aspects of Keycloak solution with practical guidance.The authors have provided an in-depth and comprehensive coverage of the different aspects of Keycloak solution implementation. The chapters take you on a progressive journey to impart knowledge on the technical interface between Keycloak, Open ID Connect & OAuth 2.0 protocols to secure applications with detailed chapters on application integration with Keycloak, managing & authenticating users, authorization strategies, managing tokens & sessions and configuring & security Keycloak.With step by step instructions and easy to relate real world scenarios, I find the book to be an easy read for anyone wanting to learn about Keycloak solution and each of the chapter ends with set of questions for the reader to answer. The solutions are provided towards the end of the book which is easy to understand.I strongly recommend this book for all those IT & cyber security IAM enthusiasts aspiring to learn about Keycloak solution implementation.
Amazon Verified review
D.MillsJul 31, 2023
5
If you are new to Keycloak, this book is a must-have. Keycloak is an open-source Identity and Access Management tool that secures modern applications such as single-page applications, mobile applications, and REST APIs. The authors provide a theoretical overview of Keycloak from start to finish. This book helps you get up to speed, from installing and running keycloak in the admin console to securing Keycloak and applications. The authors make it easy to follow with the step-by-step instructions in each chapter and screenshots of how the GUI should look while you follow along. To ensure you understand each chapter and concept, the authors have end-of-the-chapter questions to ensure you know the key concepts. At the end of some chapters, the authors have further reading so the reader can follow the URL links for more information on the topics covered in the chapters. This was helpful when I got to Chapter 8, Authorization Strategies. Being in the IAM space, it's only so much you can fit into one chapter regarding the different authorization protocols and strategies. This book gives you strategies for securing internal and external application types. The authors also have a chapter showing step-by-step instructions on integrating Keycloak in a Productions environment and tests you can run for load balancing, failover, and frontend and backchannel URLs. When it comes to Keycloak, I highly recommend this book for any IAM/Security Engineer looking to implement this tool in their environment.
Stian Thorgersen started his career at Arjuna Technologies building a cloud federation platform, years before most companies were even ready for a single-vendor public cloud. He later joined Red Hat, looking for ways to make developers' lives easier, which is where the idea of Keycloak started. In 2013, Stian co-founded the Keycloak project with another developer at Red Hat. Today, Stian is the Keycloak project lead and is also the top contributor to the project. He is still employed by Red Hat as a senior principal software engineer focusing on identity and access management, both for Red Hat and for Red Hat's customers. In his spare time, there is nothing Stian likes more than throwing his bike down the mountains of Norway.
Pedro Igor Silva is a proud dad of amazing girls. He started his career back in 2000 at an ISP, where he had his first experiences with open source projects such as FreeBSD and Linux, as well as a Java and J2EE software engineer. Since then, he has worked in different IT companies as a system engineer, system architect, and consultant. Today, Pedro Igor is a principal software engineer at Red Hat and one of the core developers of Keycloak. His main area of interest and study is now IT security, specifically in the application security and identity and access management spaces. In his non-working hours, he takes care of his planted aquariums.
Economy: Delivery to most addresses in the US within 10-15 business days
Premium: Trackable Delivery to most addresses in the US within 3-8 business days
UK:
Economy: Delivery to most addresses in the U.K. within 7-9 business days. Shipments are not trackable
Premium: Trackable delivery to most addresses in the U.K. within 3-4 business days! Add one extra business day for deliveries to Northern Ireland and Scottish Highlands and islands
EU:
Premium: Trackable delivery to most EU destinations within 4-9 business days.
Australia:
Economy: Can deliver to P. O. Boxes and private residences. Trackable service with delivery to addresses in Australia only. Delivery time ranges from 7-9 business days for VIC and 8-10 business days for Interstate metro Delivery time is up to 15 business days for remote areas of WA, NT & QLD.
Premium: Delivery to addresses in Australia only Trackable delivery to most P. O. Boxes and private residences in Australia within 4-5 days based on the distance to a destination following dispatch.
India:
Premium: Delivery to most Indian addresses within 5-6 business days
Rest of the World:
Premium: Countries in the American continent: Trackable delivery to most countries within 4-7 business days
Asia:
Premium: Delivery to most Asian addresses within 5-9 business days
Disclaimer: All orders received before 5 PM U.K time would start printing from the next business day. So the estimated delivery times start from the next day as well. Orders received after 5 PM U.K time (in our internal systems) on a business day or anytime on the weekend will begin printing the second to next business day. For example, an order placed at 11 AM today will begin printing tomorrow, whereas an order placed at 9 PM tonight will begin printing the day after tomorrow.
Unfortunately, due to several restrictions, we are unable to ship to the following countries:
Afghanistan
American Samoa
Belarus
Brunei Darussalam
Central African Republic
The Democratic Republic of Congo
Eritrea
Guinea-bissau
Iran
Lebanon
Libiya Arab Jamahriya
Somalia
Sudan
Russian Federation
Syrian Arab Republic
Ukraine
Venezuela
What is custom duty/charge?
Customs duty are charges levied on goods when they cross international borders. It is a tax that is imposed on imported goods. These duties are charged by special authorities and bodies created by local governments and are meant to protect local industries, economies, and businesses.
Do I have to pay customs charges for the print book order?
The orders shipped to the countries that are listed under EU27 will not bear custom charges. They are paid by Packt as part of the order.
A custom duty or localized taxes may be applicable on the shipment and would be charged by the recipient country outside of the EU27 which should be paid by the customer and these duties are not included in the shipping charges been charged on the order.
How do I know my custom duty charges?
The amount of duty payable varies greatly depending on the imported goods, the country of origin and several other factors like the total invoice amount or dimensions like weight, and other such criteria applicable in your country.
For example:
If you live in Mexico, and the declared value of your ordered items is over $ 50, for you to receive a package, you will have to pay additional import tax of 19% which will be $ 9.50 to the courier service.
Whereas if you live in Turkey, and the declared value of your ordered items is over € 22, for you to receive a package, you will have to pay additional import tax of 18% which will be € 3.96 to the courier service.
How can I cancel my order?
Cancellation Policy for Published Printed Books:
You can cancel any order within 1 hour of placing the order. Simply contact customercare@packt.com with your order details or payment transaction id. If your order has already started the shipment process, we will do our best to stop it. However, if it is already on the way to you then when you receive it, you can contact us at customercare@packt.com using the returns and refund process.
Please understand that Packt Publishing cannot provide refunds or cancel any order except for the cases described in our Return Policy (i.e. Packt Publishing agrees to replace your printed book because it arrives damaged or material defect in book), Packt Publishing will not accept returns.
What is your returns and refunds policy?
Return Policy:
We want you to be happy with your purchase from Packtpub.com. We will not hassle you with returning print books to us. If the print book you receive from us is incorrect, damaged, doesn't work or is unacceptably late, please contact Customer Relations Team on customercare@packt.com with the order number and issue details as explained below:
If you ordered (eBook, Video or Print Book) incorrectly or accidentally, please contact Customer Relations Team on customercare@packt.com within one hour of placing the order and we will replace/refund you the item cost.
Sadly, if your eBook or Video file is faulty or a fault occurs during the eBook or Video being made available to you, i.e. during download then you should contact Customer Relations Team within 14 days of purchase on customercare@packt.com who will be able to resolve this issue for you.
You will have a choice of replacement or refund of the problem items.(damaged, defective or incorrect)
Once Customer Care Team confirms that you will be refunded, you should receive the refund within 10 to 12 working days.
If you are only requesting a refund of one book from a multiple order, then we will refund you the appropriate single item.
Where the items were shipped under a free shipping offer, there will be no shipping costs to refund.
On the off chance your printed book arrives damaged, with book material defect, contact our Customer Relation Team on customercare@packt.com within 14 days of receipt of the book with appropriate evidence of damage and we will work with you to secure a replacement copy, if necessary. Please note that each printed book you order from us is individually made by Packt's professional book-printing partner which is on a print-on-demand basis.
What tax is charged?
Currently, no tax is charged on the purchase of any print book (subject to change based on the laws and regulations). A localized VAT fee is charged only to our European and UK customers on eBooks, Video and subscriptions that they buy. GST is charged to Indian customers for eBooks and video purchases.
What payment methods can I use?
You can pay with the following card types:
Visa Debit
Visa Credit
MasterCard
PayPal
What is the delivery time and cost of print books?
Shipping Details
USA:
'
Economy: Delivery to most addresses in the US within 10-15 business days
Premium: Trackable Delivery to most addresses in the US within 3-8 business days
UK:
Economy: Delivery to most addresses in the U.K. within 7-9 business days. Shipments are not trackable
Premium: Trackable delivery to most addresses in the U.K. within 3-4 business days! Add one extra business day for deliveries to Northern Ireland and Scottish Highlands and islands
EU:
Premium: Trackable delivery to most EU destinations within 4-9 business days.
Australia:
Economy: Can deliver to P. O. Boxes and private residences. Trackable service with delivery to addresses in Australia only. Delivery time ranges from 7-9 business days for VIC and 8-10 business days for Interstate metro Delivery time is up to 15 business days for remote areas of WA, NT & QLD.
Premium: Delivery to addresses in Australia only Trackable delivery to most P. O. Boxes and private residences in Australia within 4-5 days based on the distance to a destination following dispatch.
India:
Premium: Delivery to most Indian addresses within 5-6 business days
Rest of the World:
Premium: Countries in the American continent: Trackable delivery to most countries within 4-7 business days
Asia:
Premium: Delivery to most Asian addresses within 5-9 business days
Disclaimer: All orders received before 5 PM U.K time would start printing from the next business day. So the estimated delivery times start from the next day as well. Orders received after 5 PM U.K time (in our internal systems) on a business day or anytime on the weekend will begin printing the second to next business day. For example, an order placed at 11 AM today will begin printing tomorrow, whereas an order placed at 9 PM tonight will begin printing the day after tomorrow.
Unfortunately, due to several restrictions, we are unable to ship to the following countries: