refactored the md5sum helper method and added first iteration for flagdata