1 00:00:00,150 --> 00:00:06,180 In the last couple of videos, we have looked at the user detailed interface, which is a contract maintained 2 00:00:06,180 --> 00:00:10,600 by the spring security whenever it tries to deal with the user details. 3 00:00:10,950 --> 00:00:17,520 And at the same time, whenever we want to customize the user schema, our contract, our support requirement, 4 00:00:17,670 --> 00:00:21,030 then we should always implement user details interface. 5 00:00:21,420 --> 00:00:27,060 And at the same time, we also looked at the user data service interface, which have only a single 6 00:00:27,060 --> 00:00:29,160 matter, which will load the user. 7 00:00:29,160 --> 00:00:34,340 Details from the persistent layer of database are held up by using a user name. 8 00:00:34,620 --> 00:00:41,310 But if we have scenarios where your application also has to handle creating, updating, deleting the 9 00:00:41,310 --> 00:00:47,040 user details, then use a detailed service interface will not be enough in altered scenarios. 10 00:00:47,160 --> 00:00:55,710 We should go ahead and implement user details manager interface, which internally extends user details, 11 00:00:55,710 --> 00:00:57,060 service interface as well. 12 00:00:57,210 --> 00:01:04,860 So in this video, let's try to see inside the framework of spring security about the user details manager 13 00:01:04,860 --> 00:01:05,459 interface. 14 00:01:06,720 --> 00:01:14,910 Now we are inside the user details manager interface present inside our spring framework with this package. 15 00:01:14,940 --> 00:01:21,570 Now, as we discussed in the slide, user details manager, extending user details are ways. 16 00:01:21,750 --> 00:01:29,070 That means whatever single method that we have inside user detailed service load user by user name will 17 00:01:29,070 --> 00:01:31,590 also present in this interface. 18 00:01:31,800 --> 00:01:39,060 And who are want to implement this user details manager has to provide a concrete implementation for 19 00:01:39,060 --> 00:01:40,530 all these methods. 20 00:01:40,650 --> 00:01:47,330 Like if I want to have a scenario of create an user, then we will call create user. 21 00:01:47,550 --> 00:01:52,820 And as you can expect, the argument of this method is user details. 22 00:01:52,830 --> 00:01:58,890 So what our input argument that you're sending to this create user update user, it has to follow the 23 00:01:59,040 --> 00:02:03,000 schema provided by user details interface. 24 00:02:03,030 --> 00:02:09,389 Similarly, in the case of updating the user details, we can update user and for deleting user from 25 00:02:09,389 --> 00:02:11,380 your database or relapser. 26 00:02:11,550 --> 00:02:18,810 We should override this method followed by if you have a scenario where you want to allow the user to 27 00:02:18,810 --> 00:02:26,670 change password by themselves, then you can go this method and implement accepting the old password, 28 00:02:26,670 --> 00:02:30,090 a new passport and eventually updating the database. 29 00:02:30,180 --> 00:02:33,740 And lastly, we also have a simple matter, which is user. 30 00:02:34,260 --> 00:02:38,340 Suppose you don't want to load the details of the user. 31 00:02:38,550 --> 00:02:41,090 You just wanted to check if the user. 32 00:02:41,220 --> 00:02:46,560 But I'm going to provide with the user name is present inside my database so far. 33 00:02:46,560 --> 00:02:47,700 Altered scenarios. 34 00:02:47,910 --> 00:02:54,160 You can always implement the method user exist in your custom class. 35 00:02:54,540 --> 00:03:01,650 So this is about user details, manager and how to extend user details services and what type of methods 36 00:03:01,650 --> 00:03:03,780 are available inside this interface. 37 00:03:03,960 --> 00:03:11,010 So it's very clear the very first thing that interplaying security we have to understand is user details, 38 00:03:11,310 --> 00:03:14,520 which holds the schema a blueprint of user. 39 00:03:14,610 --> 00:03:21,720 And then we have user detail services which have only a single method where we can load the user details 40 00:03:21,870 --> 00:03:23,310 by using it user name. 41 00:03:23,490 --> 00:03:30,510 On top of that, we also how user details manager, which will allow you to manage user details like 42 00:03:30,510 --> 00:03:35,390 creating, updating, deleting change password and user check. 43 00:03:35,430 --> 00:03:38,500 So all such things are possible using user details. 44 00:03:38,550 --> 00:03:40,260 Manage the next video. 45 00:03:40,440 --> 00:03:42,100 Let's try and look. 46 00:03:42,120 --> 00:03:48,570 What are the default implementations provided by spring security which extends this user details? 47 00:03:48,570 --> 00:03:56,130 Maneesha, that means we have three famous default implementation of spring security where they ordered 48 00:03:56,130 --> 00:04:02,460 all these methods by extending this user d'états manager to let's try to look into them in detail in 49 00:04:02,460 --> 00:04:03,010 the next week. 50 00:04:03,090 --> 00:04:03,620 Thank you. 51 00:04:03,630 --> 00:04:03,870 By.