1 00:00:00,060 --> 00:00:02,100 This would ever be looking at dysfunction. 2 00:00:02,100 --> 00:00:10,260 Nick Sherry Not to enumerate are the computer shares on the computer, so it retrieves information about 3 00:00:10,260 --> 00:00:12,300 each shared resource on his or her. 4 00:00:12,810 --> 00:00:14,250 And here you can see the syntax. 5 00:00:14,610 --> 00:00:16,740 The return type is net API status. 6 00:00:16,920 --> 00:00:18,900 So that's Google's expertise. 7 00:00:25,600 --> 00:00:31,180 And if you go to this website here, we have the values. 8 00:00:31,570 --> 00:00:33,880 So the return type is actually integer. 9 00:00:33,880 --> 00:00:39,290 So based on the return by, what you can do is you can compare the return type here. 10 00:00:39,640 --> 00:00:40,150 So this. 11 00:01:10,780 --> 00:01:15,340 So we can just compare the traditional values. 12 00:01:16,060 --> 00:01:18,130 So let's first declare our input. 13 00:01:18,550 --> 00:01:22,480 So this function is that we do not deliver. 14 00:01:23,830 --> 00:01:25,030 So let's do the import. 15 00:01:48,020 --> 00:01:51,640 So I am calling this return the integer and the function name. 16 00:01:54,870 --> 00:02:00,060 And the first argument is bells are not a name, so it's not really computer name. 17 00:02:00,870 --> 00:02:04,890 You can also parse that combatant name as well. 18 00:02:05,430 --> 00:02:07,120 So it is Elon Musk here. 19 00:02:07,230 --> 00:02:13,770 So it's similar to we can Marshall as well where character acting. 20 00:02:25,440 --> 00:02:32,910 Marshall as unmanaged a not a p w sd. 21 00:02:33,180 --> 00:02:36,420 So we can now just pass this as bringing it through. 22 00:02:36,420 --> 00:02:38,280 We cannot be converted to this. 23 00:02:40,340 --> 00:02:40,570 Right. 24 00:02:40,640 --> 00:02:41,660 Got her pointer. 25 00:02:41,660 --> 00:02:47,330 So copied username and the second parameter is level. 26 00:02:47,600 --> 00:02:53,810 So here you can see the level level indicates that the enumeration you want to do on it, on the particular 27 00:02:53,810 --> 00:03:00,530 computer, if you give the version zero, you get the return type of this pointer. 28 00:03:00,770 --> 00:03:05,360 So I will get a normal address that is binding to the output structure. 29 00:03:07,360 --> 00:03:09,610 So let's open this sharing for zero. 30 00:03:11,820 --> 00:03:20,870 And here you can see there is only one member in this structure that is nickname so Pinder Unicode specifying 31 00:03:20,880 --> 00:03:22,020 the shade name of the resource. 32 00:03:23,630 --> 00:03:28,040 So it was simply that the name of the ship. 33 00:03:30,400 --> 00:03:30,700 Okay. 34 00:03:30,700 --> 00:03:32,710 Let's create the structure on that name. 35 00:03:32,920 --> 00:03:33,910 So let's copy this. 36 00:03:44,960 --> 00:03:46,890 And public after the structure. 37 00:03:52,890 --> 00:03:57,690 So this is also going to be Marshall to this great character study. 38 00:04:06,680 --> 00:04:11,330 So we can into martial arts, so we can just simply copy this. 39 00:04:16,230 --> 00:04:17,190 So we are good to go. 40 00:04:18,660 --> 00:04:22,590 Now, the second parameter for our function is the level. 41 00:04:22,740 --> 00:04:24,360 So let's first, uh. 42 00:04:25,820 --> 00:04:28,130 That is in beta. 43 00:04:28,700 --> 00:04:31,430 So you don't see any negative here. 44 00:04:31,820 --> 00:04:33,710 So we can say in beta level. 45 00:04:39,110 --> 00:04:44,690 And the third type is they point out, so we can say better than the obvious point that we can just 46 00:04:44,690 --> 00:04:46,670 specify with this endpoint. 47 00:04:53,600 --> 00:04:58,490 And then action is put in front of my exponent by my event of the data we can. 48 00:04:58,790 --> 00:04:59,630 We need to return. 49 00:05:14,700 --> 00:05:15,730 So that's a. 50 00:05:17,290 --> 00:05:18,320 132. 51 00:05:19,270 --> 00:05:20,920 And then please read. 52 00:05:20,920 --> 00:05:25,570 So the number of entries, the function hazard and the is total entries. 53 00:05:27,270 --> 00:05:28,980 So we need to pass this as a reference. 54 00:05:38,720 --> 00:05:45,410 Because the parameter we need to pass this as a reference so we get the value to our, uh, variable 55 00:05:46,190 --> 00:05:47,540 so that order renders. 56 00:05:48,290 --> 00:05:55,430 So sometimes you can get there, there are five entries you'll be able to only read or if your entries 57 00:05:55,790 --> 00:06:00,800 because we do not have access to that some particular issue. 58 00:06:01,910 --> 00:06:03,430 And then one is resume handle. 59 00:06:03,450 --> 00:06:08,000 If you want to continue searching through the shares, you can use this handle. 60 00:06:08,630 --> 00:06:12,250 So for now, let's consider, uh, null. 61 00:06:20,440 --> 00:06:20,740 Okay. 62 00:06:20,770 --> 00:06:22,570 This is our function. 63 00:06:22,690 --> 00:06:27,760 Now we can call this and say let's in. 64 00:06:27,760 --> 00:06:29,230 The result is equals to. 65 00:06:31,020 --> 00:06:32,580 Net share in a month. 66 00:06:34,790 --> 00:06:35,390 And the first. 67 00:06:37,230 --> 00:06:39,030 Uh, paramedics bring them. 68 00:06:39,240 --> 00:06:41,850 So let's go and find our horse name. 69 00:06:44,020 --> 00:06:45,960 So I'm testing this on my machine. 70 00:06:45,980 --> 00:06:51,070 I also tested on the Metro Network and it's working perfectly. 71 00:06:52,330 --> 00:07:03,240 So the hostname of the computer and the level is zero because we have only the structural shade in form 72 00:07:03,250 --> 00:07:06,420 zero and the next one is above there. 73 00:07:06,430 --> 00:07:12,160 We need to create an interpreter that's above PTI recalls. 74 00:07:12,210 --> 00:07:14,500 Do we want to? 75 00:07:14,740 --> 00:07:22,150 Let's say first one, we can initiate digital zero, and after that we can serve both video. 76 00:07:24,900 --> 00:07:26,790 So upon that function is the question. 77 00:07:26,790 --> 00:07:29,460 We'll get the address into this year. 78 00:07:29,460 --> 00:07:31,950 We can convert that to structure using module. 79 00:07:33,710 --> 00:07:36,200 So the next one is a preferred one. 80 00:07:36,950 --> 00:07:38,420 So I guess. 81 00:07:42,550 --> 00:07:46,240 We can say just 100, I guess our 200. 82 00:07:49,110 --> 00:07:50,040 And please read. 83 00:07:50,190 --> 00:07:51,600 So this will be. 84 00:07:59,550 --> 00:08:01,500 And Trace is equal to zero. 85 00:08:02,570 --> 00:08:07,630 And also we can sit and read and order and Prince. 86 00:08:12,570 --> 00:08:13,770 Rough entries. 87 00:08:13,770 --> 00:08:16,260 Read the total entries. 88 00:08:20,150 --> 00:08:21,680 We need to initiate this as well. 89 00:08:23,920 --> 00:08:24,190 Okay. 90 00:08:24,190 --> 00:08:29,290 The Russian is actually not border zero. 91 00:08:30,280 --> 00:08:38,380 So they should do fine and return to the functions that seeds return babies narrow success. 92 00:08:38,740 --> 00:08:43,150 So if you go to this summary, the value of the success, I think zero. 93 00:08:43,420 --> 00:08:44,530 Yes, it's zero. 94 00:08:45,220 --> 00:08:47,230 So we can also do that as well. 95 00:08:49,090 --> 00:08:50,190 This is. 96 00:08:53,820 --> 00:08:54,570 Cameras are. 97 00:09:01,060 --> 00:09:01,550 Kevin. 98 00:09:02,120 --> 00:09:03,360 We did not serve. 99 00:09:03,580 --> 00:09:04,000 Okay? 100 00:09:09,610 --> 00:09:11,470 So let's first normally run this. 101 00:09:15,260 --> 00:09:15,510 Okay. 102 00:09:20,610 --> 00:09:22,070 And here you can see the function. 103 00:09:22,070 --> 00:09:28,410 And so it was really good that when you do expect this is a pointer, the point that is pointing to 104 00:09:28,410 --> 00:09:31,140 the first element of this structure. 105 00:09:31,470 --> 00:09:34,800 So we need to convert that pointer to the structure. 106 00:09:35,160 --> 00:09:37,650 So what we can do is we can use Marshal Dot. 107 00:09:38,550 --> 00:09:43,620 We are to structure, so we need to pass the pointer. 108 00:09:43,620 --> 00:09:53,640 And the second one is so that it can calculate the size of the structure and it will take this information 109 00:09:53,640 --> 00:09:57,480 and it will give you a proper structure for. 110 00:09:58,770 --> 00:10:06,240 So both are common type of and this structure name some type of. 111 00:10:07,890 --> 00:10:08,920 Sharon fled Europe. 112 00:10:16,640 --> 00:10:26,720 And the return by these children for let's say is zero is equal to and we need to cash to this incoming 113 00:10:26,720 --> 00:10:32,240 structure into this shared infrastructure so that our members will be actually protected in this. 114 00:10:34,190 --> 00:10:36,570 Uh, the net net. 115 00:10:36,670 --> 00:10:38,560 So that net will be accurate. 116 00:10:39,070 --> 00:10:40,360 So what I can do is I can. 117 00:10:40,360 --> 00:10:40,990 To print. 118 00:10:41,080 --> 00:10:41,370 Yes. 119 00:10:41,380 --> 00:10:42,100 Zero dot. 120 00:10:43,880 --> 00:10:44,870 She did not know. 121 00:10:45,770 --> 00:10:48,880 So if I go and run this and here you can see that are. 122 00:10:50,300 --> 00:10:51,770 Our Soledad O'Brien, 123 00:10:54,650 --> 00:10:55,890 daughter and prince. 124 00:11:04,750 --> 00:11:10,870 And if you run this and here you can see there are 14 priests, but we have only one output because 125 00:11:11,530 --> 00:11:16,470 our pointer is pointing to the fastest actual return. 126 00:11:17,050 --> 00:11:25,660 If you add the length of this structure to this pointer, you will get the first element of the next 127 00:11:25,660 --> 00:11:26,200 structure. 128 00:11:26,230 --> 00:11:29,950 So what you can do is both are equal to four. 129 00:11:30,490 --> 00:11:36,700 So y for the string is a pointer so that it occupies the four weights. 130 00:11:37,870 --> 00:11:38,590 So that's. 131 00:11:41,920 --> 00:11:42,670 Copy this. 132 00:11:49,640 --> 00:11:50,450 Oh, that's. 133 00:11:52,580 --> 00:11:53,960 Cut and paste here. 134 00:11:53,990 --> 00:11:55,190 Now, if you go and. 135 00:11:59,960 --> 00:12:04,730 If you go run this, I will get the next share so we can move over this one. 136 00:12:06,240 --> 00:12:08,480 Fire in are easy questions. 137 00:12:08,490 --> 00:12:08,940 Zero. 138 00:12:10,370 --> 00:12:10,900 I. 139 00:12:11,560 --> 00:12:15,620 I was then daughter in Paris. 140 00:12:17,400 --> 00:12:18,360 I pressed press. 141 00:12:25,140 --> 00:12:26,310 So let's go and run this. 142 00:12:26,340 --> 00:12:30,630 Now you can see we got the same name because we are not incrementing it. 143 00:12:30,780 --> 00:12:31,430 So let's go. 144 00:12:31,470 --> 00:12:32,080 Earning driven. 145 00:12:32,100 --> 00:12:34,980 This Musketeer press is equal to four. 146 00:12:35,610 --> 00:12:36,360 Let's run this. 147 00:12:36,630 --> 00:12:39,450 And here we can see all of the shared names. 148 00:12:40,680 --> 00:12:44,820 But you don't need to calculate the size of this number. 149 00:12:45,210 --> 00:12:49,860 You can say Marshal, not sizeof. 150 00:12:50,490 --> 00:12:56,680 Just like in the previous videos, how we found the structure size. 151 00:12:56,910 --> 00:13:02,430 And we print it to narrow where we can see the type of. 152 00:13:04,280 --> 00:13:05,800 This shading -- up. 153 00:13:06,650 --> 00:13:08,000 So let's run this one. 154 00:13:08,300 --> 00:13:14,210 So do automatically target the structure a size and it will add to this pointer so that we get the first 155 00:13:14,210 --> 00:13:16,490 member of the next structure. 156 00:13:16,550 --> 00:13:18,800 So let's run this and we get the same one put. 157 00:13:23,400 --> 00:13:29,070 So this is how you generate the shares using the net share function. 158 00:13:29,490 --> 00:13:31,560 So this is a level zero. 159 00:13:31,620 --> 00:13:35,370 We get the plane only the name of the ship. 160 00:13:35,640 --> 00:13:37,440 So that's the level. 161 00:13:37,650 --> 00:13:42,300 Bu this in this photo, we get much more information. 162 00:13:44,820 --> 00:13:46,200 So that I bought the share. 163 00:13:46,590 --> 00:13:49,530 So I also made this. 164 00:13:49,970 --> 00:13:50,870 This is my get up. 165 00:13:50,970 --> 00:13:51,240 Yes, yes. 166 00:13:51,630 --> 00:13:54,450 If you go to this, we need to have examples. 167 00:13:54,750 --> 00:13:59,070 Now you see this chair, you know, and these are the share types. 168 00:13:59,370 --> 00:14:03,570 So the you get the number depending upon the type that you. 169 00:14:09,330 --> 00:14:14,280 And also you can get the permissions currently in this part, actual part. 170 00:14:18,370 --> 00:14:22,930 So let's go and get this shared in for two. 171 00:14:28,950 --> 00:14:34,500 Secretary Cohen copied this and paste here and changed this to Zero Boo Boo. 172 00:14:38,970 --> 00:14:39,840 And this is a big. 173 00:15:20,890 --> 00:15:21,250 So far. 174 00:15:21,250 --> 00:15:22,570 She had me copy all of this. 175 00:15:22,570 --> 00:15:24,580 Our members. 176 00:15:47,700 --> 00:15:55,110 Whatever the remark is this one saying that we can marshal this as a string. 177 00:15:56,590 --> 00:15:58,690 So public string. 178 00:16:00,560 --> 00:16:04,610 And the remaining of the next three members are will. 179 00:16:15,990 --> 00:16:16,950 So based here. 180 00:16:29,250 --> 00:16:30,180 But doing. 181 00:16:34,330 --> 00:16:40,450 So I think our structure was completed, so we are good to go. 182 00:16:41,320 --> 00:16:49,720 So you need to just change this level to two and put it in the pointer that is pointing to the area 183 00:16:49,720 --> 00:16:52,090 of these shading for two structures. 184 00:16:52,450 --> 00:16:56,440 So all you need to do is our name change to two. 185 00:16:57,110 --> 00:16:57,610 Who? 186 00:16:58,000 --> 00:16:58,390 Who? 187 00:17:00,980 --> 00:17:03,140 And change everywhere from 0 to 2. 188 00:17:10,860 --> 00:17:13,140 So let's give it a try. 189 00:17:14,950 --> 00:17:16,600 We did not get character. 190 00:17:18,530 --> 00:17:19,080 The result. 191 00:18:01,640 --> 00:18:02,930 So one, two, three. 192 00:18:03,080 --> 00:18:04,640 So there you go. 193 00:18:04,670 --> 00:18:05,240 On to three. 194 00:18:16,020 --> 00:18:17,570 So it's four, two, one, two, three. 195 00:18:45,930 --> 00:18:46,290 Okay. 196 00:18:47,110 --> 00:18:50,320 Oh, so this is the thing. 197 00:18:50,340 --> 00:18:51,480 The number of bites. 198 00:18:52,950 --> 00:18:53,820 What are the problem? 199 00:18:54,000 --> 00:19:00,570 So we changed this for the max one and two to this one so that we got the output. 200 00:19:00,840 --> 00:19:03,000 So we can also print other members as well. 201 00:19:04,080 --> 00:19:04,890 They're screwed out. 202 00:19:06,000 --> 00:19:08,850 And part. 203 00:19:08,970 --> 00:19:09,450 Yes. 204 00:19:10,350 --> 00:19:10,710 But. 205 00:19:14,450 --> 00:19:17,300 Got and based below this nickname. 206 00:19:19,200 --> 00:19:19,950 As to up. 207 00:19:26,200 --> 00:19:27,190 Let's go and run this. 208 00:19:28,340 --> 00:19:32,570 And here we can see the actual part of this. 209 00:19:37,210 --> 00:19:42,130 And one thing I want is the tape of this one. 210 00:19:46,030 --> 00:19:47,340 So it's the type. 211 00:19:53,100 --> 00:19:54,000 The varies the type. 212 00:20:03,140 --> 00:20:03,410 Okay. 213 00:20:03,440 --> 00:20:06,360 We did not put this as public. 214 00:20:08,180 --> 00:20:11,960 That's why I can't see it in the situation. 215 00:20:16,370 --> 00:20:18,380 So this maximum this. 216 00:20:19,850 --> 00:20:21,810 Now we can see this is the type. 217 00:20:21,830 --> 00:20:25,580 So I have already read this one. 218 00:20:25,850 --> 00:20:27,590 So you can see this order dictionary. 219 00:20:28,220 --> 00:20:29,240 So let's copy this. 220 00:20:35,780 --> 00:20:37,630 Now we need to check every value. 221 00:20:37,640 --> 00:20:43,910 If the type is greater than or equal to this one, then we are going to print this. 222 00:20:47,460 --> 00:20:49,470 So let's also copy this one. 223 00:20:57,670 --> 00:21:06,100 Utopian impulses using systems or connections, not specialists, so that we can use our dictionaries. 224 00:21:07,420 --> 00:21:09,550 So let's print here so we can just. 225 00:21:34,890 --> 00:21:37,590 So that's one reason this there are areas. 226 00:21:44,200 --> 00:21:47,440 And now we can see we got this type of gusher. 227 00:21:48,480 --> 00:21:51,060 It's a special proboscis. 228 00:21:51,890 --> 00:21:57,790 So this is how you read the sheriff using this next you function. 229 00:21:58,360 --> 00:22:02,560 And also, I gather I want to give you guys a exercise. 230 00:22:02,890 --> 00:22:13,000 So that is net user, you know, so this is all of these functions starting with this net or somewhat 231 00:22:13,000 --> 00:22:14,220 similar scene. 232 00:22:14,240 --> 00:22:18,370 You can see Netflix Reno I could give you are the users. 233 00:22:18,730 --> 00:22:27,470 So the same syntax of these parameters and also there are levels I can see it's just uh. 234 00:22:28,970 --> 00:22:31,850 The differences that I shared in full and four. 235 00:22:32,840 --> 00:22:40,070 So you can see the same exact uh, uh, little copy of this, uh, function that showed it. 236 00:22:40,190 --> 00:22:42,410 So, uh, give it a try.