I am working on a .Net Standard project and i am using netDxf.netstandard library in it.
I am trying to obfuscate my code using DotFuscator Community Edition GUI.
DotFuscator build process fails and shows the following message:
Reading debugging symbols for module 'MyNameSpace.dll'...
Warning: No debugging symbols found for module 'MyNameSpace.dll'.
An item with the same key has already been added.
Build Error.
I ended up (after code pruning) with one-file project and the same error message is shown!
using netDxf.Entities;
namespace MyNameSpace
{
public class Cls
{
public static double Method1(Polyline p)
{
return 0;
}
public static double Method2(LwPolyline p)
{
return 0;
}
}
}
Whats wrong with this snippet so the obfuscation process always fail?
I work on the Dotfuscator team, and am answering this question in that capacity.
Thank you for finding this issue. It seems to occur when protecting .NET Standard libraries only, and only if the library being protected references another library whose name contains netstandard
. In this case, your .NET Standard library references netDxf.netstandard.dll
.
You can work around the problem by setting a config property with the name ilreader.alias_netstandard.never
and any non-empty value. This might cause other issues with assembly resolution, however, so you may also need to update the assembly load paths.
As for the underlying problem, we've filed a bug internally. The bug will be fixed in future releases of both Dotfuscator Professional and Dotfuscator Community.