ProxyAuth
Linux PAM to authenticate device via Bluetooth device
|
#include "pam_bt_misc.h"
Go to the source code of this file.
Functions | |
int | verify_bt_addr (char *address, FILE *log_fp) |
int | is_dev_trusted (FILE *log_fp, char *dev, char **trusted_devices, int num_of_devices) |
void | free_device_list (char **device_list, int num_of_devices) |
Variables | |
const char * | trusted_dir_path = "/etc/proxy_auth/" |
void free_device_list | ( | char ** | device_list, |
int | num_of_devices | ||
) |
Free the list of bluetooth MAC addresses from memory
device_list | the list of bluetooth MAC addresses |
num_of_devices | the cardinality of device array - represents the number of bluetooth devices stored in the array |
Definition at line 55 of file pam_bt_misc.c.
int is_dev_trusted | ( | FILE * | log_fp, |
char * | dev, | ||
char ** | trusted_devices, | ||
int | num_of_devices | ||
) |
Return 1 iff the given address is one of the trusted devices the user trusts
log_fp | the handle of the log file |
trusted_devices | the array of trusted bluetooth MAC addresses of the user |
num_of_devices | the number of devices the user trusts |
Definition at line 46 of file pam_bt_misc.c.
int verify_bt_addr | ( | char * | address, |
FILE * | log_fp | ||
) |
Return 1 iff the address is a valid Bluetooth Address
NOTE: Bluetooth Address is a 48 bit address. The function will treat address as a string expecting:
address | the bluetooth address |
log_fp | the file handle for the log file |
Definition at line 5 of file pam_bt_misc.c.
const char* trusted_dir_path = "/etc/proxy_auth/" |
Definition at line 3 of file pam_bt_misc.c.