Hi Yousuf,
This is not a complete answer to your question but could help:
ARSAPP.DOC_TYPE
--------------------
41 = AFP
4C = line
42 = BMP
47 = GIF
50 = PCX
54 = TIFF
52 = PDF
4A = JFIF/JPEG
51 = PNG
4D = Metacode
55 = User defined
4E = None
Reading CLOB you can just select with cast, most of CMOD CLOB are relatively small in size.
Parsing the CLOB read the ORACLE reference for regex.
Hope this helps,
N.