mirror of
https://github.com/greenart7c3/Amber.git
synced 2026-10-06 11:28:22 +00:00
The SignerProvider's authorities are enumerated explicitly in the manifest, and the new NIP44_V3_ENCRYPT / NIP44_V3_DECRYPT authorities were missing. As a result contentResolver.query() for a v3 URI resolved to no provider and returned null, which the bunker path treats as "needs approval" — so invalid v3 requests (e.g. a decrypt whose kind does not match the ciphertext) were surfaced to the user instead of being rejected, and valid v3 requests could never auto-accept from a remembered permission. Also validate v3 bunker requests at the relay entry point and reject malformed ones (missing kind, context mismatch, bad MAC/padding, non-base64 payload) with a generic error response before any approval screen is shown.
68 lines
2.9 KiB
XML
68 lines
2.9 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
|
xmlns:tools="http://schemas.android.com/tools">
|
|
|
|
<!-- Explicitly remove INTERNET permission — offline flavor has no network stack -->
|
|
<uses-permission android:name="android.permission.INTERNET" tools:node="remove" />
|
|
<uses-permission android:name="android.permission.CHANGE_NETWORK_STATE" tools:node="remove" />
|
|
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" tools:node="remove" />
|
|
|
|
<application
|
|
android:name=".Amber"
|
|
android:allowBackup="false"
|
|
android:configChanges="orientation|screenSize|screenLayout"
|
|
android:dataExtractionRules="@xml/data_extraction_rules"
|
|
android:enableOnBackInvokedCallback="true"
|
|
android:fullBackupContent="@xml/backup_rules"
|
|
android:icon="@mipmap/ic_launcher"
|
|
android:label="@string/app_name"
|
|
android:launchMode="singleTop"
|
|
android:supportsRtl="true"
|
|
android:theme="@style/Theme.NostrSigner"
|
|
android:networkSecurityConfig="@xml/network_security_config"
|
|
android:windowSoftInputMode="adjustResize"
|
|
tools:targetApi="33">
|
|
|
|
<provider
|
|
android:name=".SignerProvider"
|
|
android:authorities="${applicationId}.PING;${applicationId}.SIGN_EVENT;${applicationId}.NIP04_ENCRYPT;${applicationId}.NIP04_DECRYPT;${applicationId}.NIP44_ENCRYPT;${applicationId}.NIP44_DECRYPT;${applicationId}.NIP44_V3_ENCRYPT;${applicationId}.NIP44_V3_DECRYPT;${applicationId}.GET_PUBLIC_KEY;${applicationId}.DECRYPT_ZAP_EVENT"
|
|
android:enabled="true"
|
|
android:exported="true" />
|
|
|
|
<activity
|
|
android:name=".MainActivity"
|
|
android:exported="true">
|
|
<intent-filter>
|
|
<action android:name="android.intent.action.MAIN" />
|
|
|
|
<category android:name="android.intent.category.LAUNCHER" />
|
|
</intent-filter>
|
|
</activity>
|
|
|
|
<activity
|
|
android:name=".SignerActivity"
|
|
android:exported="true"
|
|
android:theme="@style/Theme.NostrSigner.Modal">
|
|
<intent-filter>
|
|
<action android:name="com.greenart7c3.nostrsigner.MAIN_ACTIVITY" />
|
|
|
|
<category android:name="android.intent.category.DEFAULT" />
|
|
</intent-filter>
|
|
<intent-filter>
|
|
<action android:name="android.intent.action.VIEW" />
|
|
|
|
<category android:name="android.intent.category.DEFAULT" />
|
|
<category android:name="android.intent.category.BROWSABLE" />
|
|
|
|
<data android:scheme="nostrsigner" />
|
|
</intent-filter>
|
|
</activity>
|
|
|
|
<activity
|
|
android:name="com.journeyapps.barcodescanner.CaptureActivity"
|
|
android:screenOrientation="fullSensor"
|
|
tools:replace="screenOrientation" />
|
|
</application>
|
|
|
|
</manifest>
|