1
00:00:00,770 --> 00:00:02,750
Welcome to the final video of the project.

2
00:00:03,170 --> 00:00:07,370
They'll be discussing the final step of security and authentication of our secret speech.

3
00:00:07,790 --> 00:00:12,410
That is, as you can see here, sign up with Google and sign up with Facebook.

4
00:00:12,950 --> 00:00:13,970
So how to do that?

5
00:00:14,480 --> 00:00:15,170
So white.

6
00:00:15,440 --> 00:00:17,120
What what do you mean by what?

7
00:00:17,690 --> 00:00:19,360
Firstly, what do you mean by what?

8
00:00:22,080 --> 00:00:25,260
Or means open authorization.

9
00:00:26,470 --> 00:00:28,420
Open often, I.

10
00:00:29,630 --> 00:00:30,070
Session.

11
00:00:32,890 --> 00:00:35,190
Kindness, yeah, open up tradition.

12
00:00:35,770 --> 00:00:38,800
So it's an open standard for token based authorization.

13
00:00:39,220 --> 00:00:40,360
Why do we need a what?

14
00:00:40,840 --> 00:00:49,180
So basically, we need a lot more granular access levels read, write or read or read plus write access

15
00:00:49,630 --> 00:00:53,740
and revoke access to have doubt for this meaning you can stick them in the Google.

16
00:00:53,740 --> 00:00:55,750
What do you mean by granular access levels?

17
00:00:56,140 --> 00:00:58,060
What do you mean by revoke access and everything?

18
00:00:58,990 --> 00:01:02,800
So first thing we to be doing is we'll set up our app.

19
00:01:03,010 --> 00:01:10,150
That means we have the Secrets app, the social app, right, that will set the social app in their

20
00:01:10,150 --> 00:01:11,020
developer console.

21
00:01:11,380 --> 00:01:15,760
For example, if you're using Google or what Google open authorization, we'll set up our app in their

22
00:01:15,760 --> 00:01:21,610
Google Developer console that using Facebook will be setting up our app and said that Facebook developer

23
00:01:21,610 --> 00:01:26,760
console, if we are doing it up, then we'll be setting it up inside their GitHub console.

24
00:01:27,430 --> 00:01:35,920
So in Britain, we will get App Idea Client daily and we our website is the client which will make their

25
00:01:35,920 --> 00:01:38,290
request to Facebook to authenticate our use it.

26
00:01:38,920 --> 00:01:44,520
So once users sign in with Google or Facebook in Britain, we get the authentication code from Google

27
00:01:44,520 --> 00:01:45,100
or Facebook.

28
00:01:46,000 --> 00:01:48,940
We can exchange our code with access.

29
00:01:48,940 --> 00:01:53,720
Token for access token is basically valid for a lot longer than the authentication code.

30
00:01:54,700 --> 00:01:55,060
OK.

31
00:01:56,370 --> 00:02:01,900
So we'll be implementing logging with Google, using a passport and Google log, so that if you see

32
00:02:01,900 --> 00:02:04,770
a passport, the phone.

33
00:02:07,070 --> 00:02:13,430
Can search for strategies here, you can find Google or tried Google.

34
00:02:14,630 --> 00:02:16,740
Basically one or two points.

35
00:02:17,750 --> 00:02:21,830
So yeah, so how to do this first thing, you have to install this npm package.

36
00:02:23,640 --> 00:02:28,590
And the second thing they have to create an application for, they have given a link for Google Developer

37
00:02:28,590 --> 00:02:31,950
console can go to that console and then create an application.

38
00:02:33,130 --> 00:02:35,620
So this is a process for creating this application.

39
00:02:36,700 --> 00:02:37,300
First thing.

40
00:02:39,580 --> 00:02:40,930
You have to click on Create.

41
00:02:42,820 --> 00:02:49,480
You can click on Create New Project once you click on New Project, you'll get the project name and

42
00:02:49,480 --> 00:02:52,120
everything, you can give your project some name.

43
00:02:52,450 --> 00:02:54,790
And then you have to go to the credentials section.

44
00:02:55,930 --> 00:02:59,610
Just follow me, you know, follow my words and then you can.

45
00:02:59,620 --> 00:03:01,690
You can do what you don't want to do.

46
00:03:02,140 --> 00:03:06,430
Go to credentials section and then go to what contents clean.

47
00:03:06,820 --> 00:03:11,230
So we are going to configure the screen that the user sees in the log in through Google and that when

48
00:03:11,230 --> 00:03:18,700
they log in through Google to add name, logo and scope for Google apps, save and create the API credentials,

49
00:03:19,090 --> 00:03:22,750
select what claim daily and then they're going to be authorized.

50
00:03:22,750 --> 00:03:27,690
JavaScript logins that you have to go localhost three thousand and then authorized to do that if you

51
00:03:27,700 --> 00:03:34,570
are and you can localhost 3000 or slash Google's hash secrets and now save the client Debian client

