Commit 5ce4fa0d authored by José Henrique's avatar José Henrique
Browse files

Initial commit

parents
java_library {
name: "faceunlock_framework",
installable: true,
srcs: [
"src/**/*.java",
"src/**/*.aidl",
],
aidl: {
local_include_dirs: ["src"],
},
}
\ No newline at end of file
/*
* Copyright (C) 2020 The Pixel Experience 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.
*/
package com.android.internal.util.custom.faceunlock;
import android.os.SystemProperties;
public class FaceUnlockUtils {
public static boolean isFaceUnlockSupported() {
return SystemProperties.getBoolean("ro.face_unlock_service.enabled", false);
}
}
/**
* Copyright (C) 2021 The PixelExperience 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.
*/
package com.android.internal.util.custom.faceunlock;
import com.android.internal.util.custom.faceunlock.IFaceServiceReceiver;
/** @hide */
interface IFaceService {
oneway void authenticate(long operationId);
oneway void cancel();
oneway void enroll(in byte[] cryptoToken, int timeout, in int[] disabledFeatures);
int enumerate();
long generateChallenge(int timeout);
int getAuthenticatorId();
boolean getFeature(int feature, int faceId);
int getFeatureCount();
oneway void remove(int biometricId);
oneway void resetLockout(in byte[] cryptoToken);
int revokeChallenge();
oneway void setCallback(in IFaceServiceReceiver receiver);
oneway void setFeature(int feature, boolean enable, in byte[] token, int faceId);
}
\ No newline at end of file
/**
* Copyright (C) 2021 The PixelExperience 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.
*/
package com.android.internal.util.custom.faceunlock;
/** @hide */
oneway interface IFaceServiceReceiver {
void onEnrollResult(int faceId, int userId, int remaining);
void onAuthenticated(int faceId, int userId, in byte[] token);
void onAcquired(int userId, int acquiredInfo, int vendorCode);
void onError(int error, int vendorCode);
void onRemoved(in int[] faceIds, int userId);
void onEnumerate(in int[] faceIds, int userId);
void onLockoutChanged(long duration);
}
sed -i "s/com.motorola.faceunlock.util.MotoUnlockEncryptor/faceunlock\/util\/FaceUnlockEncryptorDependencyLib/" prebuilt/lib64/libarcsoft-lib.so
sed -i "s/android.os.Build/faceunlock\/Build/" prebuilt/lib64/libarcsoft-lib.so
cc_prebuilt_library_shared {
name: "libarcsoft_faceid",
strip: {
none: true,
},
target: {
android_arm64: {
srcs: ["lib64/libarcsoft_faceid.so"],
},
},
compile_multilib: "64",
prefer: true,
product_specific: true,
check_elf_files: false,
}
cc_prebuilt_library_shared {
name: "libarcsoft-lib",
strip: {
none: true,
},
target: {
android_arm64: {
srcs: ["lib64/libarcsoft-lib.so"],
},
},
compile_multilib: "64",
prefer: true,
product_specific: true,
check_elf_files: false,
}
cc_prebuilt_library_shared {
name: "libarcsoftbase",
strip: {
none: true,
},
target: {
android_arm64: {
srcs: ["lib64/libarcsoftbase.so"],
},
},
compile_multilib: "64",
prefer: true,
product_specific: true,
check_elf_files: false,
}
cc_prebuilt_library_shared {
name: "libmpbase",
strip: {
none: true,
},
target: {
android_arm64: {
srcs: ["lib64/libmpbase.so"],
},
},
compile_multilib: "64",
prefer: true,
product_specific: true,
check_elf_files: false,
}
\ No newline at end of file
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment