178efe41174950783e39782c71ff8382f851bb487Jeff Sharkey/* 278efe41174950783e39782c71ff8382f851bb487Jeff Sharkey * Copyright (C) 2016 The Android Open Source Project 378efe41174950783e39782c71ff8382f851bb487Jeff Sharkey * 478efe41174950783e39782c71ff8382f851bb487Jeff Sharkey * Licensed under the Apache License, Version 2.0 (the "License"); 578efe41174950783e39782c71ff8382f851bb487Jeff Sharkey * you may not use this file except in compliance with the License. 678efe41174950783e39782c71ff8382f851bb487Jeff Sharkey * You may obtain a copy of the License at 778efe41174950783e39782c71ff8382f851bb487Jeff Sharkey * 878efe41174950783e39782c71ff8382f851bb487Jeff Sharkey * http://www.apache.org/licenses/LICENSE-2.0 978efe41174950783e39782c71ff8382f851bb487Jeff Sharkey * 1078efe41174950783e39782c71ff8382f851bb487Jeff Sharkey * Unless required by applicable law or agreed to in writing, software 1178efe41174950783e39782c71ff8382f851bb487Jeff Sharkey * distributed under the License is distributed on an "AS IS" BASIS, 1278efe41174950783e39782c71ff8382f851bb487Jeff Sharkey * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1378efe41174950783e39782c71ff8382f851bb487Jeff Sharkey * See the License for the specific language governing permissions and 1478efe41174950783e39782c71ff8382f851bb487Jeff Sharkey * limitations under the License. 1578efe41174950783e39782c71ff8382f851bb487Jeff Sharkey */ 1678efe41174950783e39782c71ff8382f851bb487Jeff Sharkey 17377cd1957172c19ee21baa3d6bda0840f1ce020dPaul Lawrence#include <sys/cdefs.h> 18377cd1957172c19ee21baa3d6bda0840f1ce020dPaul Lawrence#include <stdbool.h> 193045e27e894dd8a90faabc0177e080114b35af3bPaul Lawrence#include <cutils/multiuser.h> 20377cd1957172c19ee21baa3d6bda0840f1ce020dPaul Lawrence 21377cd1957172c19ee21baa3d6bda0840f1ce020dPaul Lawrence__BEGIN_DECLS 22377cd1957172c19ee21baa3d6bda0840f1ce020dPaul Lawrence 23377cd1957172c19ee21baa3d6bda0840f1ce020dPaul Lawrence// These functions assume they are being called from init 24377cd1957172c19ee21baa3d6bda0840f1ce020dPaul Lawrence// They will not operate properly outside of init 25377cd1957172c19ee21baa3d6bda0840f1ce020dPaul Lawrenceint e4crypt_install_keyring(); 26377cd1957172c19ee21baa3d6bda0840f1ce020dPaul Lawrenceint e4crypt_create_device_key(const char* path, 27377cd1957172c19ee21baa3d6bda0840f1ce020dPaul Lawrence int ensure_dir_exists(const char* dir)); 28377cd1957172c19ee21baa3d6bda0840f1ce020dPaul Lawrenceint e4crypt_set_directory_policy(const char* path); 29facc16251cd66bdd229c9429818d8f0b7daa8a02Paul Crowleyint e4crypt_do_init_user0(); 3059ffd6d9c7dd3ddaa036956d89c3e4d416769bf6Paul Lawrence 31377cd1957172c19ee21baa3d6bda0840f1ce020dPaul Lawrence__END_DECLS 32