Patent ID: 10659220

Abstract:
The invention provides a method and system for encrypting and decrypting two-dimensional code mask. The method comprises: generating a target two-dimensional code containing a function pattern and an identification, an initial mask pattern and a key by a two-dimensional code generating device; sending the identification, the initial mask pattern and the key to a server by the two-dimensional code generating device; sending the identification to the server by the two-dimensional code decoding device; receiving the identification by the server; sending the key and the initial mask pattern to the two-dimensional code decoding device by the server according to the identification; receiving by the two-dimensional code decoding device the key and the initial mask pattern sent by the server; and decrypting the encrypted two-dimensional code by the two-dimensional code decoding device according to the key and the initial mask pattern to acquire the target two-dimensional code. The system has high security.