Failed to create Identity from tokens

Allan Zimmermann

 
Content is edited
/My-Page/5821/

Re: Failed to create Identity from tokens

Hi Allen,

That error message translate to "Authentication Failed", for whatever reason - but that reason is probably somewhere else in the stack trace.

Was else was in the stack trace?

Best regards.

/My-Page/6538/

Re: Failed to create Identity from tokens

Hi Anthony.

That is the full stacktrace. I just reproduced the error. The client gets "An error occured while opening the database. See Log File"

so_log
110912 13:50:34                   Calculate SODirPath=c:\Program Files (x86)\SuperOffice\SuperOffice 7 Windows\SuperOffice.INI. Src: SSuperOfficeIni::InitVariables at .\SuperOfficeIni.cpp v$Revision: line 313
110912 13:50:34            3.1001 SODirPath (c:\Program Files (x86)\SuperOffice\SuperOffice 7 Windows\SuperOffice.INI) did not exist, look for for config path or program dir instead!. Src: SSuperOfficeIni::InitVariables at .\SuperOfficeIni.cpp v$Revision: line 326
110912 13:50:34                   Loading superoffice.ini from path 'c:\Program Files (x86)\SuperOffice\SuperOffice 7 Windows'.
110912 13:50:34                   ConfigFile=c:\Program Files (x86)\SuperOffice\SuperOffice 7 Windows\SuperOffice.CONFIG. Src: SSuperOfficeIni::InitVariables at .\SuperOfficeIni.cpp v$Revision: line 350
110912 13:50:34            3.1001 Could not find Superoffice.Config from path 'c:\Program Files (x86)\SuperOffice\SuperOffice 7 Windows\SuperOffice.CONFIG'. Src: SSuperOfficeIni::InitVariables at .\SuperOfficeIni.cpp v$Revision: line 355
110912 13:50:35                    has ODBC driver. Src: DSNTypes::_ConvertDSToType at .\DSNTypes.cpp v$Revision: line 301
110912 13:50:35                    has db type -1. Src: DSNTypes::_ConvertDSToType at .\DSNTypes.cpp v$Revision: line 415
110912 13:50:35            3.1001 Unsupported database family: 7, type -1; no NetServer configuration changes will be made. If superoffice.config works then you're either lucky or talented. Src: DSNTypes::_UpdateNetServerConfig at .\DSNTypes.cpp v$Revision: line 247
110912 13:50:35                   Calculate SODirPath=p:\SO7\SuperOffice.INI. Src: SSuperOfficeIni::InitVariables at .\SuperOfficeIni.cpp v$Revision: line 313
110912 13:50:35                   Loading superoffice.ini from path 'p:\SO7\SuperOffice.INI'.
110912 13:50:35                   ConfigFile=p:\SO7\SuperOffice.CONFIG. Src: SSuperOfficeIni::InitVariables at .\SuperOfficeIni.cpp v$Revision: line 350
110912 13:50:35                   Loading .net assemblies from path 'q:\SO7\VFS\CSIDL_PROGRAM_FILES\SuperOffice\SuperOffice 7 Windows'.
110912 13:50:35                   ConfigFile=p:\SO7\SuperOffice.CONFIG. Src: SSuperOfficeIni::InitVariables at .\SuperOfficeIni.cpp v$Revision: line 372
110912 13:50:35                   Loading superoffice.config from path 'p:\SO7\SuperOffice.CONFIG'.
110912 13:50:35                   SO7_SOTEST2 has ODBC driver C:\Windows\system32\SQLSRV32.dll. Src: DSNTypes::_ConvertDSToType at .\DSNTypes.cpp v$Revision: line 301
110912 13:50:35                   SO7_SOTEST2 has db type 4. Src: DSNTypes::_ConvertDSToType at .\DSNTypes.cpp v$Revision: line 415
110912 13:50:35                   DEFAULTTRAVEL has db type 32. Src: DSNTypes::_ConvertDSToType at .\DSNTypes.cpp v$Revision: line 415
110912 13:50:35                   SO7_SOTEST2 has ODBC driver C:\Windows\system32\SQLSRV32.dll. Src: DSNTypes::_ConvertDSToType at .\DSNTypes.cpp v$Revision: line 301
110912 13:50:35                   SO7_SOTEST2 has db type 4. Src: DSNTypes::_ConvertDSToType at .\DSNTypes.cpp v$Revision: line 415
110912 13:50:39                   Opening NetServer session. Src: NSSoSession::_OpenSession at .\NSSoSession.clr.cpp v$Revision: line 35

