wifi: fix security issue

The API registerLocalOnlyHotspotSoftApCallback/
unregisterLocalOnlyHotspotSoftApCallback should check caller package name
is belong to caller uid, otherwise caller can fake own app's packet name
to know if the specific app is installed or not.

Bug: 233605242
Test: atest -c FrameworksWifiTests
Test: atest -c android.net.wifi.cts.WifiManagerTest#testStartLocalOnlyHotspotWithConfigBssid (CTS works normally)
Test: adb shell cmd wifi start-lohs test open -b 2 (shell command works normally)
Test: Install the test app and issue is fixed.
Change-Id: I8db109cce3f18433dca924b3f2196885c529dc5f
Merged-In: I0959ee7c3100adc571e693427bc9c0df95cbc0d2
(cherry picked from commit ed9f623611bcc42d511f3b2e53d3504e51f5199e)
2 files changed