Image that your .NET application uses an assembly. When compiled, the application references the exact version of that assembly. If a new minor of this assembly is installed, your application will not use it unless a policy told her so. This is fine in most cases, as it avoids the DLL hell issue.
But, the problem with assembly policy is that the oldVersion attribute cannot be a wildcard. You have to specify the exact old version of assembly to redirect to the new one. This can be a problem when you have several versions of the assembly and want to redirect them to the latest version.
There are two solutions for that: - Define as much redirect as there is old versions of the assembly. This is the explicit way. - Although oldVersion attribute cannot be a wildcard, it can be a range. All you have to do is to define the lower and upper bound of the version. This is the implicit way.
Here is an example of range use:
<configuration> <runtime> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <dependentAssembly> <assemblyIdentity name="Monobjc" publicKeyToken="d5a8d181860c16be" /> <bindingRedirect oldVersion="10.5.0.0-10.5.65535.65535" newVersion="10.5.1492.0"/> </dependentAssembly> </assemblyBinding> </runtime> </configuration>
This policy will redirect any assembly whose version begins with "10.5" to the newVersion.