ssh token: Fix -Wmissing-prototypes warnings

This commit is contained in:
Vojtech Trefny
2021-06-29 14:44:44 +02:00
parent 07d23c2ee8
commit 3589f9578a
3 changed files with 12 additions and 1 deletions

View File

@@ -211,7 +211,7 @@ parse_opt (int key, char *arg, struct argp_state *state) {
static struct argp argp = { options, parse_opt, args_doc, doc }; static struct argp argp = { options, parse_opt, args_doc, doc };
void _log(int level, const char *msg, void *usrptr) static void _log(int level, const char *msg, void *usrptr)
{ {
struct arguments *arguments = (struct arguments *)usrptr; struct arguments *arguments = (struct arguments *)usrptr;

View File

@@ -44,6 +44,16 @@
#define l_dbg(cd, x...) crypt_logf(cd, CRYPT_LOG_DEBUG, x) #define l_dbg(cd, x...) crypt_logf(cd, CRYPT_LOG_DEBUG, x)
const char *cryptsetup_token_version(void);
int cryptsetup_token_open_pin(struct crypt_device *cd, int token, const char *pin,
size_t pin_size, char **password, size_t *password_len, void *usrptr);
int cryptsetup_token_open(struct crypt_device *cd, int token,
char **password, size_t *password_len, void *usrptr);
void cryptsetup_token_dump(struct crypt_device *cd, const char *json);
int cryptsetup_token_validate(struct crypt_device *cd, const char *json);
const char *cryptsetup_token_version(void) const char *cryptsetup_token_version(void)
{ {
return TOKEN_VERSION_MAJOR "." TOKEN_VERSION_MINOR; return TOKEN_VERSION_MAJOR "." TOKEN_VERSION_MINOR;

View File

@@ -26,6 +26,7 @@
#include <libssh/sftp.h> #include <libssh/sftp.h>
#include <fcntl.h> #include <fcntl.h>
#include <libcryptsetup.h> #include <libcryptsetup.h>
#include "ssh-utils.h"
#define KEYFILE_LENGTH_MAX 8192 #define KEYFILE_LENGTH_MAX 8192