Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,10 @@
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-security</artifactId>
</dependency>
<dependency>

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why we need to explicit add this dependency?
anything changed from spring boot 3?
does this work without this spring-secruity-oauth2-core in spring boot 2.x sample?

@moarychan moarychan Nov 23, 2022

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's also a bug in the main branch, which will fix in the next PR.
The class org.springframework.security.oauth2.core.AuthorizationGrantType is referred to com.azure.spring.cloud.autoconfigure.aad.properties.AuthorizationClientProperties#authorizationGrantType, this sample scenario will not depend on Security OAuth2 Client dependencies, it's only to demo the com.azure.spring.cloud.autoconfigure.aad.filter.AadAuthenticationFilter.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I remember per our discussion, the dependency should be the resource server starter, since the application acts as a resource server.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should think about how we could improve this. This shouldn't be the best practice.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

<groupId>org.springframework.security</groupId>
<artifactId>spring-security-oauth2-core</artifactId>
</dependency>
</dependencies>

</project>
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ angular.module('todoApp')
return $http.get('/api/todolist/' + id);
},
postItem: function (item) {
return $http.post('/api/todolist/', item);
return $http.post('/api/todolist', item);
},
putItem: function (item) {
return $http.put('/api/todolist/', item);
return $http.put('/api/todolist', item);
},
deleteItem: function (id) {
return $http({
Expand Down