Problem
What is an AFPS Trust Relationship and how is it created?
Solution
A trust relationship is a mechanism that allows AFPS (or NT) users access to the shared resources (such as filesystems and printers) of an AFPS or NT system in another AFPS/NT domain, without the requirement that they have local user accounts on these systems. This simplifies user administration and control in large sites.
For a trust relationship to be enabled, the primary domain
controller (PDC) of one AFPS domain is configured to "trust"
the users of another AFPS or NT domain and/or visa versa. Once
the trust relationship is established, trusted users have access
to the resources of the remote domain as if they were users local
to that domain. AFPS implements user-level security so that every
user of a system should have a user account, password, and access
control data (ACL) contained in the local AFPS system database
(SAM).Previously, in products such as SCO LAN Manager for UNIX, to
enable a user to access resources in another domain, it would
have been necessary to use the "guest" account or to create a
duplicate local account on the second domain primary domain
controller (PDC). It would be an overhead on administration on
such systems to keep the accounts up-to-date, as there is no
method to synchronize the accounts between different domains
- as per "net accounts /sync".A trust relationship allows individual users, or global groups, access to another domain's resources. A trust relationship cannot be set up between local groups between domains. A trust relationship does not involve any login to another domain by the user; it simply allows network access to resources.
Establishing a trust relationship requires 2 steps:
1. One domain must permit a second domain to trust it.
2. The second domain must be set up to trust the first domain.
This can be confusing. The domain that is ultimately requesting access is first allowing the other domain to trust it. The second domain then has to decide whether it indeed will trust it, and if so, then configure that trust.
Trust relationships can be either one way or two way. In a one way relationship, system 'A' trusts users or groups from system 'B', but system 'B' does not in turn trust users from system 'A'. In a two way relationship, system 'A' trusts users or groups from system 'B', and system 'B' in turn trusts users or groups from system 'A'.
In the following example, a one way trust relationship is set up between 2 AFPS PDC systems, 'scosys3' and 'scosys4', in the domains ASU3_DOM and ASU4_DOM respectively, using a single Microsoft Windows for Workgroups 3.11 PC client installed with the NT server tools utility. Both systems reside on the same physical LAN. Ideally, it would be easier for the System Administrator to have a PC client logged into each AFPS system. The NT server tools (a component part of the NT server operating system), as supplied with the AFPS product, are required to configure the trust relationships on each server in turn.
NOTE: To set up a trust relationship, the password for the 'administrator' users of BOTH domains must be the same. Once the relationship has been created, the passwords may be changed. This is a known problem with the AFPS product. See the Release Notes referenced in the "SEE ALSO" section.
System Operating Domain AFPS
Name System Name User
-----------------------------------------------------
scosys3 OpenServer ASU3_DOM afpstest
5.0.0d +
Net MS 1.0.scosys4 "" ASU4_DOM -As an example only, an AFPS user is created on the ASU3_DOM domain server 'scosys3' using the command;
# net user afpstest afpstest /comment:"AFPS test user" /addA one way trust relationship is then set up. Step 1 above is completed as follows;
a. Log in as the "ADMINISTRATOR" user to the ASU3_DOM domain from the WFWG 3.11 PC client.
b. Start the NT Server Tools "User Manager for Domains" utility.
c. Choose "Policies",d. Choose "Trust Relationships",e. Two boxes are presented on the screen. Add the ASU4_DOM domain to that labeled "Permitted to Trust this domain".
f. Choose "Close" and then exit the application.
Step 2 is as follows:a. Log in as the "ADMINISTRATOR" user to the ASU4_DOM domain.
b. Again start the NT Server Tools "User Manager".
c. Choose "Policies", then "Trust Relationships".d. Add the domain "ASU3_DOM" to the "Trusted Domains" box.
e. This message appears:You have changed a trust relationship between domains. This client cannot verify changes to trust relationships. If you find that it was not established, contact the Administrator of the ASU3_DOM domain and verify that it has permitted ASU4_DOM to trust.
f. Choose "Close" and leave the application.
The trust relationship should now be active. To verify this, it should be possible to connect to a share in the ASU4_DOM domain and access any files present.
a. Create a test share called "AFPSTEST" that maps to a local UNIX directory called "/afpstest" on the 'scosys4' server. For example:
#mkdir /afpstest
#chmod 777 /afpstest
#net share AFPSTEST=c:/afpstest /remark:"Test Share"By default, full access rights to this share will be granted to all users, but only for users in that domain. For example, see the group "*Everyone" in the ouput of the command "#net access c:/afpstest"; For example:
# net access c:/afpstest
Resource Permissions Permissions
-------------------------------------------------------
c:\afpstest
*Administrators:RWCXDAP *Everyone:RWCXDA
*Server Operators:RWCXDA *SYSTEM:RWCXDAP
*SYSTEM:RWCXDAPb. Log in as the user "afpstest" into the ASU3_DOM domain.
c. Go into the "File Manager" utility and connect a local drive to the remote share on the ASU4_DOM scosys4 server:
E: "is mapped to" \\scosys4\afpstestd. Start the Microsoft Windows Notepad utility and create a test file and save it to E:
e. The file will be saved:-rw-rwSr- 1 lmworld DOS-a-- test1.txtThe file ownership defaults to the user "lmworld". This is a special UNIX user account that has been created by AFPS for files and directories owned by AFPS users who have not been mapped explicitly to another UNIX user account.
NOTE: It is not possible to map a trusted user to a local UNIX user account using the mapuname(AS) utility:
#cd /usr/net/servers/lanman/bin
#./mapuname -a asu3_dom:afpstest afpstestThe command above will fail with the error:
Could not find specified domainMapuname(AS) will only map local AFPS user accounts to local UNIX accounts, that is, "./mapuname -a asu4_dom:afpstest afpstest" will work if the UNIX user "afpstest" exists on the ASU4_DOM PDC. This is a known problem and has been reported to SCO Engineering. As the command syntax suggests, any domain should be able to be used.
If the test file had been created by the 'afpstest' user on its own local domain, ASU3_DOM, its ownership is "afpstest" as follows:
-rw-rwSr-- 1 afpstest DOS-a-- 34 Aug 2 17:40
test1.txtIf a test file is created by the 'administrator' user, its ownership is 'lmxadmin' as follows:
-rw-rwSr-- 1 lmxadmin DOS-a-- 14 Aug 6 15:04
test4.txtIn this case the AFPS "administrator" account is mapped internally to the UNIX "lmxadmin" user account.
Although a trust relationship gives a user access to shares in another domain, overall access is ultimately governed by the AFPS "net access" and UNIX file permissions. See Page 83 in the AFPS System Guide and Page 63 in the AFPS Administrator's Handbook for an explanation of the interaction of AFPS and UNIX file and directory permissions.
If a trust relationship had not been set up, a user would be unable to access any resource in the other domain. As an example:
A user "joe" is set up as an AFPS user on the PDC of the ASU4_DOM domain. The WFWG3.11 PC client then logs in as this user. File Manager is selected and a connection is attempted to the share \\scosys4\afpstest. The user is prompted as follows;
Enter Network PasswordDrive Letter: D:
Resource: \\SCOSYS4\AFPSTEST
Password:The password is unknown to any user so access is denied to the resource.
A two way trust relationship would be set up between the two example domains by simply repeating Steps 1 and 2 in reverse; that is, log in to ASU4_DOM and permit it to trust ASU3_DOM, then log in to ASU3_DOM and add ASU4_DOM as a trusted domain.
In the previous example, the trust relationship was set up between
systems with the same network address; that is, they resided on the
same network subnet. In other cases, the domains (containing at least one PDC and perhaps several BDC's) may reside on different subnets.
In this case, in order for the trust relationship to succeed, the
different domains must be able to "see" each other on the network.
Each PDC must be able to resolve the other server name and obtain its
IP address that will exist outside its own subnet on the other side
of a router. This requires a server "lmhosts" capability similar in
functionality to a "client" lmhosts capability. This is provided
within the SCO Networking Supplement 1.0.0. The configuration is
detailed in the accompanying release notes in the section entitled
"NetBIOS routing". This must be configured on AFPS PDC servers prior
to configuration of any trust relationship. The NetBIOS routing
functionality is included as part of the SCO OpenServer Release 5.0.2
operating system. See also
SCO Advanced File and Print Server Release Notes, page 21, "Administrator passwords and establishing trust relationships".
SCO Advanced File and Print Server Concepts and Planning Guide, Chapter 1, "Understanding domains and trusts".
SCO Advanced File and Print Server System Guide, Chapter 2, page 50, "Establishing Trust Relationships".
mapuname(AS)SCO Networking Supplement 1.0.0 Release Notes.