LDAPviewer

Shell Files

Shell files are supported by some specialized editors to create skeleton configurations for complex attribute parameters sets. In general, they provide all possible parameters that can be used (typically with their default values if appropriate) for a user selected style or type of configuration, for example, TLS or SASL. The user can edit or delete the supplied parameters as required. Shells offer a number of potential advantages:

  1. Defensive Configuration: By reducing the effort required defensive configurations are easier to configure.

  2. Ommisions: By providing all possible parameters it reduces the chance of overlooking significant parameters.

  3. Custom Style: The *.shell and *.menu files can be customized for site/application specific values or to enforce in-house rules or conventions.

  4. Note: A defensive configuration is defined as:

    1. All parameters are included even those with acceptable default values. This guards against future changes to default values in version updates.

    2. By defining all parameters maintenance and potential errors are reduced by not requiring support personnel or administrators to either know, or have to look up, the default values of silent parameters.

    Shell File System

    The shell system comprises two parts a *.menu file and *.shell file. Both are text files and may be edited using any appropraite text editor. Line ends may be either Windows or Unix format.

    Shell File Naming

    Shell files are maintained in the misc resource directory. The shell file contains the configuration parameters and is named lower-case-object-name.shell. The menu file contains the values that are placed on the selection menu and is named lower-case-object-name.menu.

    Shell files consist or one or more lines of text The generic line format is:

    # comment
    text
    

    Line commencing with # are assumed to be comments and are ignored in subsequent processing. The text is added to the configuration selection menu 'as is' and in the order in which it is read from the file. No length limits are enforced but the text should be limited to 50 characters or less. A maximum of 10 non-comment lines may appear in this file. If more than 10 are present the first 10 will be used.

    Shell File Format

    Shell files consist or one or more lines of text The generic line format is:

    # comment
    [i] text
    

    Lines starting with # are comments and never appear in the output. The value i always appears inside [] and may take the character value A (not case sensitive) which indicates it is applicable to all configurations, or the numeric value 0 - 9 which represents the index (starting from 0) in the drop-down menu from which the configuration is selected. There may be any number of numeric values. If A is used it should appear alone.

    Example Menu and Shell Files

    A menu file called example-attribute.menu is defined thus:

    # this is a local comment
    All Parameters
    TLS Configuration
    SASL Configuration
    

    This displays a configuration selection menu as shown:

    Shell files - shell selection

    The following is a commented example-attribute.shell file that indicates what would be output based on user selections:

    # the following line would be output in all cases
    [a] line 1
    # the following line would be output if user selects
    # All Parameters from menu
    [0] line 2
    # the following line would be output if user selects
    # TLS Configuration from menu
    [1] line 3
    # the following line would be output if user selects
    # either TLS Configuration or SASL Configuration from menu
    [12] line 4
    

© LV Project 2016. Creative Commons Attribution 4.0 International License.