I have a project created with Spring Security and Spring MVC, and I have a url in the following way:
universidad/acceso/infoNotas?idEstudiante=20
It turns out that when defining access to the URL, it is defined for the role of teacher in the following way:
.antMatchers("/acceso/**").access("hasRole('ROLE_DOCENTE')")
But each teacher has a list of courses to which he can access and should only see the students' grades for the courses he or she dictates; If I copy the URL from the work area of any teacher so this teacher is not linked to the course to which the student belongs whose idEstudiante
is referenced in the URL, you can see your notes, I have the question of how to solve this problem security and I wonder if it has to do with handling sessions and if someone has a clue as to how it should proceed. Thank you very much