The invention provides a method for dynamically setting a
password by setting a graphic per se in a grid
digital array. The method comprises the following steps of: setting the graphic, a counting point and a
password point per se in the grid array with abscissas and ordinates, setting a positioning point and reference point arrangement sequence per se in the graphic, simultaneously performing
password counting in any one of the eight directions of the grid
digital array, transmitting a counted password into a computer
server and storing the password as a graphic password; and moving the self-set graphic into the grid
digital array with the abscissas and the ordinates, obtaining an abscissa and ordinate point and the password point in the moved graphic according to the self-set counting point, and obtaining the password every time the graphic is moved until meeting the requirement of a
network on password digits to dynamically finish password login by the easily-remembered graphic capable of preventing the password from being detected. By the method for dynamically obtaining the password and finishing the login, even though the graphic is the same, the same password cannot be obtained due to different graphic positioning points, different counting points and different password points. Therefore, the password security of a user can be greatly and effectively protected, and sudden attacks from bogusware such as Trojan and the like, and different kinds of snooping and harassing attacks in front of automatic teller machines are prevented; and the method is easy to remember and operate, and highly preventive.