Just a heads-up that I've committed a small bit of code to master that verifies template contents when downloading (per CLOUDSTACK-6088). For example, it verifies that the first few bytes of a template registered as a vhd format look like a vhd file. This is designed to catch mis-matches, and in particular uploads of .vmdk where the user is really uploading the ASCII text descriptor and not the FLAT vmdk data file.
The commit is fairly small, but I'm a bit nervous that I may not have accounted for all incarnations of what various formats might look like, so I thought I'd send out a heads-up. If your template registrations start complaining about mismatched types we can fix or roll this back. commit 15ac47e47b4c9a2323888d73f6988cb967647e28 Author: Marcus Sorensen <mar...@betterservers.com> Date: Wed May 28 15:36:13 2014 -0600 CLOUDSTACK-6088: Check first bytes of template when downloading to verify format/type