Home - Forums-.NET - Spices.Net - System.TypeLoadException was unhandled Message: An unhandled exception of type 'System.TypeLoadException' occurred in mscorlib.dll

Spices.Net

NET code security, tools to protect, obfuscate, tamper defense, code and data safety, recover, convert, optimize, explore, browse and analyze .Net software.

This forum related to following products: Spices.Net Suite, Spices.Net Obfuscator, Spices.Net Decompiler

System.TypeLoadException was unhandled Message: An unhandled exception of type 'System.TypeLoadException' occurred in mscorlib.dll
Link Posted: 15-Jan-2015 15:09
I get the following error after trying to run my obfuscated assembly:
System.TypeLoadException was unhandled
Message: An unhandled exception of type 'System.TypeLoadException' occurred in mscorlib.dll
Additional information: Type 'ADODB.Connection15' from assembly 'CollectPlus9, Version=9.1.167.0, Culture=neutral, PublicKeyToken=null' contains more methods than the current implementation allows.

This is my iloprj file:

  
    
      
      
      
      
      Custom
    
  
  
  
  
    *
  
  
  
  
    *
  
  
  
  
    
      VSProject
      
        
          StringEncryption
          True
          None
          EnhancedEncrypt
          
          
        
      
      obfuscatethis_cp\CollectPlus9.exe
    
    
      
        
          StringEncryption
          True
          None
          EnhancedEncrypt
          
          
        
      
      obfuscatethis_cp\CreditSoft.dll
    
  
  Spices_output_cp\
  Skip
  False
  False
  <?xml version="1.0" encoding="utf-16"?>
<Layout>
  <Window Guid="d011ae1a-b131-40cb-8ce1-4454c2694fcd" LastFocused="130602156030833224" DockedSize="406" PopupSize="0" FloatingLocation="-1, -1" FloatingSize="250, 400" LastOpenDockSituation="Docked" LastFixedDockSituation="Docked" LastFixedDockLocation="Left" LastFloatingWindowGuid="00000000-0000-0000-0000-000000000000" LastDockContainerCount="1" LastDockContainerIndex="0" DockedWorkingSize="530, 456" DockedWindowGroupGuid="6a16888a-0a32-4b86-8b58-3a9dd8633dc6" DockedIndexInWindowGroup="1" DockedSplitPath="0" DocumentWorkingSize="250, 400" DocumentWindowGroupGuid="00000000-0000-0000-0000-000000000000" DocumentIndexInWindowGroup="0" DocumentSplitPath="0" FloatingWorkingSize="250, 400" FloatingWindowGroupGuid="00000000-0000-0000-0000-000000000000" FloatingIndexInWindowGroup="0" FloatingSplitPath="0" />
  <Window Guid="16bbe2d2-5504-4cd4-82f2-6737d26493b8" LastFocused="0" DockedSize="406" PopupSize="0" FloatingLocation="-1, -1" FloatingSize="250, 400" LastOpenDockSituation="Docked" LastFixedDockSituation="Docked" LastFixedDockLocation="Left" LastFloatingWindowGuid="00000000-0000-0000-0000-000000000000" LastDockContainerCount="1" LastDockContainerIndex="0" DockedWorkingSize="530, 456" DockedWindowGroupGuid="6a16888a-0a32-4b86-8b58-3a9dd8633dc6" DockedIndexInWindowGroup="2" DockedSplitPath="0" DocumentWorkingSize="250, 400" DocumentWindowGroupGuid="00000000-0000-0000-0000-000000000000" DocumentIndexInWindowGroup="0" DocumentSplitPath="0" FloatingWorkingSize="250, 400" FloatingWindowGroupGuid="00000000-0000-0000-0000-000000000000" FloatingIndexInWindowGroup="0" FloatingSplitPath="0" />
  <Window Guid="1ab51f96-7428-4b68-9f25-0af0d8415f26" LastFocused="0" DockedSize="406" PopupSize="0" FloatingLocation="-1, -1" FloatingSize="250, 400" LastOpenDockSituation="Docked" LastFixedDockSituation="Docked" LastFixedDockLocation="Left" LastFloatingWindowGuid="00000000-0000-0000-0000-000000000000" LastDockContainerCount="1" LastDockContainerIndex="0" DockedWorkingSize="530, 456" DockedWindowGroupGuid="6a16888a-0a32-4b86-8b58-3a9dd8633dc6" DockedIndexInWindowGroup="0" DockedSplitPath="0" DocumentWorkingSize="250, 400" DocumentWindowGroupGuid="00000000-0000-0000-0000-000000000000" DocumentIndexInWindowGroup="0" DocumentSplitPath="0" FloatingWorkingSize="250, 400" FloatingWindowGroupGuid="00000000-0000-0000-0000-000000000000" FloatingIndexInWindowGroup="0" FloatingSplitPath="0" />
  <Container Dock="3" ContentSize="406">
    <SplitLayoutSystem WorkingSize="250, 400" SplitMode="0">
      <ControlLayoutSystem WorkingSize="530, 456" Guid="6a16888a-0a32-4b86-8b58-3a9dd8633dc6" Collapsed="0" SelectedControl="d011ae1a-b131-40cb-8ce1-4454c2694fcd">
        <Controls>
          <Control Guid="1ab51f96-7428-4b68-9f25-0af0d8415f26" />
          <Control Guid="d011ae1a-b131-40cb-8ce1-4454c2694fcd" />
          <Control Guid="16bbe2d2-5504-4cd4-82f2-6737d26493b8" />
        </Controls>
      </ControlLayoutSystem>
    </SplitLayoutSystem>
  </Container>
