none
Problem with .Net Framework Security Policy RRS feed

  • Question

  • Hello,

    We have a problem with a custom application that seems to be related to .Net Framework Security Policies, however, when changing in the client the Runtime Security Policy and setting the intranet with Full Trust as a developer suggested me, the problem isn't solved.

    Should I change the Runtine Security Server Policy in the server too? Any suggestion?

    Thanks in advance.

    I Attach the error log:

    See the end of this message for details on invoking 
    just-in-time (JIT) debugging instead of this dialog box.

    ************** Exception Text **************
    System.Security.SecurityException: Unable to create Hook.
       at System.Windows.Forms.SendKeys.InstallHook()
       at System.Windows.Forms.SendKeys.Send(String keys, Control control, Boolean wait)
       at System.Windows.Forms.SendKeys.SendWait(String keys)
       at FormulariosSubDiarios.subdiario.UltraGrid1_KeyPress(Object sender, KeyPressEventArgs e)
       at System.Windows.Forms.Control.OnKeyPress(KeyPressEventArgs e)
       at Infragistics.Win.UltraWinGrid.UltraGrid.OnKeyPress(KeyPressEventArgs e)
       at System.Windows.Forms.Control.ProcessKeyEventArgs(Message& m)
       at System.Windows.Forms.Control.ProcessKeyMessage(Message& m)
       at System.Windows.Forms.Control.WmKeyChar(Message& m)
       at System.Windows.Forms.Control.WndProc(Message& m)
       at System.Windows.Forms.ControlNativeWindow.OnMessage(Message& m)
       at System.Windows.Forms.ControlNativeWindow.WndProc(Message& m)
       at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)


    ************** Loaded Assemblies **************
    mscorlib
        Assembly Version: 1.0.5000.0
        Win32 Version: 1.1.4322.573
        CodeBase: file:///c:/windows/microsoft.net/framework/v1.1.4322/mscorlib.dll
    ----------------------------------------
    contasys2.0
        Assembly Version: 1.0.4500.14764
        Win32 Version: 1.0.4500.14764
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/contasys2.0.exe
    ----------------------------------------
    System.Windows.Forms
        Assembly Version: 1.0.5000.0
        Win32 Version: 1.1.4322.573
        CodeBase: file:///c:/windows/assembly/gac/system.windows.forms/1.0.5000.0__b77a5c561934e089/system.windows.forms.dll
    ----------------------------------------
    System
        Assembly Version: 1.0.5000.0
        Win32 Version: 1.1.4322.573
        CodeBase: file:///c:/windows/assembly/gac/system/1.0.5000.0__b77a5c561934e089/system.dll
    ----------------------------------------
    XmlUtils
        Assembly Version: 1.0.4500.14721
        Win32 Version: 1.0.4500.14721
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/XmlUtils.DLL
    ----------------------------------------
    Hardkey
        Assembly Version: 1.0.4500.14763
        Win32 Version: 1.0.4500.14763
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/Hardkey.DLL
    ----------------------------------------
    Datos
        Assembly Version: 2.0.2006.0
        Win32 Version: 2.0.2006.0
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/Datos.DLL
    ----------------------------------------
    Usuarios
        Assembly Version: 2.0.2006.1
        Win32 Version: 2.0.2006.1
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/Usuarios.DLL
    ----------------------------------------
    System.Drawing
        Assembly Version: 1.0.5000.0
        Win32 Version: 1.1.4322.573
        CodeBase: file:///c:/windows/assembly/gac/system.drawing/1.0.5000.0__b03f5f7f11d50a3a/system.drawing.dll
    ----------------------------------------
    Parametros
        Assembly Version: 2.0.2006.2
        Win32 Version: 2.0.2006.2
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/Parametros.DLL
    ----------------------------------------
    Conversion
        Assembly Version: 2.0.2006.1
        Win32 Version: 2.0.2006.1
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/Conversion.DLL
    ----------------------------------------
    Infragistics.Win.UltraWinToolbars.v3.1
        Assembly Version: 3.1.20041.15
        Win32 Version: 3.1.20041.15
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/Infragistics.Win.UltraWinToolbars.v3.1.DLL
    ----------------------------------------
    Infragistics.Shared.v3.1
        Assembly Version: 3.1.20041.15
        Win32 Version: 3.1.20041.15
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/Infragistics.Shared.v3.1.DLL
    ----------------------------------------
    Infragistics.Win.v3.1
        Assembly Version: 3.1.20041.15
        Win32 Version: 3.1.20041.15
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/Infragistics.Win.v3.1.DLL
    ----------------------------------------
    Accessibility
        Assembly Version: 1.0.5000.0
        Win32 Version: 1.1.4322.573
        CodeBase: file:///c:/windows/assembly/gac/accessibility/1.0.5000.0__b03f5f7f11d50a3a/accessibility.dll
    ----------------------------------------
    Microsoft.VisualBasic
        Assembly Version: 7.0.5000.0
        Win32 Version: 7.10.3052.4
        CodeBase: file:///c:/windows/assembly/gac/microsoft.visualbasic/7.0.5000.0__b03f5f7f11d50a3a/microsoft.visualbasic.dll
    ----------------------------------------
    Entorno
        Assembly Version: 2.0.2006.9
        Win32 Version: 2.0.2006.9
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/Entorno.DLL
    ----------------------------------------
    System.Data
        Assembly Version: 1.0.5000.0
        Win32 Version: 1.1.4322.573
        CodeBase: file:///c:/windows/assembly/gac/system.data/1.0.5000.0__b77a5c561934e089/system.data.dll
    ----------------------------------------
    FormulariosCopiados
        Assembly Version: 1.0.4500.14763
        Win32 Version: 1.0.4500.14763
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/FormulariosCopiados.DLL
    ----------------------------------------
    System.Xml
        Assembly Version: 1.0.5000.0
        Win32 Version: 1.1.4322.573
        CodeBase: file:///c:/windows/assembly/gac/system.xml/1.0.5000.0__b77a5c561934e089/system.xml.dll
    ----------------------------------------
    System.EnterpriseServices
        Assembly Version: 1.0.5000.0
        Win32 Version: 1.1.4322.573
        CodeBase: file:///c:/windows/assembly/gac/system.enterpriseservices/1.0.5000.0__b03f5f7f11d50a3a/system.enterpriseservices.dll
    ----------------------------------------
    FormulariosEmpresas
        Assembly Version: 1.0.4500.14763
        Win32 Version: 1.0.4500.14763
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/FormulariosEmpresas.DLL
    ----------------------------------------
    Empresas
        Assembly Version: 2.0.2006.2
        Win32 Version: 2.0.2006.2
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/Empresas.DLL
    ----------------------------------------
    ConsultaSQL
        Assembly Version: 2.0.2006.0
        Win32 Version: 2.0.2006.0
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/ConsultaSQL.DLL
    ----------------------------------------
    System.Runtime.Serialization.Formatters.Soap
        Assembly Version: 1.0.5000.0
        Win32 Version: 1.1.4322.573
        CodeBase: file:///c:/windows/assembly/gac/system.runtime.serialization.formatters.soap/1.0.5000.0__b03f5f7f11d50a3a/system.runtime.serialization.formatters.soap.dll
    ----------------------------------------
    FormulariosBalances
        Assembly Version: 1.0.4500.14756
        Win32 Version: 1.0.4500.14756
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/FormulariosBalances.DLL
    ----------------------------------------
    FormulariosListados
        Assembly Version: 1.0.4500.14752
        Win32 Version: 1.0.4500.14752
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/FormulariosListados.DLL
    ----------------------------------------
    FormulariosAyuda
        Assembly Version: 1.0.4500.14763
        Win32 Version: 1.0.4500.14763
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/FormulariosAyuda.DLL
    ----------------------------------------
    FormulariosVentas
        Assembly Version: 1.0.4500.14754
        Win32 Version: 1.0.4500.14754
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/FormulariosVentas.DLL
    ----------------------------------------
    FormulariosCompras
        Assembly Version: 1.0.4500.14756
        Win32 Version: 1.0.4500.14756
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/FormulariosCompras.DLL
    ----------------------------------------
    FormulariosDiarios
        Assembly Version: 1.0.4500.14762
        Win32 Version: 1.0.4500.14762
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/FormulariosDiarios.DLL
    ----------------------------------------
    FormulariosParametros
        Assembly Version: 1.0.4500.14763
        Win32 Version: 1.0.4500.14763
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/FormulariosParametros.DLL
    ----------------------------------------
    FormulariosSubDiarios
        Assembly Version: 1.0.4500.14762
        Win32 Version: 1.0.4500.14762
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/FormulariosSubDiarios.DLL
    ----------------------------------------
    Infragistics.Win.UltraWinEditors.v3.1
        Assembly Version: 3.1.20041.15
        Win32 Version: 3.1.20041.15
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/Infragistics.Win.UltraWinEditors.v3.1.DLL
    ----------------------------------------
    PlandeCuentas
        Assembly Version: 2.0.2006.1
        Win32 Version: 2.0.2006.1
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/PlandeCuentas.DLL
    ----------------------------------------
    CentrodeCostos
        Assembly Version: 2.0.2006.1
        Win32 Version: 2.0.2006.1
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/CentrodeCostos.DLL
    ----------------------------------------
    abm_programas
        Assembly Version: 1.0.4500.14751
        Win32 Version: 1.0.4500.14751
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/abm_programas.DLL
    ----------------------------------------
    Configuraciones
        Assembly Version: 2.0.2006.1
        Win32 Version: 2.0.2006.1
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/Configuraciones.DLL
    ----------------------------------------
    abm_esquemaprorrateo
        Assembly Version: 2.0.2006.0
        Win32 Version: 2.0.2006.0
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/abm_esquemaprorrateo.DLL
    ----------------------------------------
    SubDiarios
        Assembly Version: 2.0.2006.0
        Win32 Version: 2.0.2006.0
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/SubDiarios.DLL
    ----------------------------------------
    Monedas
        Assembly Version: 2.0.2006.1
        Win32 Version: 2.0.2006.1
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/Monedas.DLL
    ----------------------------------------
    Detalles
        Assembly Version: 2.0.2006.1
        Win32 Version: 2.0.2006.1
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/Detalles.DLL
    ----------------------------------------
    ModeloAsiento
        Assembly Version: 1.0.4500.14755
        Win32 Version: 1.0.4500.14755
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/ModeloAsiento.DLL
    ----------------------------------------
    Infragistics.Win.UltraWinGrid.v3.1
        Assembly Version: 3.1.20041.15
        Win32 Version: 3.1.20041.15
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/Infragistics.Win.UltraWinGrid.v3.1.DLL
    ----------------------------------------
    FormulariosModelosAsientos
        Assembly Version: 1.0.4500.14755
        Win32 Version: 1.0.4500.14755
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/FormulariosModelosAsientos.DLL
    ----------------------------------------
    FormulariosMonedas
        Assembly Version: 1.0.4500.14752
        Win32 Version: 1.0.4500.14752
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/FormulariosMonedas.DLL
    ----------------------------------------
    FormulariosDetalles
        Assembly Version: 1.0.4500.14752
        Win32 Version: 1.0.4500.14752
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/FormulariosDetalles.DLL
    ----------------------------------------
    FormulariosEsquemasProrrateo
        Assembly Version: 1.0.4500.14752
        Win32 Version: 1.0.4500.14752
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/FormulariosEsquemasProrrateo.DLL
    ----------------------------------------
    FormulariosProgramas
        Assembly Version: 1.0.4500.14752
        Win32 Version: 1.0.4500.14752
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/FormulariosProgramas.DLL
    ----------------------------------------
    FormulariosCentrosCostos
        Assembly Version: 2.0.2006.0
        Win32 Version: 2.0.2006.0
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/FormulariosCentrosCostos.DLL
    ----------------------------------------
    FormulariosPlanCuentas
        Assembly Version: 1.0.4500.14752
        Win32 Version: 1.0.4500.14752
        CodeBase: file:///C:/Program%20Files/EDYDSI/EDYDSI-CONTASYS%202007/FormulariosPlanCuentas.DLL
    ----------------------------------------

    ************** JIT Debugging **************
    To enable just in time (JIT) debugging, the config file for this
    application or machine (machine.config) must have the
    jitDebugging value set in the system.windows.forms section.
    The application must also be compiled with debugging
    enabled.

    For example:

    <configuration>
        <system.windows.forms jitDebugging="true" />
    </configuration>

    When JIT debugging is enabled, any unhandled exception
    will be sent to the JIT debugger registered on the machine
    rather than being handled by this dialog.



    Gabriel Talavera | MCP

    • Moved by Barry Wang Friday, June 1, 2012 6:40 AM CLR security setting issue (From:.NET Framework Setup)
    Wednesday, May 30, 2012 4:05 PM

