openwrt / openwrt/packages

sshtunnel: procd doesn’t detect service when SSH control sockets are used by default.

Open Beginner friendly
#29,347 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
Makefile
Stars
4.6k
Forks
4k
Avg merge
3d 12h
Merged PRs (30d)
134

Description

Package Name

sshtunnel

Maintainer

@nunojpg

OpenWrt Version

25.12.2

OpenWrt Target/Subtarget

mediatek/mt7622

Steps to Reproduce
  1. Install openssh-client
  2. Add the following to /etc/ssh/ssh_config :

Host *
ControlMaster auto
ControlPath /tmp/.ssh/cm_%r@%h:%p
ControlPersist yes

This ensures that every SSH connection uses a control socket by default.

  1. Create and run any ssh tunnel.
Actual Behaviour

The tunnel does start and is usable, but service sshtunnel status reports “Not running,” and service sshtunnel stop doesn’t terminate it. Additionally, ubus call service list '{ "name": "sshtunnel" }' shows no PIDs.

Suggested fix: Explicitly add -o ControlMaster=no and -o ControlPersist=no to the SSH options in the load_server() function within /etc/init.d/sshtunnel

Confirmation Checklist

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with /etc/init.d/sshtunnel and inspect the load_server() function. Reproduce the issue using the supplied SSH ControlMaster configuration, then check service sshtunnel status, stop, and ubus service-list behavior. Done means the tunnel remains usable while service status reports its process and stop terminates it.

Written by the indexing model from the issue text.

Assessment

Tech stack
shell
Domain
operating-systems
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Quiet
Clarity
Clearly specified
Newbie friendliness
68/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.