nerdexam
F5

101 · Question #219

A virtual server is listening at 10.10.1.100:any and has the following iRule associated with it: when CLIENT_ACCEPTED { if {[TCP::local_port] equals 21 } { pool ftppool } elseif {[TCP::local_port] equ

The correct answer is D. Unknown. The pool cannot be determined from the information provided.. The iRule handles only ports 21 and 23 with no else clause, so a connection on port 22 may fall to a virtual server default pool that is not specified in the given information.

Section 2: F5 Solutions and Technology

Question

A virtual server is listening at 10.10.1.100:any and has the following iRule associated with it:

when CLIENT_ACCEPTED { if {[TCP::local_port] equals 21 } { pool ftppool } elseif {[TCP::local_port] equals 23 } { pool telnetpool } If a user connects to 10.10.1.100 and port 22, which pool will receive the request.

Options

  • Aftppool
  • Btelnetpool
  • CNone. The request will be dropped.
  • DUnknown. The pool cannot be determined from the information provided.

How the community answered

(47 responses)
  • A
    17% (8)
  • B
    9% (4)
  • C
    32% (15)
  • D
    43% (20)

Why each option

The iRule handles only ports 21 and 23 with no else clause, so a connection on port 22 may fall to a virtual server default pool that is not specified in the given information.

Aftppool

ftppool is only selected when TCP::local_port equals 21; a connection on port 22 does not satisfy that condition.

Btelnetpool

telnetpool is only selected when TCP::local_port equals 23; a connection on port 22 does not satisfy that condition.

CNone. The request will be dropped.

The request is not necessarily dropped - if the virtual server has a default pool assigned, that pool would handle the connection, but this cannot be confirmed from the information given.

DUnknown. The pool cannot be determined from the information provided.Correct

When a client connects on port 22, neither the ftppool condition (port 21) nor the telnetpool condition (port 23) is satisfied, and the iRule contains no else or default routing clause. Because the provided information does not indicate whether the virtual server has a default pool configured, the pool that will ultimately receive the request cannot be determined from the given information alone.

Concept tested: F5 iRule TCP port-based routing with no default branch

Source: https://clouddocs.f5.com/api/irules/TCP__local_port.html

Topics

#iRules#CLIENT_ACCEPTED event#TCP port matching#default pool behavior

Community Discussion

No community discussion yet for this question.

Full 101 Practice