2011-09-12

Level:   FailureAudit
At:      13:50:39

Element:
Message: Failed to create Identity from tokens
Type:    SuperOffice.Exceptions.SoSessionException
Details:
   at SuperOffice.Security.Principal.SoLocalPrincipal.Authenticate()

Environment info:
Version:                        SuperOffice NetServer 7.0 Release (Build: 4167.b)
Database type:                  MSSQL - 8
Database:                       \\sql01\SO7_SOTEST2
StackTrace:                        at SuperOffice.Diagnostics.SoLogger.LogException(EventLogEntryType logType, SoExceptionInfo exception)
   at SuperOffice.Exceptions.SoException.LogException(EventLogEntryType logType)
   at SuperOffice.Security.Principal.SoLocalPrincipal.Authenticate()
   at SuperOffice.SoContext.Authenticate(SecurityToken[] tokens)
   at SuperOffice.SoSession.Authenticate()
   at NSSoSession._OpenSession(SvStr* i_UserId, SvStr* i_Passwrd)
   at _WinMainCRTStartup()

 

-------------------------
Level:   FailureAudit
At:      13:50:39

Element:
Message: Authentication failed
Type:    SuperOffice.Exceptions.SoSessionException
Details:
   at SuperOffice.Security.Principal.SoLocalPrincipal.Authenticate()
   at SuperOffice.SoContext.Authenticate(SecurityToken[] tokens)

Inner Element:
Message: Failed to create Identity from tokens
Type:    SuperOffice.Exceptions.SoSessionException
Details:
   at SuperOffice.Security.Principal.SoLocalPrincipal.Authenticate()

Environment info:
Version:                        SuperOffice NetServer 7.0 Release (Build: 4167.b)
Database type:                  MSSQL - 8
Database:                       \\sql01\SO7_SOTEST2
StackTrace:                        at SuperOffice.Diagnostics.SoLogger.LogException(EventLogEntryType logType, SoExceptionInfo exception)
   at SuperOffice.Diagnostics.SoLogger.LogException(EventLogEntryType logType, Exception exception)
   at SuperOffice.SoContext.Authenticate(SecurityToken[] tokens)
   at SuperOffice.SoSession.Authenticate()
   at NSSoSession._OpenSession(SvStr* i_UserId, SvStr* i_Passwrd)
   at _WinMainCRTStartup()

 

-------------------------

/My-Page/6538/

Re: Failed to create Identity from tokens

/My-Page/6538/

Re: Failed to create Identity from tokens

HeyStick out tongue>

So Super Office’s Licenses Web Service was backup today, so I tried the following.Stick out tongue>

On server 3 that works with database1 but not database2
I ran dbsetup.exe against database2

I then test with client and everything is ok. (So apparently dbsetup.exe did something to the machine)Stick out tongue>

To test this theory I create database3/dbuser3/schema on the SQL server.
Add DNS / and run dbsetup.exe against database3 from machine 3
create config files and test the client. Everything worksStick out tongue>

Go to machine2
add DSN,
open client and test. And it works (????) what the hell?
So I go to a client machine 4
create DSN, open client and test. Same error again "Authentication failed/Failed to create Identity from tokens"Stick out tongue>

This is interesting. But not usefully for solving my problem. I can’t run around on all citric/terminal server and all client computers and run dbsetup and create dummy databases just to make the client's able to talk with more than 1 database. I need to know what is missing from the equation to make a client talk with whatever database I want it to talk to.Stick out tongue>

Make that work and fix the error with dbsetup not parsing parameters correctly when supplying licenses information and you might have a hosting ready product.Stick out tongue>

/My-Page/6538/

Re: Failed to create Identity from tokens

HeyStick out tongue>

I managed to get some of it to work, but god I'm getting sick and tired of SuperOfficeStick out tongue>

