After deploying 2nd LDAPCP: An exception occurred when trying to issue security token...

Sep 8, 2016 at 8:20 AM
Edited Sep 20, 2016 at 4:17 PM
Hi,

I've the following error msg in eventlog:
An exception occurred when trying to issue security token: The server was unable to process the request due to an internal error.  For more information about the error, either turn on IncludeExceptionDetailInFaults (either from ServiceBehaviorAttribute or from the <serviceDebug> configuration behavior) on the server in order to send the exception information back to the client, or turn on tracing as per the Microsoft .NET Framework SDK documentation and inspect the server trace logs..
I had this error before, after I deplyed the LDAPCP the first time... but after deploying the dll on all servers, this error was gone...

after deploying the 2nd ldapcp provider, the error shows up again... but dll is already deployed...
Coordinator
Sep 14, 2016 at 11:38 AM
Hi, this is a very generic error message, you need to check SharePoint logs to get the exact error...
Sep 20, 2016 at 4:03 PM
Edited Sep 20, 2016 at 4:04 PM
Only on Search Servers:
STS Call: Failed to issue new security token. Exception: System.IO.FileNotFoundException: Could not load file or assembly 'Identity.Axxx, Version=1.0.0.0, Culture=neutral, PublicKeyToken=44d426517c6aaeea' or one of its dependencies. The system cannot find the file specified.  File name: 'Identity.Axxx, Version=1.0.0.0, Culture=neutral, PublicKeyToken=44d426517c6aaeea'    
 at System.Reflection.RuntimeAssembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)    
 at System.Reflection.RuntimeAssembly.InternalLoadAssemblyName(AssemblyName assemblyRef, Evidence assemblySecurity, RuntimeAssembly reqAssembly, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)    
 at System.Reflection.RuntimeAssembly.InternalLoad(String assemblyString, Evidence assemblySecurity, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean forIntrospection)    
 at System.Reflection.RuntimeAssembly.InternalLoad(String assemblyString, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection)    
 at System.Reflection.Assembly.Load(String assemblyString)    
 at Microsoft.SharePoint.Administration.Claims.SPClaimProviderDefinition.GetClaimProviderType(String assemblyName, String typeName)    
 at Microsoft.SharePoint.Administration.Claims.SPClaimProviderDefinition.get_ClaimProviderType()    
 at Microsoft.SharePoint.Administration.Claims.SPClaimProviderDefinition.CreateClaimProvider()    
 at Microsoft.SharePoint.Administration.Claims.SPClaimProviderManager.get_EnabledAndTrustedClaimProvidersByName()    
 at Microsoft.SharePoint.Administration.Claims.SPClaimProviderManager.<GetClaimProvidersByName>d__2.MoveNext()    
 at Microsoft.SharePoint.Administration.Claims.SPClaimProviderOperations.ClaimsForEntity(Uri context, SPClaimProviderOperationOptions mode, String[] providerNames, SPClaim entity)    
 at Microsoft.SharePoint.IdentityModel.SPSecurityTokenService.AugmentClaimsIdentityWithClaimProviders(SPRequestInfo requestInfo, IClaimsIdentity identity, SPClaim identityClaim)    
 at Microsoft.SharePoint.IdentityModel.SPSecurityTokenService.AugmentOutputIdentityForRequest(SPRequestInfo requestInfo, IClaimsIdentity outputIdentity)    
 at Microsoft.SharePoint.IdentityModel.SPSecurityTokenService.GetOutputClaimsIdentity(IClaimsPrincipal principal, RequestSecurityToken request, Scope scope)    
 at Microsoft.IdentityModel.SecurityTokenService.SecurityTokenService.Issue(IClaimsPrincipal principal, RequestSecurityToken request)    
 at Microsoft.SharePoint.IdentityModel.SPSecurityTokenService.Issue(IClaimsPrincipal principal, RequestSecurityToken request)    WRN: Assembly binding logging is turned OFF.  To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.  Note: There is some performance penalty associated with assembly bind failure logging.  To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].
Sep 20, 2016 at 4:17 PM
okay, fixed it by adding 2nd ddl... -_-
[System.Reflection.Assembly]::Load("System.EnterpriseServices, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")
$publish = New-Object System.EnterpriseServices.Internal.Publish
$publish.GacInstall("C:\inst\Identity.Axxx.dll")
thank you
Marked as answer by Domsen on 9/20/2016 at 9:17 AM