How to enable rtp_symmetric and rewrite_contact for pjsip Trunk?

I don’t need support for dynamic domains.

It would be sufficient if anyway the external ip address be found and used (e.g. STUN). Does this pjsip?