User name

How to configure my trunk when send user name to send one not extention user name ? I have to login in another trunk whit user name and password but my trunk send to another extentions user name.

Normal Sip trunk
host=XXXXXXXXXXXX
username=XXX
secret=XXX
type=peer
callerid=XXX

register string
XXX:XXX@XXXXXXXXXXXXXXX
Another trunk Authenticate me with user XXX pasw XXX

Need more information on the type of trunk and how you are setting it up.