Skip to content
This repository was archived by the owner on Apr 15, 2025. It is now read-only.

Is there a way to prevent "infinity" reconnection when the OpenVPN server is shut down? #419

@jarakys

Description

@jarakys

Hello everyone,

Is there a way to prevent "infinity" reconnection when the OpenVPN server is shut down? I have the following rules:

let onDemandRule = NEOnDemandRuleConnect()
onDemandRule.interfaceTypeMatch = .wiFi
let onDemandRule1 = NEOnDemandRuleConnect()
onDemandRule1.interfaceTypeMatch = .cellular
var extra = NetworkExtensionExtra()
extra.disconnectsOnSleep = false
extra.passwordReference = passwordReference
extra.onDemandRules = [onDemandRule, onDemandRule1]

When the server is shut down, the app keeps trying to reconnect endlessly. Is there a way to avoid this? I cannot "ping" the server because when the OpenVPN server is shut down, I don't have an internet connection as the app keeps trying to reconnect.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions