Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UPnP port mappings should be deleted on graceful shutdown #5532

Open
mickvandijke opened this issue Aug 5, 2024 · 1 comment
Open

UPnP port mappings should be deleted on graceful shutdown #5532

mickvandijke opened this issue Aug 5, 2024 · 1 comment

Comments

@mickvandijke
Copy link

mickvandijke commented Aug 5, 2024

Description

UPnP port mappings should be deleted on graceful shutdown.

Motivation

The lease time for opened UPnP port mappings is quite long. It would be decent to remove any created port mappings on shutdown.

Current Implementation

On shutdown, port mappings just stay alive until the lease time is up.

Are you planning to do it yourself in a pull request ?

No

@jxs
Copy link
Member

jxs commented Aug 5, 2024

Hi, this is quite complex and complicated to achieve without async Drop¹.
That's why also we introduced the TTL, so that mappings are not permanent. Can't you remove the listener and wait for the ExpiredListenAddr event on your application? It will trigger the removal of the upnp mappings

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants