# File System Service Provider for the
Java Naming and Directory InterfaceTM (JNDI) 1.2
Optional Package

Please send feedback to jndi@java.sun.com

Table of Contents

- Introduction
- JavaTM 2 SDK, Standard Edition, v 1.3
- JavaTM 2 SDK, Standard Edition, v 1.2.x
- JDKTM 1.1.x

## Introduction

This document describes how to use the file system service provider with the Java 2 SDK, Standard Edition, v 1.3, the Java 2 SDK, Standard Edition, v 1.2.x, and the JDK 1.1.x. It is a companion to the main File System Service Provider document.

## Java 2 SDK, Standard Edition, v 1.3

#### Software Installation

1. Unzip the distribution file to get a `lib` directory.
2. If you are installing the file system provider as an installed extension, copy `fscontext.jar` and `providerutil.jar` from the `lib` directory to the `$JAVA_HOME/jre/lib/ext` directory.
3. If you are not installing the file system provider as an installed extension, copy the `fscontext.jar` to its permanent location and add its locations to your classpath.

#### Security Considerations

When a security manager has been installed, you must grant to the application using JNDI and the file system service provider the following permissions:

    permission java.io.FilePermission file, actions;

> For the files and directories identified in the `java.naming.provider.url` property and in file names supplied to context methods. file specifies the files or directories; actions is a list of actions ("read", "write", "delete", "execute"). See `java.io.FilePermission` for details.

If you have installed the file system service provider as an installed extension, that is, `fscontext.jar` has been installed in the `$JAVA_HOME/jre/lib/ext` directory, you need to take no further action.

Otherwise, perform the following additional step:

- Grant the permissions listed above to the file system service provider (`fscontext.jar`).

  ## Java 2 SDK, Standard Edition, v 1.2.x

  #### Software Dependencies

  - JNDI 1.2.

  #### Software Installation

  1. Unzip the distribution file to get a `lib` directory.
  2. If you are using JNDI as an installed extension, copy the JARs (`fscontext.jar` and `providerutil.jar`) from the `lib` directory to the `$JAVA_HOME/jre/lib/ext` directory.
  3. If you are not using JNDI as an installed extension, copy the JARs to their permanent locations and add their locations to your classpath.

  #### Security Considerations

  When a security manager has been installed, you must grant to the application using JNDI and the file system context service provider the following permissions:

      permission java.io.FilePermission file, actions;

  > For the files and directories identified in the `java.naming.provider.url` property and in file names supplied to context methods. file specifies the files or directories; actions is a list of actions ("read", "write", "delete", "execute"). See `java.io.FilePermission` for details.

  If you are using JNDI and the file system service provider as an installed extension, that is, their JARs have been installed in the `$JAVA_HOME/jre/lib/ext` directory, you need to take no further action.

  Otherwise, perform the following additional steps:

  - Grant the permissions listed above to the file system service provider (`fscontext.jar`, `providerutil.jar`) and JNDI (`jndi.jar`).
  - Grant the permissions listed in the JNDI 1.2 Optional Package document.

    ## JDK 1.1.x

    #### Software Dependencies

    - JNDI 1.2.

    #### Software Installation

    1. Unzip the distribution file to get a `lib` directory.
    2. Copy the JARs (`fscontext.jar` and `providerutil.jar`) from the `lib` directory to its permanent location.
    3. Add the location of the JARs to your classpath.

    #### Security Considerations

    Follow the instructions in the JNDI Optional Package document.

    If you are using JNDI and the file system service provider from an applet, you need to grant the applet permission to read the files and directories that it will be accessing via `java.naming.factory.initial` property and in file names supplied to context methods.

    Copyright © 1999 Sun Microsystems, Inc., All Rights Reserved.