Wednesday, September 26, 2018

Forward Propagation and Backward Propagation

I have been trying my hands on machine learning. Started with Supervised learning and later unsupervised learning. While I was able to breeze through these quickly I was stuck when I started with Deep learning. Apparently if you want to understand the back-end algo/process you must need to be very clear about mathematical concepts (Algebra, Calculus, Coordinate geometry). Considering I have almost forgotten the basic concepts I really had a hard time understanding the deep learning concepts.

After spending half day browsing through various portals finally I was able to make sense of what forward and backward propagation all about. Will be putting the details in mostly layman terms. A rather complex but easy to follow (can qualify for an oxymoron) instruction can be found here. Continuing further - 

In simple terms - forward propagation is about calculating output (output node) based on given input (input node) and multiplier value (weight). This calculated value may or may not match the actual expected value. Resulting difference between calculated and actual expected output is what is called error. This is the point where the forward propagation concept ends. You may have a ReLU, Sigmoid, etc functions as equation where you will be using input node and weight data to calculate the output node (more or this later) 

Coming to the backward propagation - this is actually a super-set of forward propagation. Intent here is to reduce the error which is calculated so that optimal value of weight can be identified. This will be series of repeated cycle back and forth to calculate error and then keep on reducing based on changed weight. As we are going back from output node back towards input node, this involves taking the derivative (basic calculus - minimize the dy/dx) 

This takes us to question why are we even bothered to do this exercise - well apart from fun of doing the exercise, intent is to get machine learn to identify the output based on random set of input. Deep learning is probably easier to do with libraries like Keras (yes a python fan - still working on this)

P.S. - Please correct me if you are an expert here. And don't bother to ask any question related to complex algorithm if you happen to land here by mistake, as I am also exploring and may not have answers to your queries.

Wednesday, September 19, 2018

Hacking the Window 10 device

I recently upgraded some driver in window 10 device after which the device was not letting me in and kept on throwing error that password method doesn't exist or incorrect password. I do not have any admin user setup available and was staring at possibility of calling HP help desk and likely option of re-imaging my device with loss of data.  Keeping that as last resort I tried various option and realized vulnerability of HP window 10 device or possibly any window 10 device. You can create an admin user out of nothing and restore anything and everything without even a trace of anyone finding someone meddled with the system. Steps as follow - 

  1. Restart your system with Shift key pressed from login window were you kept on getting the password error.
  2. You be routed to HP support page. Select troubleshoot option then recovery manager followed by run computer  checkup (maintenance) and finally get an option to select command prompt. [Other available option for command prompt will not work as it will end up taking you back to password page] This will have admin privilege allowing you to make below changes. Basically with the below command you will replace 'ease of use' button on login screen with command prompt where you will be able to create a new admin user. Admin user creation is allowed only from login screen and nowhere else.
  3. move d:\windows\system32\utilman.exe d:\windows\system32\utilman.exe.bak
  4. copy d:\windows\system32\cmd.exe d:\windows\system32\utilman.exe
  5. Once this is complete, use the command “wpeutil reboot” to restart the machine.
  6. You will see a command prompt where enter below command
  7. net user <username> /add
  8. net localgroup administrators <username> /add
  9. You need to be quick as system senses something fishy if you enter anything wrong and the prompt doesn't appear again. Leading you to re-do entire exercise once again.
  10. Now close the prompt, reboot, and you should see your new user in the login screen.
  11. No password required.
  12. Login go to system setting. PressWindow+R, and type netplwiz update password for account which you were unable to login.
  13. Reboot the system and done.
  14. Don't forget to revert back the name of utilman.exe file.
I found this to be a big vulnerability with Hp system and allows anyone to login to any one's Window10 device provided bios password is not set. 

All in all, I saved my self from pain of resetting my system again and in process learnt to hack into system.