Commit Briefs

813bc04fe9 Stefan Sperling

add nshdoas to fix the 'enable' command when stdin is not a TTY (nshdoas)

nshdoas is based on doas(1). It reads /etc/doas.conf and asks for the root password in case no matching rule exists. This avoids the need to fall back on su(1) and makes it possible to use the 'enable' command when sending nsh commands on standard input.


98fc2f167b Stefan Sperling

allow nsh to change its behaviour when standard input is not a TTY

Introduce an 'interactive_mode' flag which indicates whether standard input is a TTY. This allows nsh to accept commands on standard input for scripting purposes. This will be needed for better integration of at(1). The 'enable' command will not work in non-interactive mode yet. This will be fixed soon.


d759fe7472 Stefan Sperling

add cmdargs_output_setenv

This will be needed for future work.


574d5c2d6a Stefan Sperling

fill empty configuration files with an example config from /etc/examples

If the user begins editing an empty file which corresponds to a file in the /etc/examples directory offer to load this example for editing. Suggested by Tom Smyth. ok tom, chris


cec4f8cecc Stefan Sperling

leave pf processing of rc(8) enabled in integration script

Otherwise pfctl -e will never be run during boot, leaving pf disabled by default.


e84a83799e GitHub

Merge pull request #139 from stspdotname/env

add 'show environment', 'setenv', and 'unsetenv' commands


660067642d Stefan Sperling

add 'show environment', 'setenv', and 'unsetenv' commands

Being able to manage environment variables from within nsh will be useful, especially if nsh is used as a login shell because nsh's environment is visible to other commands run by nsh. Setting variables can now affect the behaviour of nsh itself. For example, it is possible to set NSH_MANUAL_PAGE from within a running nsh session and the new value will immediately be used by the 'manual' command. This particular variable is only useful to nsh developers themselves but the same mechanism could be used for user-facing variables in the future. If 'show environment' is run without further arguments all variables will be displayed. Otherwise the value of the specified variable will be displayed if the variable exists. All commands support tab-completion for names which already exist in the environment. The 'setenv' commands appends "=" if the name being completed does not yet exist in the environment.


2d331b3f3d GitHub

Merge pull request #138 from stspdotname/cron

add crontab commands: show crontab, crontab edit, crontab install


d84619f382 chris

wgpeer description

ok stsp@



Branches

Tags

Tree

.gitignorecommits | blame
COPYRIGHTcommits | blame
Makefilecommits | blame
READMEcommits | blame
arp.ccommits | blame
bgpcommands.ccommits | blame
bgpnsh/
bridge.ccommits | blame
bridge.hcommits | blame
carp.ccommits | blame
cmdargs.ccommits | blame
commands.ccommits | blame
commands.hcommits | blame
compile.shcommits | blame
complete.ccommits | blame
conf.ccommits | blame
ctl.ccommits | blame
ctl.hcommits | blame
ctlargs.ccommits | blame
editing.hcommits | blame
externs.hcommits | blame
genget.ccommits | blame
helpcommands.ccommits | blame
ieee80211.ccommits | blame
if.ccommits | blame
ip.hcommits | blame
kroute.ccommits | blame
main.ccommits | blame
makeargv.ccommits | blame
media.ccommits | blame
more.ccommits | blame
nameserver.ccommits | blame
ndp.ccommits | blame
nopt.ccommits | blame
nsh-dist.txtcommits | blame
nsh-scripts/
nsh-version.mkcommits | blame
nsh.8commits | blame
nshdoas/
passwd.ccommits | blame
pflow.ccommits | blame
pfsync.ccommits | blame
ppp.ccommits | blame
prompt.ccommits | blame
route.ccommits | blame
save-ro.sh*commits | blame
save-rw.sh*commits | blame
show.ccommits | blame
sqlite3.ccommits | blame
stats.ccommits | blame
stringlist.ccommits | blame
stringlist.hcommits | blame
sysctl.ccommits | blame
sysctl.hcommits | blame
test/
trunk.ccommits | blame
tunnel.ccommits | blame
umb.ccommits | blame
utf8.ccommits | blame
utils.ccommits | blame
version.ccommits | blame
wg.ccommits | blame
who.ccommits | blame

README

nsh//network config shell//Chris Cappuccio <chris@nmedia.net> version 1.1

NSH is a CLI intended for OpenBSD-based network appliances. It replaces
ifconfig, sysctl and route with its own simple command language, and
encapsulates configuration for other daemons into one place, effectively
replacing /etc/netstart and parts of /etc/rc for appliance-style usage.

Daemons and services encapsulated by nsh:

bgpd, dhcpd, dhcpleased, dhcrelay, dvmrpd, eigrpd, ftp-proxy, ifstated, inetd, 
iked, ipsecctl, ldapd, ldpd, npppd, ntpd, ospfd, ospf6d, pf, rad, relayd, 
resolvd, ripd, sasyncd, slaacd, smtpd, snmpd, sshd, tftpd, tftp-proxy.

NSH is freely licensed, in the BSD style.

In conjunction with the OpenBSD kernel and the daemons you wish to control,
you have a fully functioning system.

See https://github.com/yellowman/nsh/wiki/NSH-Manual-page or 
nsh.8 manual for installation instructons and command set.

See the Todo list on https://github.com/users/yellowman/projects/1 for 
details on implementation status and future ideas.

See http://github.com/yellowman/nsh/ for current source code repository.
See http://www.nmedia.net/nsh/ for example configurations and mailing
list.

See https://www.youtube.com/watch?v=WMKxIHaWaG0 for an EurobsdCon 2022 
Presentation on NSH for network administrators.