1 00:00:00,940 --> 00:00:09,370 In this lesson we are going to learn reversing judge to do reversing germs. 2 00:00:09,430 --> 00:00:18,210 We will need to use all these previous commands which we learned before including the concept for what 3 00:00:18,460 --> 00:00:31,040 arguments both and then we will learn how to reverse germ and then how to reverse the Zero flag a part 4 00:00:31,190 --> 00:00:35,000 of the register let's get started. 5 00:00:38,780 --> 00:00:41,650 Recorded in the previous example. 6 00:00:41,750 --> 00:00:46,100 Lesson Well we try to run this from the command line. 7 00:00:46,100 --> 00:00:49,400 If we show us a story try harder. 8 00:00:52,040 --> 00:00:57,460 Now we have learned how to set a breakpoint on the string. 9 00:00:57,490 --> 00:01:07,270 Now the objective of this is to state how looking and we try harder message. 10 00:01:07,450 --> 00:01:17,530 We would like to see the flag being displayed here the flag as you recall is a serial number or secret 11 00:01:17,530 --> 00:01:21,040 phrase or a secret word. 12 00:01:21,340 --> 00:01:32,440 And if you refer back to the place where we download is correct me the author evil programmer sees that 13 00:01:32,530 --> 00:01:33,880 this is a very easy flag. 14 00:01:34,030 --> 00:01:44,140 So the objective is to make the program show us the flag instead of show us this message. 15 00:01:44,140 --> 00:01:44,810 Try harder. 16 00:01:46,120 --> 00:01:53,950 So let us see how you can do that so let's run the program in the debugger 17 00:02:05,430 --> 00:02:15,530 let's go to the entry point by pressing F nine run the now and the entry point. 18 00:02:15,530 --> 00:02:25,690 Now let's put a breakpoint on the string so we can either scroll down and look for the string or we 19 00:02:25,690 --> 00:02:29,340 can rightly and look for string. 20 00:02:29,340 --> 00:02:38,190 Search for current you and you have to make sure you are in your user module then string references 21 00:02:40,970 --> 00:02:41,960 over here. 22 00:02:42,210 --> 00:02:52,450 You will find your string try harder so we can double click the address to directly go to once we arrive 23 00:02:52,450 --> 00:02:52,980 here. 24 00:02:54,660 --> 00:03:04,340 We can see that the string is being set up for the call to display so previous lessons. 25 00:03:04,590 --> 00:03:14,390 We put a brake point here to pass so that we can step through using FAA to see the string but now we 26 00:03:14,390 --> 00:03:17,150 want to avoid seeing the string. 27 00:03:17,210 --> 00:03:27,240 How do we avoid seeing the string so let's analyze this a bit notice that this instruction comes from 28 00:03:27,510 --> 00:03:38,540 here a previous jam which takes place over here so it is this jam which brings us to this string this 29 00:03:38,540 --> 00:03:39,440 suggested. 30 00:03:40,070 --> 00:03:46,710 If we don't want to see this string we should not jam at the moment. 31 00:03:46,730 --> 00:03:55,850 The line the arrow is red meaning that the jam will be taken and you can also confirmed by looking in 32 00:03:55,850 --> 00:03:57,260 the status here. 33 00:03:57,440 --> 00:03:59,230 Jam is taken. 34 00:03:59,510 --> 00:04:10,540 So now the question is how do we reverse this jam another phrase here is reversing the jam reversing 35 00:04:10,660 --> 00:04:11,080 the jam. 36 00:04:12,140 --> 00:04:18,170 So you to jam is going to be taken after reversing it will be. 37 00:04:18,170 --> 00:04:23,320 He will not be taken so that is called reversing. 38 00:04:23,350 --> 00:04:36,340 So now let's see before a jam is made a decision has to be made better not to jam so this is decided 39 00:04:36,610 --> 00:04:49,370 by a Register called the Zero fly z f zero flight so the Zero flag will determine whether or not if 40 00:04:49,490 --> 00:04:54,540 we jam if at this point the jam is taken. 41 00:04:54,970 --> 00:05:02,530 And if we don't want it to jam all we need to do is toggle the zero fly by double clicking. 42 00:05:02,530 --> 00:05:04,140 So if I were to double click this. 43 00:05:04,150 --> 00:05:13,530 Now watch what happens to the status in the airline so I would absolutely zero flight to become zero 44 00:05:14,730 --> 00:05:15,910 zero fact now is zero. 45 00:05:15,910 --> 00:05:17,320 Previously it was 1. 46 00:05:17,600 --> 00:05:26,940 And notice the line has changed to gray and the status has two to jump he's not taken. 47 00:05:26,940 --> 00:05:35,280 If he wanted to to toggle back to jump all we have to do is toggle the zero flight back to one by double 48 00:05:35,280 --> 00:05:37,190 clicking again. 49 00:05:37,530 --> 00:05:39,420 And now the Zero flag is one. 50 00:05:39,750 --> 00:05:48,260 And now the line has changed to read and the status is Jim is taking so what the. 51 00:05:48,410 --> 00:05:52,010 Is to stop it from jumping. 52 00:05:52,070 --> 00:05:56,800 So let's toggle the zero flight said it is zero. 53 00:05:56,880 --> 00:06:03,980 So now he will not jump so that we he will not display this string. 54 00:06:04,040 --> 00:06:05,570 Try harder. 55 00:06:05,810 --> 00:06:08,150 So instead what will he do. 56 00:06:08,150 --> 00:06:10,730 He will proceed to the next car below. 57 00:06:11,390 --> 00:06:15,530 So let's press f it before we press feet. 58 00:06:15,590 --> 00:06:17,200 We need to put a brake point here 59 00:06:20,170 --> 00:06:24,000 and then send it back to the previous date. 60 00:06:24,020 --> 00:06:28,460 So now we are going to run to this point. 61 00:06:28,580 --> 00:06:31,720 Press F 9 1 and he will stop. 62 00:06:31,890 --> 00:06:33,400 And is very fine. 63 00:06:33,400 --> 00:06:42,490 So when you are here we want to toggle the zero fly to zero so that he will not jump. 64 00:06:42,490 --> 00:06:43,560 Now we press it 65 00:06:46,540 --> 00:06:48,550 and you will go to the next instruction. 66 00:06:49,300 --> 00:06:54,530 So he has not jumped to the despite a show's history. 67 00:06:54,550 --> 00:06:57,140 Instead he went onto the next line. 68 00:06:57,150 --> 00:07:03,960 Now what do you think would happen if I were to press f it again to call this instruction. 69 00:07:04,200 --> 00:07:04,770 Let's try 70 00:07:07,600 --> 00:07:10,150 you see the flag is shown. 71 00:07:10,150 --> 00:07:16,520 So that means this car who show you the fly right. 72 00:07:17,000 --> 00:07:27,760 And if you press F it again you will go to this line and jump over this string as you can see so we 73 00:07:27,800 --> 00:07:31,430 not jump over this line and avoid it. 74 00:07:31,530 --> 00:07:33,430 The try had a string. 75 00:07:33,830 --> 00:07:43,120 So this is the way in which we can correct some way by analyzing the jumps and toggling it and putting 76 00:07:43,120 --> 00:07:50,890 the right brake point where decision is being made whether to jump or not to jump so let us repeat this 77 00:07:51,040 --> 00:07:52,920 one more time. 78 00:07:52,980 --> 00:08:02,670 The first thing you need to do is to look for the string and then analyze where he's supposed to decide 79 00:08:04,380 --> 00:08:09,960 where it comes from the call which lines in the string come from here. 80 00:08:10,770 --> 00:08:22,870 So if you put a breakpoint here and then restart run to the big pine and then reverse the point so that 81 00:08:22,870 --> 00:08:30,590 it jumps he will not jump to the to the track the message reverse it. 82 00:08:31,240 --> 00:08:34,020 Have it called a jump. 83 00:08:34,530 --> 00:08:35,760 That's it. 84 00:08:35,790 --> 00:08:44,100 So you have solved this challenge by getting the flag because this one and you can confirm it by looking 85 00:08:44,700 --> 00:08:49,680 at the some of the answers posted by other reverses. 86 00:08:49,730 --> 00:08:55,200 If that is indeed this case you can see. 87 00:08:55,230 --> 00:08:58,680 So that is how you reverse a jump. 88 00:08:58,680 --> 00:09:05,020 So in a moment we will stop here and I will see you in the next lesson. 89 00:09:05,100 --> 00:09:13,380 So far what we have learned is how to celebrate points on the history how to reverse jump by reversing 90 00:09:13,480 --> 00:09:14,880 the zero flight. 91 00:09:14,910 --> 00:09:15,840 Thank you for watching.