Turns out socrm.exe flips out if superoffice.config has configuration/SuperOffice/Security/Cryptography
filled out. Removing that part makes some of it workStick out tongue>

So status quo is.Stick out tongue>

DBSetup.exe - Broken.
Waiting on response from support case about this.
If you run it without parameters and create a new database, when it calls DSRegisterDatabaseWithDialogW DbSetup.dll it asks for both license serial and company name and everything works.
But if you call DBSetup.exe you can’t supply company name, and the call to DSRegisterDatabaseW fails with error 1001 ...Stick out tongue>

Managing SuperOffice/SuperOffice users -
Someone in SuperOffice needs to learn a bit more about coding. You *DON’T* save all you information as static variables. What in the world where these guys thinking when they did that ? Stick out tongue>

Maybe I need a new crash course too, apparently Frank Gynnild managed to get multiple appdomains to work, ( see ) but when I try I just keep getting
System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation.
---> SuperOffice.Exceptions.SoSessionException: Initiate database connection
---> SuperOffice.Exceptions.SoException: Failed to initiatedatabase connection
---> SuperOffice.Exceptions.SoException: Failed to invoke the ToSql(...) method with argument(s): [SuperOffice.Data.SQL.FieldInfo]
---> System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation.
---> System.Collections.Generic.KeyNotFoundException: The given key was not present in the dictionaryStick out tongue>

/My-Page/6538/

Re: Failed to create Identity from tokens

Ok, i managed to get the whole appdomain part to work.
Source code is downloadable from my blog if anyone else needs something like that.

So that just leave dbsetup.exe and funny enough; getting the client to work.

/My-Page/6538/

Re: Failed to create Identity from tokens

Hey

All problems have been solved.

DBSetup not working when called from commandline.
It does. Turns out that "Contact Name" parameter is the company name from you license.

Client Throwing "Failed to create Identity from tokens" when normal users logon though citrix/RDP servers.
I swear too god, I was 100% sure that with SuperOffice 7; users dont need have access to the database anymore. That all communication was done though the inital connection made with the DBUser/DBPassword you suply in superoffice.config's Explicit section.
Turns out i was dead wrong. But if you add the user as a windows user on the sql server and grant them minimum dbreader/dbwriter .. or create a windows group, add it to the sql server with minimum rights and all all the users to that group, it works.

/My-Page/6518/

Re: Failed to create Identity from tokens

Dear Allan, Could you please help me in a similar issue that u faced. Could you please have a look at my post :

http://devnet.superoffice.com/forums/ShowPost.aspx?PostID=16162

I am receiving similar error messages as you are. Please find a copy of my error log attached with this post:

Looking forward to hear from you.

Thanks and Regards,
Gaurav

/My-Page/6538/

Re: Failed to create Identity from tokens

Turns out the solution is not addin the users to the database.

When i was adding the ODBC DSN link, i had Trusted_Connection = Yes .. This is suppose to be "No" ...

You need to be a member of this group to post

Tags

  1. 7.126 Tagged items
  2. 7.531 Tagged items
  3. audience154 Tagged items
  4. cs1246 Tagged items
  5. cs733 Tagged items
  6. csv4476 Tagged items
  7. csv7790 Tagged items
  8. customer service33 Tagged items
  9. devnet18 Tagged items
  10. devnet211 Tagged items
  11. ejscript35 Tagged items
  12. email19 Tagged items
  13. emarketing35 Tagged items
  14. filter14 Tagged items
  15. generalv6620 Tagged items
  16. generalv7204 Tagged items
  17. import19 Tagged items
  18. intellisync42 Tagged items
  19. maillink24 Tagged items
  20. netserver45 Tagged items
  21. nsv21171 Tagged items
  22. nsv32497 Tagged items
  23. nsv7274 Tagged items
  24. pocket16 Tagged items
  25. pocketcrm323 Tagged items
  26. sm1185 Tagged items
  27. sm737 Tagged items
  28. sm7.161 Tagged items
  29. smv65724 Tagged items
  30. smv7679 Tagged items
  31. ticket9 Tagged items
  32. web37 Tagged items
  33. windows beta250 Tagged items