With the continuous development of information technology, the security of images in the process of transmission, storage and use has also become the focus of network security. However, most of the existing image encryption algorithms only focus on the security of images in the transmission and storage process, while ignoring their security in use. For some special organisations, images are very sensitive information and their security during usage is also very important. Similar to the advanced encryption information stored in the public security system, the depth of information that can be viewed by ordinary privileges and advanced privileges is different. But there is no such hierarchical authorisation algorithm in image security. In order to solve this problem, this study proposes a hierarchical authorisation encryption and decryption algorithm, which achieves hierarchical decryption while ensuring the security of encrypted images. In this method, the image is decomposed by bit plane, and the bit plane is grouped, and each group adopts different key. According to the level of legitimate users, the corresponding key is assigned to them, and the clarity of the decrypted image requested by different levels of users is different, that is, the information depth is different. This method extends the scope of application of the encryption algorithm and is more practical than the existing encryption algorithm.