Variables Available to Samba
If you've followed along in swat and looked at any of the default entries on the Advanced View pages, you've seen variables in the form %X, where X is one of many upper- or lowercase letters. These variables can be used to extend the flexibility of Samba. Following is a list of the variables and a short explanation of each:
%S—The name of the current service, if any.
%P—The root directory of the current service, if any.
%u—Username of the current service, if any.
%g—Primary group name of %u.
%U—Session username (the username that the client requested, not necessarily the same as the one received).
%G—Primary group name of %U.
%H—The home directory of the user (%u).
%v—The Samba version.
%h—The Internet hostname (DNS) on which ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access