Indented the xml templates to enchance readability, switched openssl to gibberish in hash generation because openssl was returning binary hashes. Still doesnt work though.