The invention provides a webpage text
encryption and decryption method based on random fonts, and belongs to the technical field of
the Internet. By randomly generating the mapping relation between the characters and the fonts in the CMAP, the custom fonts are quickly generated,
encryption rendering is carried out on the specific characters in the webpage, and therefore data cannot be directly obtained in an original text of the webpage, and key data are effectively prevented from being stolen in the webpage environment. The method has no influence on the whole style, and the style unificationis kept; the
font file only describes the vector information of the
glyph, and compared with a picture, the
font file is very small in occupied space,
font drawing is completely completed by a browser, and the user experience is hardly influenced. According to the method, effective obstacles are caused to malicious collection of part of crawlers, and the risk that a website is maliciously attacked is reduced; meanwhile, a large amount of manpower,
material resources and money cost consumed in many invalid accesses are saved, and the method has important significance in improving the user experience degree and satisfaction degree of company products.