<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Obfuscating an add-in in ArcGIS Pro SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-pro-sdk-questions/obfuscating-an-add-in/m-p/879831#M5615</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Marvis,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;We use Agile.net on our Desktop and Pro Application.&lt;/P&gt;&lt;P&gt;Pro must have the same name in the daml and as the name of the class (or it is obfuscated and that is reflected in the daml)&lt;/P&gt;&lt;P&gt;We achieve this by&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;CODE&gt;&lt;SPAN class="punctuation token"&gt;[&lt;/SPAN&gt;&lt;SPAN class="token function"&gt;Obfuscation&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;Exclude &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;true&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;]&lt;/SPAN&gt;
    &lt;SPAN class="keyword token"&gt;public&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;class&lt;/SPAN&gt; &lt;SPAN class="token class-name"&gt;Dosomething&lt;/SPAN&gt; &lt;SPAN class="punctuation token"&gt;:&lt;/SPAN&gt; Button
    &lt;SPAN class="punctuation token"&gt;{&lt;/SPAN&gt;
        &lt;SPAN class="keyword token"&gt;protected&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;override&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;void&lt;/SPAN&gt; &lt;SPAN class="token function"&gt;OnClick&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
        &lt;SPAN class="punctuation token"&gt;{&lt;/SPAN&gt;
            &lt;SPAN class="keyword token"&gt;using&lt;/SPAN&gt; &lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;DosomethingCommand dosomethingCommand &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;new&lt;/SPAN&gt; &lt;SPAN class="token class-name"&gt;DosomethingCommand&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
            &lt;SPAN class="punctuation token"&gt;{&lt;/SPAN&gt;
                dosomethingCommand&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;&lt;SPAN class="token function"&gt;Command&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;;&lt;/SPAN&gt;
            &lt;SPAN class="punctuation token"&gt;}&lt;/SPAN&gt;
        &lt;SPAN class="punctuation token"&gt;}&lt;/SPAN&gt;
    &lt;SPAN class="punctuation token"&gt;}&lt;/SPAN&gt;‍‍‍‍‍‍‍‍‍‍‍‍&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Try this first with doSomethingCommand doing nothing and then build from there.&lt;/P&gt;&lt;P&gt;There can be other issues in the code that cause it not to work - eg enums &amp;lt;-&amp;gt; string etc&amp;nbsp;&lt;/P&gt;&lt;P&gt;Also turn most of the settings off in Agile.net and switch them on one by one and test.&lt;/P&gt;&lt;P&gt;It can be frustrating narrowing it down to where it is failing - the ObfucationMap xml that Agile produces can help there if you set Exceptions to show.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Adam&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sun, 12 Dec 2021 11:05:18 GMT</pubDate>
    <dc:creator>AdamDavis</dc:creator>
    <dc:date>2021-12-12T11:05:18Z</dc:date>
    <item>
      <title>Obfuscating an add-in</title>
      <link>https://community.esri.com/t5/arcgis-pro-sdk-questions/obfuscating-an-add-in/m-p/879830#M5614</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;My attempts to obfuscate an add-in specifically using agile.net have been unsuccessful. I excluded all classes inheriting from&amp;nbsp;ArcGIS.Desktop.Framework.Contracts as well as not obfuscating the xaml file as stipulated at &lt;A class="link-titled" href="https://github.com/Esri/arcgis-pro-sdk/wiki/ProConcepts-Advanced-Topics#obfuscation" title="https://github.com/Esri/arcgis-pro-sdk/wiki/ProConcepts-Advanced-Topics#obfuscation"&gt;ProConcepts Advanced Topics · Esri/arcgis-pro-sdk Wiki · GitHub&lt;/A&gt;. After obfuscation however,&amp;nbsp; the add-in doesn't work. I am wondering if it's possible to obfuscate an add-in; has someone successfully accomplished this? &lt;A href="https://community.esri.com/migrated-users/86730"&gt;Uma Harano&lt;/A&gt;‌ &lt;A href="https://community.esri.com/migrated-users/10927"&gt;Wolfgang Kaiser&lt;/A&gt;‌&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 21 Oct 2020 19:00:44 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-sdk-questions/obfuscating-an-add-in/m-p/879830#M5614</guid>
      <dc:creator>MarvisKisakye1</dc:creator>
      <dc:date>2020-10-21T19:00:44Z</dc:date>
    </item>
    <item>
      <title>Re: Obfuscating an add-in</title>
      <link>https://community.esri.com/t5/arcgis-pro-sdk-questions/obfuscating-an-add-in/m-p/879831#M5615</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Marvis,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;We use Agile.net on our Desktop and Pro Application.&lt;/P&gt;&lt;P&gt;Pro must have the same name in the daml and as the name of the class (or it is obfuscated and that is reflected in the daml)&lt;/P&gt;&lt;P&gt;We achieve this by&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;CODE&gt;&lt;SPAN class="punctuation token"&gt;[&lt;/SPAN&gt;&lt;SPAN class="token function"&gt;Obfuscation&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;Exclude &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;true&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;]&lt;/SPAN&gt;
    &lt;SPAN class="keyword token"&gt;public&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;class&lt;/SPAN&gt; &lt;SPAN class="token class-name"&gt;Dosomething&lt;/SPAN&gt; &lt;SPAN class="punctuation token"&gt;:&lt;/SPAN&gt; Button
    &lt;SPAN class="punctuation token"&gt;{&lt;/SPAN&gt;
        &lt;SPAN class="keyword token"&gt;protected&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;override&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;void&lt;/SPAN&gt; &lt;SPAN class="token function"&gt;OnClick&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
        &lt;SPAN class="punctuation token"&gt;{&lt;/SPAN&gt;
            &lt;SPAN class="keyword token"&gt;using&lt;/SPAN&gt; &lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;DosomethingCommand dosomethingCommand &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;new&lt;/SPAN&gt; &lt;SPAN class="token class-name"&gt;DosomethingCommand&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
            &lt;SPAN class="punctuation token"&gt;{&lt;/SPAN&gt;
                dosomethingCommand&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;&lt;SPAN class="token function"&gt;Command&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;;&lt;/SPAN&gt;
            &lt;SPAN class="punctuation token"&gt;}&lt;/SPAN&gt;
        &lt;SPAN class="punctuation token"&gt;}&lt;/SPAN&gt;
    &lt;SPAN class="punctuation token"&gt;}&lt;/SPAN&gt;‍‍‍‍‍‍‍‍‍‍‍‍&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Try this first with doSomethingCommand doing nothing and then build from there.&lt;/P&gt;&lt;P&gt;There can be other issues in the code that cause it not to work - eg enums &amp;lt;-&amp;gt; string etc&amp;nbsp;&lt;/P&gt;&lt;P&gt;Also turn most of the settings off in Agile.net and switch them on one by one and test.&lt;/P&gt;&lt;P&gt;It can be frustrating narrowing it down to where it is failing - the ObfucationMap xml that Agile produces can help there if you set Exceptions to show.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Adam&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 11:05:18 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-sdk-questions/obfuscating-an-add-in/m-p/879831#M5615</guid>
      <dc:creator>AdamDavis</dc:creator>
      <dc:date>2021-12-12T11:05:18Z</dc:date>
    </item>
    <item>
      <title>Re: Obfuscating an add-in</title>
      <link>https://community.esri.com/t5/arcgis-pro-sdk-questions/obfuscating-an-add-in/m-p/879832#M5616</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I added&amp;nbsp;[Obfuscation(Exclude = true)] which is a neat way to exclude classes.&lt;/P&gt;&lt;P&gt;I followed your advice and tested each obfuscation option individually. I found that Renaming, Control flow, String obfuscation and Resource Encryption are the only options that work. I wonder if that's adequate protection....&lt;/P&gt;&lt;P&gt;Have you been able to get the&amp;nbsp;Method call obfuscation,&amp;nbsp;Code encryption and&amp;nbsp;Code virtualization&amp;nbsp; options to work?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 22 Oct 2020 20:51:23 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-sdk-questions/obfuscating-an-add-in/m-p/879832#M5616</guid>
      <dc:creator>MarvisKisakye1</dc:creator>
      <dc:date>2020-10-22T20:51:23Z</dc:date>
    </item>
    <item>
      <title>Re: Obfuscating an add-in</title>
      <link>https://community.esri.com/t5/arcgis-pro-sdk-questions/obfuscating-an-add-in/m-p/879833#M5617</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Marvis,&lt;/P&gt;&lt;P&gt;We've never managed to get code virtualization work with ArcGIS, ArcGIS Pro or AutoCAD. I suspect it's because we are creating an add-on to an existing product rather than directly on Windows. These products must do a certain amount of probing of our dlls to get&amp;nbsp;what they need and ensure all dependencies are present etc.&lt;/P&gt;&lt;P&gt;Method Call Obfuscation and Code Encryption work OK for us.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can use something like JetBrains DotPeek to take a look at how the code looks after obfuscation to get a sense of how well the code is "protected". If you aim is to ensure the logic of your code is not copied then you just need to make it it more time-consuming to&amp;nbsp;deobfuscate than for someone to write it from new. If your aim is to protect a licencing scheme then it may not be sufficient.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Adam&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 26 Oct 2020 16:02:36 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-sdk-questions/obfuscating-an-add-in/m-p/879833#M5617</guid>
      <dc:creator>AdamDavis</dc:creator>
      <dc:date>2020-10-26T16:02:36Z</dc:date>
    </item>
  </channel>
</rss>

