1

I'm trying to setup Dante 1.4.2 on my Ubuntu 18.04 server but getting a strange behavior from Dante:

Jun 12 01:33:22 (1528760002.119429) danted[8854]: error: /etc/danted.conf: problem on line 93 near token "user.privileged": syntax error.  Please see the Dante manual for more information
Jun 12 01:33:22 (1528760002.121016) danted[8854]: alert: mother[1/1]: shutting down

My /etc/danted.conf looks like below (except commented and empty lines):

# cat /etc/danted.conf | grep -v '^#' | grep -v '^$'
logoutput: syslog stdout /var/log/sockd.log
internal: eth0 port = 1080
external: <server's real IP>
socksmethod: pam.username
client pass {
    from: 0.0.0.0/0 to: 0.0.0.0/0
    log: connect disconnect error
    pam.servicename: sockd
}
socks pass {
    from: 0.0.0.0/0 to: 0.0.0.0/0
    log: connect disconnect error
}
user.privileged: proxy
user.unprivileged: nobody

This declaration of user.* records is uncommented lines from stock file. As per Dante config format, these keywords are correct (see https://www.inet.no/dante/doc/1.4.x/sockd.conf.5.html).

If I comment user.* lines, Dante starts but reminds me that it is not safe configuration:

Jun 12 01:43:45 (1528760625.302753) danted[9445]: warning: checkconfig(): setting the unprivileged uid to 0 is not recommended for security reasons

Please advise if user.privileged and user.unprivileged are necessary, and if so how to start Dante with these settings.

Thanks!

LibertyPaul
  • 121
  • 5

1 Answers1

1

The solution was to change order of lines in config following way:

# cat danted.conf | grep -v '^#' | grep -v ^$
logoutput: syslog stdout /var/log/sockd.log
internal: eth0 port = 1080
external: <server's real IP>
socksmethod: pam.username
user.privileged: root
user.unprivileged : nobody
client pass {
    from: 0.0.0.0/0 to: 0.0.0.0/0
    log: connect disconnect error
    pam.servicename: sockd
}
socks pass {
    from: 0.0.0.0/0 to: 0.0.0.0/0
    log: connect disconnect error
}
LibertyPaul
  • 121
  • 5