# Issues with STUN on 1.2.16

**URL:** <https://forum.genieacs.com/t/issues-with-stun-on-1-2-16/7460>\
**Category:** Help\
**Created:** [September 9, 2026, 4:24pm UTC](https://forum.genieacs.com/t/issues-with-stun-on-1-2-16/7460 "2026-09-09T16:24:58Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![dcabanaw](https://yyz1.discourse-cdn.com/flex035/user_avatar/forum.genieacs.com/dcabanaw/32/921_2.png) [@dcabanaw](https://forum.genieacs.com/u/dcabanaw)\
**Post date:** [September 9, 2026, 4:24pm UTC](https://forum.genieacs.com/t/issues-with-stun-on-1-2-16/7460/1 "2026-09-09T16:24:58Z")

</div>

Recently I tried upgrading our test environment from version v1.2.9 to version v1.2.16. With the same configuration on v1.2.16. The server cannot reach out to CPE devices behind NAT using STUN after updating. Reverting back to v1.2.9 corrects the issue.

Anyone know what the cause might be? The only thing I can see off hand is on v1.2.16, the connection request is going out the wrong interface, no matter what binding options I set in the env file.

---

<div class="post-metadata">

**Author:** ![zaidka](https://yyz1.discourse-cdn.com/flex035/user_avatar/forum.genieacs.com/zaidka/32/9_2.png) [@zaidka](https://forum.genieacs.com/u/zaidka)\
**Post date:** [September 16, 2026, 6:15pm UTC](https://forum.genieacs.com/t/issues-with-stun-on-1-2-16/7460/2 "2026-09-16T18:15:56Z")

</div>

Make sure to set the value of `ManagementServer.STUNEnable` to true. v1.2.9 didn’t respect that parameter so that probably explains your situation.

---

<div class="post-metadata">

**Author:** ![dcabanaw](https://yyz1.discourse-cdn.com/flex035/user_avatar/forum.genieacs.com/dcabanaw/32/921_2.png) [@dcabanaw](https://forum.genieacs.com/u/dcabanaw)\
**Post date:** [September 16, 2026, 7:27pm UTC](https://forum.genieacs.com/t/issues-with-stun-on-1-2-16/7460/3 "2026-09-16T19:27:27Z")

</div>

Thanks for looking into this.

The customized firmware we are using on our CPE devices have STUN enabled by default. Would the parameter not explicitly being refreshed in a provision (ie inform) also cause this? If so I imagine adding a declare to keep it refreshed in the inform provision would be enough.

```javascript
// TESTING ONLY inform

// Device ID as user name
const username = declare("DeviceID.ID", { value: 1 }).value[0];

// Password will be fixed for a given device because Math.random() is seeded with device ID by default.
const password = Math.trunc(Math.random() * Number.MAX_SAFE_INTEGER).toString(36);

// const informInterval = 3600;
const informInterval = 120; // fast for testing only in dev network

// Refresh values refresh
// const refresh = Date.now(86400000);
const refresh = Date.now(120000); // fast for testing only in dev network

// Unique inform offset per device for better load distribution
// const informTime = refresh % 86400000;
const informTime = '0000-00-00T00:00:00'; // override for testing

// tr069 data model
declare(
    "InternetGatewayDevice.ManagementServer.ConnectionRequestUsername",
    { value: refresh },
    { value: username },
);
declare(
    "InternetGatewayDevice.ManagementServer.ConnectionRequestPassword",
    { value: refresh },
    { value: password },
);
declare(
    "InternetGatewayDevice.ManagementServer.PeriodicInformEnable",
    { value: refresh },
    { value: true },
);
declare(
    "InternetGatewayDevice.ManagementServer.PeriodicInformInterval",
    { value: refresh },
    { value: informInterval },
);
declare(
    "InternetGatewayDevice.ManagementServer.PeriodicInformTime",
    { value: refresh },
    { value: informTime },
);

// add refresh for STUNEnable
declare(
    "InternetGatewayDevice.ManagementServer.STUNEnable",
    { value: refresh }
);

```

I’ll backup our current config/install and deploy 1.2.16 again with that in mind and report back.

---

<div class="post-metadata">

**Author:** ![dcabanaw](https://yyz1.discourse-cdn.com/flex035/user_avatar/forum.genieacs.com/dcabanaw/32/921_2.png) [@dcabanaw](https://forum.genieacs.com/u/dcabanaw)\
**Post date:** [September 17, 2026, 1:30pm UTC](https://forum.genieacs.com/t/issues-with-stun-on-1-2-16/7460/4 "2026-09-17T13:30:20Z")

</div>

Reporting back with some success.

```javascript
const interval = Date.now(300000); // 5 minutes for testing

// ...SNIP...

declare("InternetGatewayDevice.ManagementServer.STUNEnable", {
    path: interval,
    value: interval
});

// ...SNIP...

```

This worked for me. Instead of having it in `inform` I put it in `default`. I had to specify both `path` and `value` for it to work.
