Dicom image has 2 parts: header data and pixel data.
For encryption, I am using an AES-GCM algorithm. It has :
Inputs: Plaintext, key, initialization vector
Outputs: Cipher text, Tag
These are the inputs and outputs of AES GCM algorithm used for encryption.
Now, I want to input DICOM image to this algorithm. So for that first, I take the header part of DICOM image, hash it using SHA-256 algorithm. Hence I get key and Initialization vector. Then I take the pixel data part and I get the plain text from this.
How to separately get the header data and pixel data separately in matlab?. Can somebody help me out?
What I have tried:
Till now, I could input the entire dicom image and perform hash function (SHA-256) and got the value.
But that is not what I want.I want to separately access the header and pixel dat?
What must be done? is there any way?