[Bug] window client report:panic: runtime error: invalid memory address or nil pointer dereference #997

Closed
opened 2025-12-29 02:27:13 +01:00 by adam · 2 comments
Owner

Originally created by @happytrudy on GitHub (Apr 12, 2025).

Is this a support request?

  • This is not a support request

Is there an existing issue for this?

  • I have searched the existing issues

Current Behavior

PS C:\Program Files\Tailscale> tailscale netcheck

Report:
* Time: 2025-04-12T15:27:25.9339598Z
* UDP: false
* IPv4: (no addr found)
* IPv6: no, but OS has support
* MappingVariesByDestIP:
* PortMapping:
* CaptivePortal: false
panic: runtime error: invalid memory address or nil pointer dereference
[signal 0xc0000005 code=0x0 addr=0x18 pc=0x83b748]

goroutine 1 [running]:
tailscale.com/cmd/tailscale/cli.printReport(0xc000008060, 0xc00030a0e0)
tailscale.com@v1.80.2/cmd/tailscale/cli/netcheck.go:168 +0x568
tailscale.com/cmd/tailscale/cli.runNetcheck({0xae8000, 0xf5f020}, {0x9b0487?, 0xc?, 0x64?})
tailscale.com@v1.80.2/cmd/tailscale/cli/netcheck.go:107 +0x6cd
github.com/peterbourgon/ff/v3/ffcli.(*Command).Run(0x9b0487?, {0xae8000?, 0xf5f020?})
github.com/peterbourgon/ff/v3@v3.4.0/ffcli/command.go:153 +0x148
github.com/peterbourgon/ff/v3/ffcli.(*Command).Run(0x9b0487?, {0xae8000?, 0xf5f020?})
github.com/peterbourgon/ff/v3@v3.4.0/ffcli/command.go:157 +0xf4
tailscale.com/cmd/tailscale/cli.Run({0xc0000aa390?, 0xc00012ff40?, 0x266afd?})
tailscale.com@v1.80.2/cmd/tailscale/cli/cli.go:157 +0x350
main.main()
tailscale.com@v1.80.2/cmd/tailscale/tailscale.go:22 +0xf3

Expected Behavior

I added custom derper server

this is my deper configuration of fllow:

derp:
server:
# If enabled, runs the embedded DERP server and merges it into the rest of the DERP config
# The Headscale server_url defined above MUST be using https, DERP requires TLS to be in place
enabled: false

# Region ID to use for the embedded DERP server.
# The local DERP prevails if the region ID collides with other region ID coming from
# the regular DERP config.
region_id: 999

# Region code and name are displayed in the Tailscale UI to identify a DERP region
region_code: "headscale"
region_name: "Headscale Embedded DERP"

# Listens over UDP at the configured address for STUN connections - to help with NAT traversal.
# When the embedded DERP server is enabled stun_listen_addr MUST be defined.
#
# For more details on how this works, check this great article: https://tailscale.com/blog/how-tailscale-works/
stun_listen_addr: "0.0.0.0:3478"

# Private key used to encrypt the traffic between headscale DERP
# and Tailscale clients.
# The private key file will be autogenerated if it's missing.
#
private_key_path: /var/lib/headscale/derp_server_private.key

# This flag can be used, so the DERP map entry for the embedded DERP server is not written automatically,
# it enables the creation of your very own DERP map entry using a locally available file with the parameter DERP.paths
# If you enable the DERP server and set this to false, it is required to add the DERP server to the DERP map using DERP.paths
automatically_add_embedded_derp_region: false

# For better connection stability (especially when using an Exit-Node and DNS is not working),
# it is possible to optionally add the public IPv4 and IPv6 address to the Derp-Map using:
ipv4: 1.2.3.4
ipv6: 2001:db8::1

List of externally available DERP maps encoded in JSON

urls:

- https://controlplane.tailscale.com/derpmap/default

Locally available DERP map files encoded in YAML

This option is mostly interesting for people hosting

their own DERP servers:

https://tailscale.com/kb/1118/custom-derp-servers/

paths:

- /etc/headscale/derp-example.yaml

paths:
- /etc/headscale/derper.yaml
When I run the following command:

Image

Steps To Reproduce

Same as above

Environment

- OS:
- Headscale version: 0.25.1
- Tailscale version:1.80.2

Runtime environment

  • Headscale is behind a (reverse) proxy
  • Headscale runs in a container

Debug information

Available later

