We don't provide such tools, but I will try to answer your questions anyway:
1) There are several techniques for minimizing the XAP file size:
- the easiest is to enable the assembly caching in the Silverlight application project properties. This will put (e.g. cache) the system or third party assemblies into separate ZIP files that will be downloaded when the application is run for the first time. Generally this optimization will not have effect unless the client uses several applications that use the same cached assemblies.
- since the XAP files are basically renamed ZIP files, there are tools, now obsolete, that used to re-compress them. In Silverlight 2 the XAP files were compressed with very low compression ratio, hence they benefited from those tools a lot. Silverlight 3 uses better compression algorithm so such tools are not very usable anymore.
- there are tools that analyze the assemblies in the XAP file and then remove the unused code. In theory this could have huge benefit for third party control assemblies, because they usually pack a lot of functionality that is rarely used at once. There are several problems with such tools, though - if the code in the application uses reflection, the tool could incorrectly identify parts of the code as unused and break the application. On the other hand such tools cannot process digitally signed assemblies unless you have the digital key, which is not an option with the third party control assemblies.
2) The XAP files are plain ZIP files, hence they cannot be obfuscated. You could use a third party tool (such as Dotfuscator) that will obfuscate the code of your application at compile time. Those tools are quite effective and the obfuscated code becomes virtually impossible to disassemble. The non obfuscated assemblies are very easy to disassemble using RedGate's Reflector or other similar tools.
I hope my answers were helpful.
the Telerik team
Watch a video
on how to optimize your support resource searches and check out more tips
on the blogs.
Follow the status of features or bugs in PITS
and vote for them to affect their priority.