logo

Authentication as a Windows user

This article describes signing in to the database server as a Windows user. Keep in mind, that the user, who started the ELMA server must have the administrator permissions to Windows and MS SQL (or FireBird).

If the server is installed on Cassini, press Windows + R and enter the command services.msc, which will open the Windows services. Find the ELMA Web Server, right-click on it and select Properties. Switch to the Log On tab. Specify the LocalSystem account or another account with the administrator permissions and restart the web server.

If the server is installed on IIS, open the IIS Manager (Start - Administrative Tools). Go to Application Pools, right-click on the ELMA3-[Edition] pool and select Advanced Settings. Find the Process Model unit and in the Identity field specify the LocalSystem account or another account with the administrator permissions and restart the web server.

Creating credentials in SQL Server Management Studio

  1. In the object explorer, expand the Security folder. 
  2. Right-click on the Credentials folder and select New Credential
  3. In the New Credential dialog box, in the Credential name specify the name for the credentials. 
  4. In the Identity field, specify the identity, used for outgoing connections. Usually, this is a Windows account, however, you can use an account of another type as the identity. Or click on the (...) button, to open the Select User or Group dialog box. 
  5. In the Password and Confirm Password fields enter the password for the specified Identity. If you specify a Windows account in the Identity field, use the Windows password. The Password field may be empty if a password is not required. 
  6. Check the Use Encryption Provider box, so that the credentials were checked by the provider. 
  7. Click ОК.

Authentication in SQL Server

There are two authentication types in SQL Server Windows Authentication or SQL Server Authentication. Changing the authentication type on the server using SSMS (SQL Server Management Studio) or EM (Enterprise Manager) is simple, just open the Security tab in properties and select the required option.

After that, restart the MSSQLSERVER service.

If you are using the free edition MSDE(2000) or Express (2005/2008) without client utilities installed, keep in mind that authentication settings are stored in the registry. 

Using the undocumented procedure T-SQL xp_instance_regwrite, via the utilities OSQL/SQLCMD, change the value (Windows Authentication mode; SQL Server and Windows Authentication mode) EXEC xp_instance_regwrite N’HKEY_LOCAL_MACHINE’, N’Software\Microsoft\MSSQLServer\MSSQLServer’, N’LoginMode’, REG_DWORD, 1 After changing the authentication type, restart the service. You can stop it with T-SQL (the xp_servicecontrol procedure is also undocumented): EXEC master..xp_servicecontrol ’stop’, ’MSSQLSERVER’ However will not be able to start the service with T-SQL, since it is stopped, but if you have a second instance, then execute the following in it: EXEC master..xp_servicecontrol ’start’, ’MSSQLSERVER’ To restart the service, use the commands: net stop MSSQLSERVER/net start MSSQLSERVER 

The final query for changing the authentication type on the server will look like this (you can insert the code into a bat file and use it when necessary):

SQLCMD -E -q "EXEC xp_instance_regwrite N’HKEY_LOCAL_MACHINE’, N’Software\Microsoft\MSSQLServer\MSSQLServer’, N’LoginMode’, REG_DWORD, 1"
net stop MSSQLSERVER
net start MSSQLSERVER

Creating credentials in FireBird 

Only the SYSDBA user can delete, change and create any number of accounts for different user categories.

The structure of a user account: 

•  UserName - username. Up to 31 characters. Non-case-sensitive.

•  Password - user password, case-sensitive. Up to 32 characters, however, only the first eight matter.

•  UID - Integer, user ID.

•  GID - Integer, group ID.

•  FirstName - Name. Up to 17 characters.

•  MiddleName - Middle name. Can be used as a patronymic. Up to 17 characters.

•  LastName - Last name. Up to 17 characters.

Only the username and password are required.

Launch IBExpert. Click Tools and select User Manager. The User Manager window will open. In the Server drop-down list select ( local ).

Click Connect next to the Server drop-down list. Server Login window will appear.

The Login field contains the SYSDBA username. In the Password field enter masterkey (or another password, if you've changed it) and click OK. The list of accounts will open, with only the SYSDBA user.

Click Add. In the New User window enter the username (non-case-sensitive) and the password in the fields Password and Confirm Password. Click OK. A new user account will be added.

To change an existing account (any fields except for username) click Edit or double-click on the required account and edit the fields in the opened window.

To delete an account, click Delete and confirm the action in the dialog box.

To change a username, you are going to have to delete the account and create a new one.

If you are working in IBExpert and gsec or another program simultaneously to add or edit accounts, click Refresh to see the new items in the list in IBExpert.