Application Server Solutions for Microsoft IIS and ASP.NET
       solutions   products   partners   company   support   downloads         store
ServletExec Self-Help: FAQ
Back to Search >  Back to Search Results

Faq ID 193
Product JTurbo
Category ArcIMS Users
Question Can JTurbo be used with ESRI's ArcIMS Internet GIS Mapping Server ?
Answer Yes. ArcIMS has a built-in ability to password-protect access to certain GIS mapping services that have been published. The Authentication can be done by checking a database table of users that you setup. Here are some details regarding this:
These instructions assume that you already have the following
software components installed:
1. Web Server
2. Servlet/JSP Engine
3. ArcIMS

And they also assume that if your Servlet/JSP Engine is ServletExec,
that you have password protected access to the Main SE Admin UI,
and that you have successfully tested the password protection
feature, and that you have both SE and ArcIMS working together
as required.

If you are using the ArcIMS Servlet Connector running inside
a Servlet/JSP Engine, and you use Microsoft SQL Server and you want
to restrict access to certain ArcIMS mapping services based on
users defined in your SQL Server database then the following information
may be useful to you.

The ArcIMS Servlet Connector is the Java-based conduit by which your
users access your ArcIMS mapping services via the internet.
It is easily possible to configure your ArcIMS Servlet Connector to
authenticate users of your mapping services, prompting them
to login, and denying access to unauthorized users.

In the world of Java, the most common way that Java programs (such as the
ArcIMS Servlet Connector) communicate with a database (such
as MS SQL Server) is via JDBC (Java Database Connectivity).
Specifically, you would need to obtain a JDBC driver that is
capable of communicating with your database.
JTurbo is a JDBC driver for connecting to MS SQL Server.
It is made by New Atlanta Communications and can be downloaded
for free from:
Detailed information about how to setup ArcIMS for Authentication via a
database and a JDBC driver can be found in the ArcIMS Help web pages which
come with ArcIMS.
For ArcIMS 4.0.1, this information can be found in the following location:
Start - Programs - ArcGIS - ArcIMS - ArcIMS Help
Once viewing the html pages navigate to:
Advanced ArcIMS topics - Restricting user access to services - User
Authentication in the Servlet Connector - Enabling authentication with
a JDBC-based ACL.
The 8 steps given there are very useful and you should read and follow
them. However, do not perform any of those 8 steps until you
first download, install, and learn about the JTurbo driver
from New Atlanta Communications.
You should also download the JTurbo Installation Guide & the JTurbo User
Once installed, JTurbo comes with several examples.
There is really only 1 example that you should bother with.
It is the one named:
The ReadMe.html file in the JTurbo Examples folder tells you how to compile
and run it.
Once you can run that example and you can examine your database to confirm
that it ran successfully, then you are ready for the next step:
Adding the JTurbo.jar file to the classpath of your Servlet/JSP Engine.
How to do this will vary depending upon what brand of Servlet/JSP Engine
you are using, you should consult the documentation that came with 
your Servlet/JSP Engine.
If you are using New Atlanta's ServletExec as your Servlet/JSP engine
then you should look at section 2.3 of the SE 4.1 User Guide.
For example if your JTurbo.jar file resides at:
C:\Program Files\New Atlanta\JTurbo\lib
then you would add
C:\Program Files\New Atlanta\JTurbo\lib\JTurbo.jar
to the main SE classpath and then reinitialize ServletExec.

Then you should perform the 8 steps given in the ArcIMS Help.

For step #2 entitled:
"Edit properties in the Esrimap_prop file"
here are example values for the 13 properties
which must be set:

realm=My ArcIMS Resources

Steps #4, 5, 6, & 7 are summarized by the following 
example DDL (Data Description Language)


1. Setup the User table
The name of this table must be the same as the name you specified in the
Esrimap_prop file for jdbcUserTable.

create table arcIMS_users (userid bigint IDENTITY (1,1) NOT NULL,
                           username varchar(64) NOT NULL,
                           password varchar(64))

setup permissions
grant all on arcIMS_users to public

populate the user table
insert into arcIMS_users values ('*', null)
insert into arcIMS_users values ('user1', 'password1')
insert into arcIMS_users values ('user2', 'password2')
insert into arcIMS_users values ('testuser', 'testuser')

2. Setup the permissions table.
The name of this table must be the same as the name you specified in the
Esrimap_prop file for jdbcPermTable.
create table arcIMS_permissions (userid bigint NOT NULL,
                                 service varchar(64) NOT NULL,
                                 active bigint NOT NULL,
                                 expiration datetime,
                                 tclients varchar(1024),
                                 ftags varchar(1024),
                                 roles varchar(1024))

setup permissions
grant all on arcIMS_permissions to public

populate the permissions table
insert into arcIMS_permissions values (4, 'Esri', 1, null, null, null, null)

Now, any user requesting images or data from the ArcIMS map service named "Esri"
will be prompted by their web browser to Authenticate (i.e. enter their
username and password).
Only the user whose userid = 4 (in the arcIMS_users table) will be allowed access.


If you are having trouble and need to enable debug messages for the JTurbo
JDBC driver, then one way to do this is to create a JSP page or a Servlet
which simply performs the following code when invoked:
java.sql.DriverManager.setLogWriter( new );
Then invoke that JSP or Servlet and then try to access the ArcIMS map service,
which you are trying to password-protect in your browser.

company media information terms of use privacy policy contact us