Unhandled SecurityException because ADXRegistry.OpenKey

Add-in Express™ Support Service
That's what is more important than anything else

Unhandled SecurityException because ADXRegistry.OpenKey
 
Gutek Jakub




Posts: 39
Joined: 2017-06-06
Hi,

I was looking for the answer on the forum but there is none, there are issues like this but no answer to them.

From 300 users one user have an issue with ADXRegistry.OpenKey. All users are set up exactly the same and software is installed exactly the same (big corp).

One user suffered from the exception message below. I asked IT to check if the user has permissions to:
{HKCU}\Software\Microsoft\Office\{host}\AddIns\{your add-in ProgID} and {HKCU}\Software\Microsoft\Office\{host}\AddIns\ADXXLForm

However, all users are set up exactly the same.


(Inner Exception)
Date and Time:         19.11.2019 09:39:37
Machine Name:          aaa
IP Address:            10.10.190.178
Current User:          zzzxxx

Application Domain:    C:UsersxxxAppDataLocalbbccc
Assembly Codebase:     file:///C:/Windows/Microsoft.NET/Framework/v4.0.30319/mscorlib.dll
Assembly Full Name:    mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
Assembly Version:      4.0.0.0

Exception Source:      mscorlib
Exception Type:        System.Security.SecurityException
Exception Message:     Der angeforderte Registrierungszugriff ist unzul?ssig.
Exception Target Site: ThrowSecurityException

---- Stack Trace ----
   System.ThrowHelper.ThrowSecurityException(resource As ExceptionResource)
       mscorlib.dll: N 0016 (0x10) IL 
   Microsoft.Win32.RegistryKey.OpenSubKey(name As String, writable As Boolean)
       mscorlib.dll: N 0000 (0x0) IL 
   AddinExpress.Projects.Common.ADXRegistry.OpenKey(name As String, writable As Boolean)
       mscorlib.dll: N 0192 (0xC0) IL 



(Outer Exception)
Date and Time:         19.11.2019 09:39:37
Machine Name:          aaa
IP Address:            10.10.190.178
Current User:          zzzxxx

Application Domain:    C:UsersxxxAppDataLocalbbccc
Assembly Codebase:     file:///C:/Users/xxx/AppData/Local/bbb/ccc/AddinExpress.MSO.2005.DLL
Assembly Full Name:    AddinExpress.MSO.2005, Version=9.4.4644.0, Culture=neutral, PublicKeyToken=4416dd98f0861965
Assembly Version:      9.4.4644.0

Exception Source:      AddinExpress.MSO.2005
Exception Type:        System.Exception
Exception Message:     OpenKey failed.
Exception Target Site: OpenKey

---- Stack Trace ----
   AddinExpress.Projects.Common.ADXRegistry.OpenKey(name As String, writable As Boolean)
       AddinExpress.MSO.2005.DLL: N 0292 (0x124) IL 
   AddinExpress.MSO.ADXAddinModule.AddinExpress.MSO.IDTExtensibility2.OnStartupComplete(custom As Array&)
       AddinExpress.MSO.2005.DLL: N 1434 (0x59A) IL
Posted 05 Dec, 2019 11:10:38 Top
Andrei Smolin


Add-in Express team


Posts: 18829
Joined: 2006-05-11
Hello Jakub,

In the code I see that it may also access {HKCU}\Software\Microsoft\Office\{version}.0\Common.


Andrei Smolin
Add-in Express Team Leader
Posted 06 Dec, 2019 08:02:12 Top