</Layout>



This is how I am calling the obfuscator:
"c:\program files (x86)\9Rays.Net\SpicesNet5\Bin\nrobfuscator.exe" /skipresolve /SRC=c:\versioning9\CP9Solution.iloprj /PATHS=c:\versioning9\obfuscatethis_cp

The obfuscatethis_cp has all the binaries that run fine on the same machine.

Here are the first lines of the console output:
C:\versioning9>"c:\program files (x86)\9Rays.Net\SpicesNet5\Bin\nrobfuscator.exe
" /skipresolve /SRC=c:\versioning9\CP9Solution.iloprj /PATHS=c:\versioning9\obfu
scatethis_cp
9Rays.Spices.Obfuscator.Net Console 5.8.5.1
9Rays.Net (c) 2014. All rights reserved
License Info:
              Type:   Spices.Obfuscator console
              User:   Carlos Gonzalez
              E-mail: cgonzalez@icco.com
------Loading project------
Search path:c:\versioning9\obfuscatethis_cp added to ILOProject.SearchPaths coll
ection.
------Project loaded------
------Preparing referenced assemblies------
------Preparing referenced assemblies finished------
Search path:c:\versioning9\obfuscatethis_cp added to ILOProject.SearchPaths coll
ection.
Warning: Assembly(CreditSoft) is signed but StrongNameKeyFile for the Spices.Pro
ject or for this assembly hasn't been specified.
---- Start preparing substitutions and excludes ----
---- Finish preparing substitutions (0 items) and excludes (0 items)----
----Start of obfuscation c:\versioning9\obfuscatethis_cp\CreditSoft.dll --------
----
--- Start obfuscate properties of c:\versioning9\obfuscatethis_cp\CreditSoft.dll


What do you think is causing the error when I run the obfuscated binaries?
Link Posted: 16-Jan-2015 12:30
Seems you've obfuscated and tested already obfuscated assembly/executable.
Please check it.
And please, send us (develop @ 9rays.net) your spices.project file and obfuscated assembly to analyze and get more information/recommendations.
Link Posted: 16-Jan-2015 14:50
OK. I just emailed them. Thank you!
Link Posted: 16-Jan-2015 14:51
The email was rejected. I will try renaming the zip extension to something else.

Your message wasn't delivered because the recipient's email provider rejected it.
mx.google.com gave this error:
This message was blocked because its content presents a potential security issue. Please visit http://support.google.com/mail/bin/answer.py?answer=6590 to review our message content and attachment content guidelines. ue3si7079598pab.125 - gsmtp