X-Git-Url: https://gerrit.automotivelinux.org/gerrit/gitweb?a=blobdiff_plain;f=src%2Fsession.h;h=0a61612dd38486cafe8aea10f88cca72d3f75998;hb=3d28e7d00cd8641bf600d47ed0e3e7e57cb5b439;hp=10af74fd161795cbf1c326e08d8c440600a0e40b;hpb=fb230eee946673ed5ebe9659d623c2a06d0a80ce;p=src%2Fapp-framework-binder.git diff --git a/src/session.h b/src/session.h index 10af74fd..0a61612d 100644 --- a/src/session.h +++ b/src/session.h @@ -16,6 +16,8 @@ */ // User Client Session Context +#pragma once + struct AFB_clientCtx { time_t expiration; // expiration time of the token @@ -26,12 +28,13 @@ struct AFB_clientCtx char token[37]; // short term authentication of remote client }; -extern void ctxStoreInit (int nbSession, int timeout, int apicount, const char *initok); +extern void ctxStoreInit (int nbSession, int timeout, const char *initok); extern struct AFB_clientCtx *ctxClientGetForUuid (const char *uuid); extern struct AFB_clientCtx *ctxClientGet(struct AFB_clientCtx *clientCtx); extern void ctxClientPut(struct AFB_clientCtx *clientCtx); extern void ctxClientClose (struct AFB_clientCtx *clientCtx); extern int ctxTokenCheck (struct AFB_clientCtx *clientCtx, const char *token); +extern int ctxTokenCheckLen (struct AFB_clientCtx *clientCtx, const char *token, size_t length); extern void ctxTokenNew (struct AFB_clientCtx *clientCtx);