Originally created by @happytrudy on GitHub (Apr 12, 2025). ### Is this a support request? - [x] This is not a support request ### Is there an existing issue for this? - [x] I have searched the existing issues ### Current Behavior PS C:\Program Files\Tailscale> tailscale netcheck Report: * Time: 2025-04-12T15:27:25.9339598Z * UDP: false * IPv4: (no addr found) * IPv6: no, but OS has support * MappingVariesByDestIP: * PortMapping: * CaptivePortal: false panic: runtime error: invalid memory address or nil pointer dereference [signal 0xc0000005 code=0x0 addr=0x18 pc=0x83b748] goroutine 1 [running]: tailscale.com/cmd/tailscale/cli.printReport(0xc000008060, 0xc00030a0e0) tailscale.com@v1.80.2/cmd/tailscale/cli/netcheck.go:168 +0x568 tailscale.com/cmd/tailscale/cli.runNetcheck({0xae8000, 0xf5f020}, {0x9b0487?, 0xc?, 0x64?}) tailscale.com@v1.80.2/cmd/tailscale/cli/netcheck.go:107 +0x6cd github.com/peterbourgon/ff/v3/ffcli.(*Command).Run(0x9b0487?, {0xae8000?, 0xf5f020?}) github.com/peterbourgon/ff/v3@v3.4.0/ffcli/command.go:153 +0x148 github.com/peterbourgon/ff/v3/ffcli.(*Command).Run(0x9b0487?, {0xae8000?, 0xf5f020?}) github.com/peterbourgon/ff/v3@v3.4.0/ffcli/command.go:157 +0xf4 tailscale.com/cmd/tailscale/cli.Run({0xc0000aa390?, 0xc00012ff40?, 0x266afd?}) tailscale.com@v1.80.2/cmd/tailscale/cli/cli.go:157 +0x350 main.main() tailscale.com@v1.80.2/cmd/tailscale/tailscale.go:22 +0xf3 ### Expected Behavior I added custom derper server this is my deper configuration of fllow: derp: server: # If enabled, runs the embedded DERP server and merges it into the rest of the DERP config # The Headscale server_url defined above MUST be using https, DERP requires TLS to be in place enabled: false # Region ID to use for the embedded DERP server. # The local DERP prevails if the region ID collides with other region ID coming from # the regular DERP config. region_id: 999 # Region code and name are displayed in the Tailscale UI to identify a DERP region region_code: "headscale" region_name: "Headscale Embedded DERP" # Listens over UDP at the configured address for STUN connections - to help with NAT traversal. # When the embedded DERP server is enabled stun_listen_addr MUST be defined. # # For more details on how this works, check this great article: https://tailscale.com/blog/how-tailscale-works/ stun_listen_addr: "0.0.0.0:3478" # Private key used to encrypt the traffic between headscale DERP # and Tailscale clients. # The private key file will be autogenerated if it's missing. # private_key_path: /var/lib/headscale/derp_server_private.key # This flag can be used, so the DERP map entry for the embedded DERP server is not written automatically, # it enables the creation of your very own DERP map entry using a locally available file with the parameter DERP.paths # If you enable the DERP server and set this to false, it is required to add the DERP server to the DERP map using DERP.paths automatically_add_embedded_derp_region: false # For better connection stability (especially when using an Exit-Node and DNS is not working), # it is possible to optionally add the public IPv4 and IPv6 address to the Derp-Map using: ipv4: 1.2.3.4 ipv6: 2001:db8::1 # List of externally available DERP maps encoded in JSON urls: # - https://controlplane.tailscale.com/derpmap/default # Locally available DERP map files encoded in YAML # # This option is mostly interesting for people hosting # their own DERP servers: # https://tailscale.com/kb/1118/custom-derp-servers/ # # paths: # - /etc/headscale/derp-example.yaml paths: - /etc/headscale/derper.yaml When I run the following command: ![Image](https://github.com/user-attachments/assets/e7e20b6e-fe4e-46e5-a1f9-225758853fd5) ### Steps To Reproduce Same as above ### Environment ```markdown - OS: - Headscale version: 0.25.1 - Tailscale version:1.80.2 ``` ### Runtime environment - [x] Headscale is behind a (reverse) proxy - [x] Headscale runs in a container ### Debug information Available later
adam added the stalebug labels 2025-12-29 02:27:13 +01:00
adam closed this issue 2025-12-29 02:27:13 +01:00
Author
Owner

@github-actions[bot] commented on GitHub (Jul 12, 2025):

This issue is stale because it has been open for 90 days with no activity.

@github-actions[bot] commented on GitHub (Jul 12, 2025): This issue is stale because it has been open for 90 days with no activity.
Author
Owner

@github-actions[bot] commented on GitHub (Jul 20, 2025):

This issue was closed because it has been inactive for 14 days since being marked as stale.

@github-actions[bot] commented on GitHub (Jul 20, 2025): This issue was closed because it has been inactive for 14 days since being marked as stale.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/headscale#997