android:exported

황제낙엽 2022.11.22 13:06 조회 수 : 0

sitelink1 https://hydroponicglass.tistory.com/349 
sitelink2  
sitelink3  

안드로이드12부터 manifest에 android:exported를 명시적으로 나타내야 한다.

android:exported의 값은 true, false가 있으며 true는 다른 앱과 통신이 필요할 때, false는 다른 앱과 통신이 필요하지 않을때 사용한다.

애뮬레이터를 이용한다면 true로 두어야 한다.

 

AndroidManifest.xml

<activity android:name=".MainActivity" android:exported="true"> // android:exported="true" 추가
	<intent-filter>
		<action android:name="android.intent.action.MAIN" />
		<category android:name="android.intent.category.LAUNCHER" />
	</intent-filter>
</activity>