Medical images can be constructed in two-dimensional (2D) or three-dimensional (3D) view imaging to be applied in disease detection and diagnosis inside the body, such as cancer/tumor, heart, or lung-related diseases. These images may contain patients' privacy information and clinical diagnosis records. Hence, these images need to ensure authorization demands among hospitals, medical service organizations, or physicians in a picture archiving and communication system. This study presents an intelligent symmetric cryptography with a chaotic map and quantum-based key generator (KG) for medical image encryption and decryption. Overall scheme processes include (1) random cipher code generation, (2) training gray relational analysis (GRA)-based encryptor and decryptor, and (3) decrypted image evaluation. The hybrid chaotic map and quantum-based KG are used to increase the chaotic complexity and unpredictable levels to produce cipher codes for changing pixel values (substitution method) in a 2D image by 256 key-space cipher codes. The first and second GRA models are used to train the cipher codes to achieve an encryptor and a decryptor, respectively. Through the methodology validation using a chest X-ray database, the structural similarity index measurement is employed to evaluate the decryption quality between the plain image and decrypted image. The encrypted images show a visual uncorrelation with the plain images, and experimental results indicate higher confidences against the passive eavesdropper.