52
00:03:34,570 --> 00:03:37,810
secret in their environment variable and then required the strategy.

53
00:03:38,990 --> 00:03:45,110
So these comments might be confusing, but in the resources, the resources that are that you are provided

54
00:03:45,110 --> 00:03:47,360
with, I'll be sharing a PDF.

55
00:03:47,900 --> 00:03:50,960
So this PDF will be having the complete roadmap.

56
00:03:51,320 --> 00:03:54,140
How to do this Google Developer Consulting.

57
00:03:54,500 --> 00:04:00,320
So from starting scratch to completing getting the claim daily on the app, it would have clear detailed

58
00:04:00,320 --> 00:04:01,580
explanation of the road map.

59
00:04:02,000 --> 00:04:02,930
You can follow that.

60
00:04:03,320 --> 00:04:10,310
So once you follow, you would be getting the list three record total intervals you can see here.

61
00:04:12,900 --> 00:04:19,860
I'm having the plane tied to this plane that they will be using to make the strategy, so to get this

62
00:04:19,860 --> 00:04:22,880
plane area will be sharing the road map as a PDF, you can check that.

63
00:04:23,520 --> 00:04:25,270
So once we get the Client ID.

64
00:04:25,680 --> 00:04:27,210
Next thing is Google strategy.

65
00:04:27,540 --> 00:04:30,870
So he had a passport that used Fiat using the Google strategy.

66
00:04:31,200 --> 00:04:35,160
If you want to implement from Facebook, we can use the Facebook strategy.

67
00:04:35,880 --> 00:04:37,710
So this is a challenge for you.

68
00:04:37,830 --> 00:04:38,390
How to do.

69
00:04:38,400 --> 00:04:42,240
I'll be only sharing the road map of the Google strategy, how to get this client ready.

70
00:04:42,240 --> 00:04:46,940
But the Facebook, you can refer to the online sources and check the documentation is very simple.

71
00:04:46,950 --> 00:04:52,260
It is almost similar to everything, but only thing is the Ulit app ID.

72
00:04:52,370 --> 00:04:55,680
And instead of trying to restrict what that symbol, the names are different.

73
00:04:55,680 --> 00:04:56,130
That's it.

74
00:04:56,670 --> 00:04:58,340
And then then point the call back.

75
00:04:58,350 --> 00:04:59,280
You are a little bit different.

76
00:05:00,270 --> 00:05:01,530
This will be the call back to you on it.

77
00:05:01,890 --> 00:05:04,440
And then here this is the project name that I'm using.

78
00:05:05,100 --> 00:05:05,490
OK.

79
00:05:06,420 --> 00:05:09,210
So once we do this, everything and then.

80
00:05:10,540 --> 00:05:11,920
If you see here.

81
00:05:13,940 --> 00:05:15,680
So I'll show you one thing.

82
00:05:25,110 --> 00:05:25,830
So here.

83
00:05:27,290 --> 00:05:31,550
This user, a final create is a npm package.

84
00:05:31,820 --> 00:05:32,220
OK.

85
00:05:32,540 --> 00:05:38,300
It's not a Mongo, not a MongoDB method, but it's going to be items and user is the collection of that

86
00:05:38,720 --> 00:05:40,670
Mongo DB that we are creating.

87
00:05:41,090 --> 00:05:46,070
But this find that it is not among those deep MongoDB MongoDB method.

88
00:05:46,370 --> 00:05:47,540
It is npm package.

89
00:05:47,870 --> 00:05:53,800
So we have to separately consolidate npm install and then find or create and then we can import it here,

90
00:05:53,810 --> 00:05:54,590
find, not create.

91
00:05:54,950 --> 00:05:58,430
Using that one was find out that we have to install this package.

92
00:05:58,820 --> 00:06:02,780
There's going to be a mungo's find or cleared and then required.

93
00:06:04,170 --> 00:06:09,810
So once we do that, we can use the Facebook or Google strategy, when the strategy is completed, then

94
00:06:10,140 --> 00:06:15,990
we can basically get the code from the passport documentation of the whole court after you can go to

95
00:06:15,990 --> 00:06:17,310
the documentation audio.

96
00:06:18,840 --> 00:06:19,230
OK.

97
00:06:19,560 --> 00:06:19,950
Way it is.

98
00:06:25,340 --> 00:06:31,880
So what should be in the get method, what should be in the get method of art, we will not call back

99
00:06:32,930 --> 00:06:34,190
and go to the documentation.

100
00:06:34,730 --> 00:06:40,690
Now finally, I have to change the surrealism de serialize uses to work from the start strategy instead

101
00:06:40,700 --> 00:06:42,650
of working only for the local strategies.

102
00:06:43,130 --> 00:06:52,720
OK, so as you can see here here, this serialised here, I'm giving you said and done and adultery.

