user image

Rahul Pandit.
Published in : 2022-03-05

Keycloak db query in source codes [closed]

General

I want to make some changes in the ValidateUsername and AbstractUsernameFormAuthenticator java classes of Keycloak source codes and access the tables of the H2 database of Keycloak.

Suppose I have created a new table in H2 Keycloak's DB (called MyTable) and it consists of 2 column (Username and specific attribute). Now I want to access MyTable in those classes mentioned.

Note 1: I don't want to develop a new SPI to be used instead of these 2 providers. I just want to make some changes on them.

Note 2: I can also use DriverManager.getConnection() and execute my commands using executeQuery but I am searching for a better performance way to access the table. (Since Keycloak is connected to the DB already to perform some functions like user.getId ...)

Comments

There is no comments yet

Leave a comment

Join us

Join our community and get the chance to solve your code issues & share your opinion with us

Sign up Now

Related posts

Difference between frontend and backend user authentication
Publish date: 2022-02-12 | Comments: 2

Tag: General

Convert Stored Procedure of Oracle to SQL Server
Publish date: 2022-03-02 | Comments: 1

Tag: General

Unable to Connect AWS EC2 Instance with my subdirectory through domain registrar.
Publish date: 2022-02-25 | Comments: 2

Tag: General

How do i r etrieve users?
Publish date: 2022-03-04 | Comments: 0

Tag: General

Is it possible to git commit files without adding a message or comments?
Publish date: 2022-03-02 | Comments: 2

Tag: General

git issue, fatal error: your current branch appears to be broken
Publish date: 2022-03-01 | Comments: 2

Tag: General

[solved] Unable to pull updates from git "sudo git pull"
Publish date: 2021-12-20 | Comments: 1

Tag: General