FLAT-407 Image validate

Add the code for image validation