HP-UX AAA Server A.08.02 Administrator's Guide
Example 14 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>")
Parameters
Following are the parameters for the after keyword:
• <attr-spec>: The <attr-spec> parameter is an attribute specification. For more
information on specifying attributes, see “Attribute Specifications” (page 308).
• <after-string>: Must be a quoted string constant.
Operation
Returns the requested substring with same type as the source.
If <after> is specified, the substring starts after the first occurrence of <after-string>.
If <after-last> is specified, the substring starts after the last occurrence of <after-string>.
If <after-string> is not found, the empty string is returned.
314 Customizing the HP-UX AAA Server Using Policies