HP-UX AAA Server A.08.01 administrator's guide (T1428-90072, May 2010)

Table Of Contents
Parameters
Following are the parameters for the before keyword:
<attr-spec>: The <attr-spec> parameter is an attribute specification. For more
information on specifying attributes, see Attribute Specifications” (page 422).
<before-string>: Must be a quoted string constant.
Operation
Returns the requested substring with same type as the source.
If <before> is specified, the substring starts from the beginning of the string up to but
not including the first occurrence of <before-string>.
If <before-last> is specified, the substring starts from the beginning of the string up to
but not including the last occurrence of <before-string>.
NOTE: If <before> or <before-string> is not found, the entire string is returned.
Example 27-4 Examples Illustrating the Use of the before Keyword
If Reply-Message = a string of characters, then:
Example 1
substr ( Reply-Message before " of" )
returns the following string:
a string
Example 2
substr ( Reply-Message before last " " )
returns the following string:
a string of
Example 3
substr ( Reply-Message before "not-there" )
returns the entire string.
NOTE: If <attr-spec> refers to an instance that is not present, then a no-such-instance
run-time error is generated.
The after Keyword
Syntax
substr (<attr-spec> after <after-string>)
substr (<attr-spec> after last "<after-string>")
428 Customizing the HP-UX AAA Server Using Policies