Day of Week Condition

The Current Day of Week condition allows you to restrict access based on which day of the week the request is made. Specify the following details:

Current Day of Week: Select the name of the day from the list. To compare the day specified in the current request with a static value, select Current. To compare a static value with the day specified in the current request, select the name of a day from the list.

Comparison: Specify how the current day of the week is compared to the data in the Value field. Select one of the following types:

  • Comparison: Day of Week: Specifies that you want the values compared as a day of the week. Select one of the following operators:

    • Equals: Allows you to specify a day that the client must match.

    • In Range: Allows you to specify a range of days that the client’s request must fall within, for example, Monday to Friday.

  • Comparison: Regular Expression: Matches: Specifies that you want the values compared as regular expressions. Be aware that regular expression matching uses the entire date of the server in its matching. Therefore if the value you are matching is M, the M can produce a match for months (March and May) and for time zones (such as MST).

    If you select this option, you must also specify a mode. Select one or more of the following:

    • Canonical Equivalence
    • Case Insensitive
    • Comments
    • Dot All
    • Multi-Line
    • Unicode
    • Unix Lines

    For regular expression syntax information, see the Javadoc for java.util.regex.Pattern.

Value: Specify the second value for the comparison. If you select Current for the Current Day of Week field, you need to specify a static value. If you select a static value for the Current Day of the Week field, you need to select Current for the Value field.

If you select Data Entry Field as the value type, days of the week are specified in the following format:

Sun or Sunday
Mon or Monday
Tue or Tuesday
Wed or Wednesday
Thu or Thursday
Fri or Friday
Sat or Saturday

If you selected In Range as the comparison type, specify the first day of the range in the left text box and the end day of the range in the right text box.

Other value types are possible. Your policy requirements determine whether they are useful. If you have set up a Liberty User Profile or an LDAP attribute that corresponds to a day of the week, you can use this option and select your attribute.

Result on Condition Error: Specify what the condition returns when the comparison of the two values returns an error rather than the results of the comparison. Select either False or True. If you do not want the action applied when an error occurs, select False. If you want the action applied when an error occurs, select True.