Basic module

This commit is contained in:
2024-09-29 12:20:09 +02:00
parent 220ceadc5c
commit a192bafaaf
10 changed files with 221 additions and 2 deletions
+5
View File
@@ -0,0 +1,5 @@
system/priv-app/GmsCore/*.apk
system/priv-app/GsfProxy/*.apk
system/priv-app/Phonesky/*.apk
system/framework/*.jar
*.zip
+33
View File
@@ -0,0 +1,33 @@
#!/sbin/sh
#################
# Initialization
#################
umask 022
# echo before loading util_functions
ui_print() { echo "$1"; }
require_new_magisk() {
ui_print "*******************************"
ui_print " Please install Magisk v20.4+! "
ui_print "*******************************"
exit 1
}
#########################
# Load util_functions.sh
#########################
OUTFD=$2
ZIPFILE=$3
mount /data 2>/dev/null
[ -f /data/adb/magisk/util_functions.sh ] || require_new_magisk
. /data/adb/magisk/util_functions.sh
[ $MAGISK_VER_CODE -lt 20400 ] && require_new_magisk
install_module
exit 0
@@ -0,0 +1 @@
#MAGISK
+19 -2
View File
@@ -1,3 +1,20 @@
# microG_Installer_Resurrected
# microG Installer Resurrected
Installs microG Services, Companion, and Services Framework Proxy as system apps.
Magisk module installing microG apps as privileged system apps. Based
on nift4's 3.4.4-0 microG\_Installer\_Revived.
# How to use
1. Clone this git repository.
2. Open the `system/priv-app` directory inside the repository.
3. Go to [microG website](https://microg.org/download.html), download
all the apps (microG Services, Companion, Services Framework Proxy)
and put them in their corresponding directories. Also download
[NetworkLocation](https://github.com/microg/UnifiedNlp/releases).
5. Download
[MapsV1](https://github.com/microg/android_frameworks_mapsv1/releases),
and unzip it. Copy the `com.google.android.maps.jar` from
`system/framework` to the same directory in the repository.
6. Either run the `pack.sh` script in the root directory, or pack the
module yourself into a .zip file.
7. Install the module in Magisk.
8. Enjoy your working installation of microG.
+6
View File
@@ -0,0 +1,6 @@
id=microG_Installer_Resurrected
name=microG Installer Resurrected
version=1.0
versionCode=10
author=Emil Kosz
description=Installs microG Services, Companion, and Services Framework Proxy as system apps.
Executable
+7
View File
@@ -0,0 +1,7 @@
#!/usr/bin/env bash
MODULE_NAME=microG_Installer_Resurrected
EXCLUDE="LICENSE README.md pack.sh"
rm -f $MODULE_NAME
zip -9 --recurse-paths "${MODULE_NAME}.zip" --exclude $EXCLUDE -- * >/dev/null
@@ -0,0 +1,28 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (C) 2019 chris42 (based on work of ale5k and nanolx)
SPDX-License-Identifer: GPL-3.0-or-later
This file contains permissions to be granted by default.
Default permissions are granted to special platform components and to apps that are approved to get default grants.
The special components are apps that are expected to work out-of-the-box as they provide core use cases.
Fixed permissions cannot be controlled by the user and need a special approval.
Typically these are to ensure either legally mandated functions or the app is considered a part of the OS.
Granting these permissions could prevent issues on some ROMs or on non-clean installations.
-->
<exceptions>
<exception package="com.google.android.gms">
<!-- Phone -->
<permission name="android.permission.READ_PHONE_STATE" fixed="false"/>
<permission name="android.permission.RECEIVE_SMS" fixed="false" whitelisted="true" />
<!-- Account -->
<permission name="android.permission.READ_CONTACTS" fixed="false"/>
<permission name="android.permission.WRITE_CONTACTS" fixed="false"/>
<permission name="android.permission.GET_ACCOUNTS" fixed="false"/>
<!-- Location -->
<permission name="android.permission.ACCESS_FINE_LOCATION" fixed="false"/>
<permission name="android.permission.ACCESS_COARSE_LOCATION" fixed="false"/>
<!-- Storage -->
<permission name="android.permission.READ_EXTERNAL_STORAGE" fixed="false"/>
<permission name="android.permission.WRITE_EXTERNAL_STORAGE" fixed="false"/>
</exception>
</exceptions>
@@ -0,0 +1,20 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (C) 2008 The Android Open Source Project
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<permissions>
<library name="com.google.android.maps"
file="/system/framework/com.google.android.maps.jar" />
</permissions>
@@ -0,0 +1,57 @@
<!-- microG Installer -->
<permissions>
<privapp-permissions package="com.google.android.gms">
<permission name="android.permission.LOCATION_HARDWARE"/>
<permission name="android.permission.MODIFY_PHONE_STATE"/>
<permission name="android.permission.NETWORK_SCAN"/>
<permission name="android.permission.UPDATE_DEVICE_STATS"/>
<permission name="android.permission.WATCH_APPOPS"/>
<permission name="android.permission.INSTALL_LOCATION_PROVIDER"/>
<permission name="android.permission.CHANGE_DEVICE_IDLE_TEMP_WHITELIST"/>
<permission name="android.permission.FAKE_PACKAGE_SIGNATURE"/>
<permission name="android.permission.UPDATE_APP_OPS_STATS"/>
<permission name="android.permission.MANAGE_USB" />
<permission name="android.permission.START_ACTIVITIES_FROM_BACKGROUND" />
</privapp-permissions>
<!-- For real Play Store; Fake Store will not use all except one (FAKE_PACKAGE_SIGNATURE) of them -->
<privapp-permissions package="com.android.vending">
<permission name="android.permission.ALLOCATE_AGGRESSIVE" />
<permission name="android.permission.BACKUP" />
<permission name="android.permission.BATTERY_STATS" />
<permission name="android.permission.CHANGE_COMPONENT_ENABLED_STATE" />
<permission name="android.permission.CHANGE_DEVICE_IDLE_TEMP_WHITELIST" />
<permission name="android.permission.CHANGE_OVERLAY_PACKAGES" />
<permission name="android.permission.CLEAR_APP_CACHE" />
<permission name="android.permission.CONNECTIVITY_INTERNAL" />
<permission name="android.permission.DELETE_PACKAGES" />
<permission name="android.permission.DUMP" />
<permission name="android.permission.FAKE_PACKAGE_SIGNATURE" />
<permission name="android.permission.FORCE_STOP_PACKAGES" />
<permission name="android.permission.GET_ACCOUNTS_PRIVILEGED" />
<permission name="android.permission.GET_APP_OPS_STATS" />
<permission name="android.permission.INSTALL_PACKAGES" />
<permission name="android.permission.INTERACT_ACROSS_USERS" />
<permission name="android.permission.LOADER_USAGE_STATS" />
<permission name="android.permission.MANAGE_CLOUDSEARCH" />
<permission name="android.permission.MANAGE_ROLLBACKS" />
<permission name="android.permission.MANAGE_USERS" />
<permission name="android.permission.OVERRIDE_COMPAT_CHANGE_CONFIG_ON_RELEASE_BUILD" />
<permission name="android.permission.PACKAGE_USAGE_STATS" />
<deny-permission name="android.permission.PACKAGE_VERIFICATION_AGENT" />
<deny-permission name="android.permission.READ_PRIVILEGED_PHONE_STATE" />
<permission name="android.permission.READ_RUNTIME_PROFILES" />
<permission name="android.permission.REAL_GET_TASKS" />
<permission name="android.permission.REBOOT" />
<permission name="android.permission.SEND_DEVICE_CUSTOMIZATION_READY" />
<permission name="android.permission.SEND_SAFETY_CENTER_UPDATE" />
<deny-permission name="android.permission.SEND_SMS_NO_CONFIRMATION" />
<permission name="android.permission.SET_PREFERRED_APPLICATIONS" />
<permission name="android.permission.START_ACTIVITIES_FROM_BACKGROUND" />
<permission name="android.permission.STATUS_BAR" />
<permission name="android.permission.SUBSTITUTE_NOTIFICATION_APP_NAME" />
<permission name="android.permission.UPDATE_DEVICE_STATS" />
<permission name="android.permission.USE_INSTALLER_V2" />
<permission name="com.android.permission.USE_INSTALLER_V2" />
<permission name="android.permission.WRITE_SECURE_SETTINGS" />
</privapp-permissions>
</permissions>
+45
View File
@@ -0,0 +1,45 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (C) 2014 The Android Open Source Project
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<!-- Adapted from OpenGapps -->
<config>
<allow-in-power-save package="com.google.android.gms" />
<allow-in-data-usage-save package="com.google.android.gms" />
<allow-unthrottled-location package="com.google.android.gms" />
<allow-in-power-save-except-idle package="com.google.android.apps.turbo" />
<allow-implicit-broadcast action="com.google.android.checkin.CHECKIN_COMPLETE" />
<allow-implicit-broadcast action="com.google.gservices.intent.action.GSERVICES_CHANGED" />
<allow-implicit-broadcast action="com.google.gservices.intent.action.GSERVICES_OVERRIDE" />
<allow-implicit-broadcast action="com.google.android.c2dm.intent.RECEIVE" />
<allow-in-power-save package="com.google.android.volta" />
<allow-in-power-save package="com.google.android.ims" />
<allow-in-power-save-except-idle package="com.android.vending" />
<allow-in-data-usage-save package="com.google.android.ims" />
<app-link package="com.android.vending" />
<system-user-whitelisted-app package="com.android.vending" />
<system-user-whitelisted-app package="com.google.android.gms" />
<system-user-blacklisted-app package="com.google.android.googlequicksearchbox" />
<!-- microG UnifiedNlp backends -->
<allow-unthrottled-location package="org.microg.nlp.backend.apple" />
<allow-unthrottled-location package="org.microg.nlp.backend.ichnaea" />
<allow-unthrottled-location package="org.microg.nlp.backend.nominatim" />
<allow-unthrottled-location package="org.radiocells.unifiedNlp" />
<allow-unthrottled-location package="org.fitchfamily.android.wifi_backend" />
<allow-unthrottled-location package="org.fitchfamily.android.gsmlocation" />
<allow-unthrottled-location package="org.fitchfamily.android.dejavu" />
</config>