Answers

  • Hi, 

    Please provide more details, 

    1. version of .Net 
    2. OS
    3. Which version of Infragistics (seems error raised from UltraGrid) you are using? 

    from: http://msdn.microsoft.com/en-us/library/system.windows.forms.sendkeys.sendwait.aspx

    The SendKeys class has been updated for the .NET Framework 3.0 to enable its use in applications that run on Windows Vista. The enhanced security of Windows Vista (known as User Account Control or UAC) prevents the previous implementation from working as expected.

    If your application relies on consistent behavior regardless of the operating system, you can force the SendKeys class to use the new implementation by adding the following application setting to your app.config file.

    <appSettings>
    <add key="SendKeys" value="SendInput"/>
    </appSettings>



    If this post answers your question, please click "Mark As Answer". If this post is helpful please click "Mark as Helpful".

    Thursday, June 7, 2012 4:27 AM

All replies

  • What is it related code?

    Ghost,
    Call me ghost for short, Thanks
    To get the better answer, it should be a better question.

    Friday, June 1, 2012 7:02 AM
  • Hi, 

    Please provide more details, 

    1. version of .Net 
    2. OS
    3. Which version of Infragistics (seems error raised from UltraGrid) you are using? 

    from: http://msdn.microsoft.com/en-us/library/system.windows.forms.sendkeys.sendwait.aspx

    The SendKeys class has been updated for the .NET Framework 3.0 to enable its use in applications that run on Windows Vista. The enhanced security of Windows Vista (known as User Account Control or UAC) prevents the previous implementation from working as expected.

    If your application relies on consistent behavior regardless of the operating system, you can force the SendKeys class to use the new implementation by adding the following application setting to your app.config file.

    <appSettings>
    <add key="SendKeys" value="SendInput"/>
    </appSettings>



    If this post answers your question, please click "Mark As Answer". If this post is helpful please click "Mark as Helpful".

    Thursday, June 7, 2012 4:27 AM