# Created by Henry-Nicolas Tourneur(henry.nicolas@tourneur.be)
# See man(5) tac_plus.conf for more details

# Define where to log accounting data, this is the default.

accounting file = /var/log/tac_plus.acct

# This is the key that clients have to use to access Tacacs+

key = testing123

# Use /etc/passwd file to do authentication
    
#default authentication = file /etc/passwd
 

# You can use feature like per host key with different enable passwords
#host = 127.0.0.1 {
#        key = test 
#        type = cisco
#        enable = <des|cleartext> enablepass
#        prompt = "Welcome XXX ISP Access Router \n\nUsername:"
#}

# We also can define local users and specify a file where data is stored.
# That file may be filled using tac_pwd
#user = test1 {
#    name = "Test User"
#    member = staff
#    login = file /etc/tacacs/tacacs_passwords
#}

# We can also specify rules valid per group of users.
#group = group1 {
#	cmd = conf {
#		deny
#	}
#}

# Another example : forbid configure command for some hosts
# for a define range of clients
#group = group1 {
#	login = PAM
#	service = ppp
#	protocol = ip {
#		addr = 10.10.0.0/24
#	}
#	cmd = conf {
#		deny .*
#	}
#}

#user = DEFAULT {
#	login = PAM
#	service = ppp protocol = ip {}
#}

# Much more features are availables, like ACL, more service compatibilities,
# commands authorization, scripting authorization.
# See the man page for those features.

acl = nets {
    permit = .*
#    permit = 192.168.25.*
#    permit = 192.168.26.*
#    deny = .*
}

group = admin {
    default service = permit
    acl = nets
    service = my { priv-lvl = 15 }
#    service = ppp protocol = unknow { priv-lvl = 15 }
}

user = me {
    login = cleartext "test"
    pap = cleartext "test"
    service = frr {
	priv-lvl = 15
    }
}

user = me10 {
    login = cleartext "test"
    pap = cleartext "test"
    service = frr {
	priv-lvl = 10
    }
}

user = me7 {
    login = cleartext "test"
    pap = cleartext "test"
    service = frr {
	priv-lvl = 7
    }
}

user = me1 {
    login = cleartext "test"
    pap = cleartext "test"
    service = frr {
	priv-lvl = 1
    }
}
