@@ -48,11 +48,13 @@ type ClientConfig struct {
4848 Net transport.Net
4949 LoggerFactory logging.LoggerFactory
5050
51- evenPort bool // If EVEN-PORT Attribute should be sent in Allocation
52- reservationToken []byte // If Server responds with RESERVATION-TOKEN or if Client wishes to send one
53- permissionRefreshInterval time.Duration
54- bindingRefreshInterval time.Duration
55- bindingCheckInterval time.Duration
51+ // PermissionTimeout sets the refresh interval of permissions. Defaults to 2 minutes.
52+ PermissionRefreshInterval time.Duration
53+
54+ evenPort bool // If EVEN-PORT Attribute should be sent in Allocation
55+ reservationToken []byte // If Server responds with RESERVATION-TOKEN or if Client wishes to send one
56+ bindingRefreshInterval time.Duration
57+ bindingCheckInterval time.Duration
5658}
5759
5860// Client is a STUN server client.
@@ -146,7 +148,7 @@ func NewClient(config *ClientConfig) (*Client, error) {
146148 log : log ,
147149 evenPort : config .evenPort ,
148150 reservationToken : config .reservationToken ,
149- permissionRefreshInterval : config .permissionRefreshInterval ,
151+ permissionRefreshInterval : config .PermissionRefreshInterval ,
150152 bindingRefreshInterval : config .bindingRefreshInterval ,
151153 bindingCheckInterval : config .bindingCheckInterval ,
152154 }
0 commit comments