question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[QUERY] How to fix 403 error when Azure AD redirects after a successful authentication to my Spring Boot App?

See original GitHub issue

Query/Question How to fix 403 error when Azure AD redirects after a successful authentication to my Spring Boot App? I had to disable CSRF on Spring Security to fix this. Please, see the code below. However, my app is going to production, and I would like to deploy it with CSRF enabled.

@Configuration
public class SecurityConfiguration extends AadWebSecurityConfigurerAdapter {


    @Override
    protected void configure(HttpSecurity http) throws Exception {
        super.configure(http);
        http.csrf().disable().authorizeRequests().antMatchers("/**").permitAll();

Why is this not a Bug or a feature Request? It is a question in order to explain how to fix some scenario.

Setup (please complete the following information if applicable):

  • OS: Linux
  • IDE: IntelliJ
  • Library/Libraries: com.azure.spring:spring-cloud-azure-starter-active-directory:4.3.0

Information Checklist Kindly make sure that you have added all the following information above and checkoff the required fields otherwise we will treat the issuer as an incomplete report

  • Query Added
  • Setup information Added

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:13 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
joshfreecommented, Aug 10, 2022

Hi @bergmp thanks for reaching out to us via this GitHub issue. @yiliuTo could you help route @bergmp’s question?

0reactions
msftbot[bot]commented, Sep 23, 2022

Hi, we’re sending this friendly reminder because we haven’t heard back from you in a while. We need more information about this issue to help address it. Please be sure to give us your input within the next 7 days. If we don’t hear back from you within 14 days of this comment the issue will be automatically closed. Thank you!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Troubleshoot Azure Digital Twins: Error 403 (Forbidden)
The first solution is to verify that your Azure user has the Azure Digital Twins Data Owner role on the instance you're trying...
Read more >
Azure AD redirected to /login?error when pressing back button ...
1 Answer 1 · Make sure that the redirect URL set in the app registration matches exactly what you have configured in the...
Read more >
Tutorial | Spring Security and Angular
In this tutorial we show some nice features of Spring Security, Spring Boot and Angular working together to provide a pleasant and secure...
Read more >
403 Forbidden Error: What It Is and How to Fix It - Airbrake Blog
If the application you're using has some form of user authentication, the last client-side step to try is to log out and then...
Read more >
[Solved]-Spring Security with LDAP - error after login-Springboot
[Solved]-Spring Security with LDAP - error after login-Springboot. Search. score:1. Had the same issue - Your LDAP server needs bind authentication.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found