pingcastle icon indicating copy to clipboard operation
pingcastle copied to clipboard

Pingcastle crash, probably new RPC tests

Open ruppde opened this issue 4 months ago • 0 comments

Pingcastle 3.2.0.0 crashed with the error below:

...
[14:12:45] Gathering WSUS data
[14:13:27] Gathering MSOL data
The AD query failed. Using the alternative protocol (LDAPConnection)
The AD query failed. Using the alternative protocol (LDAPConnection)
The AD query failed. Using the alternative protocol (LDAPConnection)
The AD query failed. Using the alternative protocol (LDAPConnection)
The AD query failed. Using the alternative protocol (LDAPConnection)
The AD query failed. Using the alternative protocol (LDAPConnection)
[14:13:27] Gathering domain controller data (including null session) (including RPC tests)
[14:13:27] An exception occured when doing the task: application domain
Note: you can run the program with the switch --log to get more detail
Exception: Destination array was not long enough. Check destIndex and length, and the array's lower bounds.
   at System.Array.Copy(Array sourceArray, Int32 sourceIndex, Array destinationArray, Int32 destinationIndex, Int32 length, Boolean reliable)
   at PingCastle.RPC.RpcFirewallChecker..ctor(Guid interfaceId, String pipe, UInt16 majorVersion, UInt16 minorVersion, Int32 maxOpNum) in c:\git\PingCastle\RPC\rpcfirewallchecker.cs:line 31
   at PingCastle.RPC.RpcFirewallChecker.TestFunctions(String server, Guid interfaceId, String pipe, UInt16 majorVersion, UInt16 minorVersion, Dictionary`2 functionsToTest) in c:\git\PingCastle\RPC\rpcfirewallchecker.cs:line 103
   at PingCastle.Healthcheck.HealthcheckAnalyzer.TestFirewallRPCDC(HealthcheckDomainController DC, Int32 threadId) in c:\git\PingCastle\Healthcheck\HealthcheckAnalyzer.cs:line 5312
   at PingCastle.Healthcheck.HealthcheckAnalyzer.<>c__DisplayClassbc.<GenerateDomainControllerData>b__b9(Object index) in c:\git\PingCastle\Healthcheck\HealthcheckAnalyzer.cs:line 5200
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
   at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
   at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
   at System.Threading.ThreadHelper.ThreadStart(Object obj)

Unhandled Exception: System.ArgumentException: Destination array was not long enough. Check destIndex and length, and the array's lower bounds.
   at System.Array.Copy(Array sourceArray, Int32 sourceIndex, Array destinationArray, Int32 destinationIndex, Int32 length, Boolean reliable)
   at PingCastle.RPC.RpcFirewallChecker..ctor(Guid interfaceId, String pipe, UInt16 majorVersion, UInt16 minorVersion, Int32 maxOpNum) in c:\git\PingCastle\RPC\rpcfirewallchecker.cs:line 31
   at PingCastle.RPC.RpcFirewallChecker.TestFunctions(String server, Guid interfaceId, String pipe, UInt16 majorVersion, UInt16 minorVersion, Dictionary`2 functionsToTest) in c:\git\PingCastle\RPC\rpcfirewallchecker.cs:line 103
   at PingCastle.Healthcheck.HealthcheckAnalyzer.TestFirewallRPCDC(HealthcheckDomainController DC, Int32 threadId) in c:\git\PingCastle\Healthcheck\HealthcheckAnalyzer.cs:line 5312
   at PingCastle.Healthcheck.HealthcheckAnalyzer.<>c__DisplayClassbc.<GenerateDomainControllerData>b__b9(Object index) in c:\git\PingCastle\Healthcheck\HealthcheckAnalyzer.cs:line 5200
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
   at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
   at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
   at System.Threading.ThreadHelper.ThreadStart(Object obj)

It was running on a non-domain-joined system in a runas-cmd.exe. PingCastle_3.1.0.1 worked flawless with the same machine & user. update: the same happens on a domain-joined system

ruppde avatar Feb 08 '24 14:02 ruppde