#include <fcntl.h>#include <pwd.h>#include <stdio.h>#include <stdarg.h>#include <string.h>#include <sys/param.h>#include <sys/stat.h>#include <sys/types.h>#include <unistd.h>#include "../../bin/afppasswd/afppasswd.c"Macros | |
| #define | fstat test_fstat |
| #define | fchown test_fchown |
| #define | fchmod test_fchmod |
| #define | fcntl test_fcntl |
| #define | fsync test_fsync |
| #define | setpwent test_setpwent |
| #define | getpwent test_getpwent |
| #define | endpwent test_endpwent |
| #define | main |
Functions | |
| const char * | tmpdir (void) |
| Find a suitable temporary directory for Netatalk. | |
| static int | test_fstat (int fd, struct stat *st) |
| static int | test_fchown (int fd, uid_t owner, gid_t group) |
| static int | test_fchmod (int fd, mode_t mode) |
| static int | test_fcntl (int fd, int cmd,...) |
| static int | test_fsync (int fd) |
| static void | test_setpwent (void) |
| static struct passwd * | test_getpwent (void) |
| static void | test_endpwent (void) |
| static int | is_mock_verifier (int fd) |
| static void | report (int passed, const char *name) |
| static int | write_file (const char *path, const char *contents) |
| static int | make_case (char directory[MAXPATHLEN+1]) |
| static void | test_rejected_verifier_does_not_change_metadata (void) |
| static void | test_verifier_permissions (void) |
| static void | test_single_record_updates (void) |
| static void | test_enrollment_ownership (void) |
| static void | test_unenrolled_user_message (void) |
| static void | test_shared_srp_validation (void) |
| static void | test_minimum_uid_parser (void) |
| static void | test_disable_option_argument (void) |
Variables | |
| static struct stat | verifier_directory |
| static int | mock_directory_owner |
| static const char * | mock_verifier_path |
| static uid_t | mock_verifier_owner |
| static int | fail_verifier_sync |
| static int | fail_verifier_chown |
| static int | fail_verifier_chmod |
| static int | fail_verifier_lock |
| static int | verifier_syncs |
| static int | enrollment_before_sync |
| static struct passwd * | mock_passwd |
| static int | passwd_returned |
| static int | tests_run |
| static int | tests_failed |
| #define endpwent test_endpwent |
| #define fchmod test_fchmod |
| #define fchown test_fchown |
| #define fcntl test_fcntl |
| #define fstat test_fstat |
| #define fsync test_fsync |
| #define getpwent test_getpwent |
| int main | ( | void | ) |
| #define setpwent test_setpwent |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
extern |
Find a suitable temporary directory for Netatalk.
Creates a subdirectory for current gid if it doesn't exist. The result should be copied immediately as it may be overwritten by a subsequent call.
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |