Matching User Names

A user name is supplied with all print jobs sent to Pharos. In certain situations, the user name string may have been altered, so that it cannot be recognized as the name of a User account in the Pharos system. For example, when sent from a UNIX server via TCP/IP, print jobs may have the attached user name appended with an IP address. This alteration (or "mangling") happens the same way to all users' names, so it is possible to define a Regular Expression against which all user name strings can be compared. The regular expression defines which part of the string is the actual user name, and which part(s) can be disregarded.

Multiple Regular Expressions can be defined in the Pharos system and applied in turn, to account for jobs being sent to Pharos from multiple systems, which may mangle user names in different ways. If the user name attached to an incoming print job is not found in the Pharos Database, the system applies Regular Expressions in a set order, stopping when a match is found.

Regular Expressions are configured on the Regular Expressions section of the System Settings context:

To add a new Regular Expression, click the Insert button on the right of the Regular Expressions tab ( ). This creates a new Regular Expression entry, which you can then configure.

To delete an existing expression, click the Delete button on the right of the Regular Expressions tab ( ).

Regular Expression Properties

Order By

This value indicates the regular expression's place in the order of precedence. If the user name attached to an incoming print job is not found in the Pharos Database, the system applies all Regular Expressions in order (starting at the top of the list), stopping when a match is found.

To change the order in which Regular Expressions are applied, select an expressions and use the or buttons to move it up or down the list.

Pre-match

This string defines any characters that are added to the user name string before the actual user name, which should be disregarded by the system. Pre-match strings must be written in a specific format.

For example, print jobs arriving from Novell Netware may have a user string which looks like: /o=.../on=.../un=.../n=george, where "george" is the actual user name. A pre-match string that matches everything before "george" is required (for example "any number of characters, followed by /n=", which would look like: .*/n=).

To change an expression's pre-match string, enter a new string into this field.

Match

This string defines the portion of the user name string that matches the actual user name. Match strings must be written in a specific format.

For example, where alphanumeric user names of any length are used, [a-zA-Z0-9]* ("any number of lower case characters, upper case characters, or numbers") will match all user names.

To change an expression's match string, enter a new string into this field.

Uniprint uses regular expressions to match print job user names to user accounts; the second default regular expression truncates the username before the space. For example, john smith becomes john. If you want Uniprint to accept Logon IDs with spaces (e.g. john smith), you can edit or remove the second default regular expression. In the Match column of the second regular expression, remove the space between the caret and the parenthesis as follows: [^(]+.

Post-match

This string defines any characters that are added to the user name string after the actual user name, which should be disregarded by the system. Post-match strings must be written in a specific format.

For example, print jobs arriving from a UNIX server may have a user string which looks like: george (192.168.2.87), where "george" is the actual user name. A post-match string that matches everything after "george" is required (for example "a space, followed by a left bracket, followed by any number of characters, which would look like: [ ][(].*).

To change an expression's post-match string, enter a new string into this field.