103
00:06:52,790 --> 00:06:57,470
So this will work for all the packages, not only the local masks, but all the Google strategies and

104
00:06:57,470 --> 00:06:58,460
all the other strategies.

105
00:06:59,460 --> 00:07:06,810
So once this is done, then we can basically, right, you know, and get it on this cold like I brought

106
00:07:06,810 --> 00:07:11,190
get kidnapped daughter post and everything from the documentation.

107
00:07:13,530 --> 00:07:13,800
Yeah.

108
00:07:15,560 --> 00:07:19,960
So with this, we have completed that authentication part.

109
00:07:20,360 --> 00:07:23,390
So the main thing is you have to understand what we are doing and how it is done.

110
00:07:23,630 --> 00:07:30,320
The court, but basically all look programmers or developers who are there and you know, who are there

111
00:07:30,350 --> 00:07:32,090
in the industry.

112
00:07:32,390 --> 00:07:36,260
Basically, just use the Google StackOverflow to get this code.

113
00:07:36,560 --> 00:07:38,090
None of them remembers the code.

114
00:07:38,330 --> 00:07:42,410
It's only the concept of how what we are doing and how we are doing.

115
00:07:42,770 --> 00:07:47,060
That is what we have to focus on and the core thing you can use the documentation is to refer.

116
00:07:47,630 --> 00:07:48,920
OK, it's simple as that.

117
00:07:50,090 --> 00:07:54,170
So there are comments given to this, what it is doing and everything.

118
00:07:54,170 --> 00:07:56,720
You can take this all code, it will be provided to you.

119
00:07:57,320 --> 00:07:58,790
So there's a challenge for you.

120
00:07:58,790 --> 00:08:00,620
Have to implement the log in with Facebook.

121
00:08:01,280 --> 00:08:01,610
OK.

122
00:08:02,240 --> 00:08:09,230
Now finally, once we do this, we can run our thing and check an example I'm using.

123
00:08:09,230 --> 00:08:10,280
Sign up at Google.

124
00:08:11,440 --> 00:08:13,090
And then using this, my account.

125
00:08:16,100 --> 00:08:21,710
So once they use this so we can go to the Descartes database, just refresh it.

126
00:08:22,640 --> 00:08:26,180
And if you check in Britain, they're giving the database a Google lady.

127
00:08:26,720 --> 00:08:32,210
So whenever next I click on log log in, then they will compare that Google idea with this Google Light

128
00:08:32,240 --> 00:08:33,170
in the database.

129
00:08:33,740 --> 00:08:34,160
OK.

130
00:08:34,230 --> 00:08:35,030
In the schema.

131
00:08:35,030 --> 00:08:36,860
And then they will allow me log in and log.

132
00:08:37,930 --> 00:08:38,890
So as of now.

133
00:08:40,830 --> 00:08:41,970
I'll be deleting this.

134
00:08:43,500 --> 00:08:45,810
So this is how the Google authentication is done.

135
00:08:46,320 --> 00:08:53,220
So basically, we have seen a social networking website with the highly secure and authenticated environment

136
00:08:53,220 --> 00:08:59,370
where we saw many different types of things like many levels of being like, first thing, we have just

137
00:08:59,370 --> 00:09:03,990
saw storing the username and password in the database and then encrypting the database and then using

138
00:09:03,990 --> 00:09:09,840
the environment variables and then only hashing and then solving and mashing, posting, only hashing,

139
00:09:09,840 --> 00:09:11,100
using modify solving.

140
00:09:11,100 --> 00:09:11,880
Imagine using.

141
00:09:12,690 --> 00:09:17,760
And then we saw what is cookies, what of systems, how to use them with passbook, what is serialized

142
00:09:17,760 --> 00:09:18,810
and what is serialized.

143
00:09:18,810 --> 00:09:21,660
And then finally, Google authentication, Google Developer console.

144
00:09:22,080 --> 00:09:27,270
So all these things will destroy the roadmap of Google or what?

145
00:09:27,270 --> 00:09:32,310
You will be getting it in a PDF or image file the resources that you are provided with.

146
00:09:33,090 --> 00:09:34,680
We have sort orders get ignored.

147
00:09:34,680 --> 00:09:35,430
Will do so.

148
00:09:35,550 --> 00:09:41,790
Do Is Scalia completely highly secure social networking app they can post your really can post your

149
00:09:41,790 --> 00:09:44,210
posts, photos and everything at fixed.

150
00:09:44,460 --> 00:09:50,410
Here we are only posting some pics, but you can modify it to post any major Saoradh can.

151
00:09:50,850 --> 00:09:52,530
You can see the documentation for the Google.

152
00:09:53,880 --> 00:09:57,450
So with this, we complete this project of social networking website.

153
00:09:58,560 --> 00:10:05,340
I hope you have understood all the concepts and enjoyed the videos in this through this project.

154
00:10:06,180 --> 00:10:06,630
Thank you.
