If you haven't already done so, add the new macro and the new rule set to the client.cf file:
# Defined macros D{REMOTE}mailhost              # The name of the mail hub 
D{HUB}mail.us.edu              # Hub as known to the outside world    
 new
 new
Remember to replace 
mail.us.edu
 with a real hostname - the name of the hub machine at your site.
The new rule set looks like this:
SHubset # Rewrite the sender for the hubR$- $@ $1@${HUB} user -> user@hubnew
Now test the new rule by running sendmail in rule-testing mode:
%./sendmail -Cclient.cf -btADDRESS TEST MODE (ruleset 3 NOT automatically invoked) Enter <ruleset> <address> >
At the prompt, specify rule set 3 first because  all addresses are preprocessed by that rule. Then specify 
Hubset
, because the hub delivery agent definition specifies that rule in its 
S=
 equate.
>3,Hubset you
Following the list of rule sets, give the sender's name. Remember that the lone login name will be rewritten to appear as though it is from the hub. The output produced by sendmail looks like this:
rewrite: ruleset 3 input: you rewrite: ruleset 3 returns: you rewrite: ruleset 199 input: you rewrite: ruleset 199 returns: you @ mail . us . edu
Note that V8 
sendmail
 internally changed the name 
Hubset
 into the number 199.