Provide GPSI via header enrichment as described in TS 29.244.
Have GPSI as part of the authentication information, or via in-band signalling.
At the establishment of the user plane connection between the UE Application and AF, the AF can use the procedure in clause 4.15.10 of TS 23.502 to get the GPSI.
At the establishment of the user plane connection between the UE Application and a trusted AF, the AF can use the steps 3 to 8 in clause 4.15.10 of TS 23.502, where NEF is replaced by the AF, to retrieve the SUPI of the UE.
In methods 2) to 4), the AF can correlate the UE public IP address and port with the SUPI/GPSI.