How to select captive portal user agents?

Given a list of user agents of the type CaptiveNetworkSupport-407.0.1 wispr, CaptiveNetworkSupport/1.0 wispr, CaptiveNetworkSupport-355.200.27 wispr, and CaptiveNetworkSupport wispr, what is the most concise and efficient regular expression that can be used to select these user agents in the following code snippet?

$(if user agent == … )
$(else)

$(endif)