aboutsummaryrefslogtreecommitdiffstats
path: root/src/afb-context.h
AgeCommit message (Collapse)AuthorFilesLines
2020-01-08Update copyright datesJosé Bollo1-1/+1
Signed-off-by: José Bollo <jose.bollo@iot.bzh> Change-Id: I01a566a693b8ec6239209c9323ae4ff15a07f737
2019-12-03afb-perm: separate access to permission dbJosé Bollo1-1/+14
Access to permission database is better handled in a separate file. It will afterward evolve to integrate cynagora. Bug-AGL: SPEC-2968 Signed-off-by: José Bollo <jose.bollo@iot.bzh> Change-Id: Iebcd4e227e3e6c318029926499afb9d41d3f72c7
2019-12-03afb-context: Move credentials to contextJosé Bollo1-6/+17
The split between context and credentials in requests was somehow artificial and awkward. This change move the credentials to the context and removes as many references to credentials as possible in favor of working on contexts. Change the value returned by afb_auth_check to be 1 if validated, 0 or less than zero if not validated. Bug-AGL: SPEC-2968 Signed-off-by: José Bollo <jose.bollo@iot.bzh> Change-Id: I979dc841e03247e126e3fa8433a1cc0d4108adf0
2019-11-29Move tokens from sessions to requestsJose Bollo1-2/+2
Tokens are no more related to sessions. Each request provides a token. In the case of websockets or connected link, the context can record the token. Bug-AGL: SPEC-2968 Change-Id: I1442b0422584c5a5b860ddb826518b0e673612f9 Signed-off-by: Jose Bollo <jose.bollo@iot.bzh>
2019-11-29Don't return the uuidJose Bollo1-1/+0
uuid is available in cookies and through a call to monitor/session Bug-AGL: SPEC-2968 Change-Id: I72912f3dc7985cca09e77c952e416b608711abbe Signed-off-by: Jose Bollo <jose.bollo@iot.bzh>
2019-11-25Remove returning tokenJose Bollo1-1/+0
The token is no more generated by the binder Bug-AGL: SPEC-2968 Change-Id: I43f66c7613b42d33058e167b831a93b2112d3b9e Signed-off-by: Jose Bollo <jose.bollo@iot.bzh>
2019-11-25Remove refreshing tokenJose Bollo1-3/+0
The token is no more generated by the binder but by some external component. Bug-AGL: SPEC-2968 Change-Id: I2c6221034272ab097e21e7727e4840b6b47bd0dc Signed-off-by: Jose Bollo <jose.bollo@iot.bzh>
2019-11-20Introduce object for tokensicefish_8.99.1icefish/8.99.18.99.1Jose Bollo1-0/+4
For further optimizations, the token is represented by a specific structure. Bug-AGL: SPEC-2968 Change-Id: I3d46a12c8c16809c6cc1d543fa2e6309927ed84d Signed-off-by: Jose Bollo <jose.bollo@iot.bzh>
2019-02-06Update copyright datehalibut_7.90.0halibut/7.90.07.90.0José Bollo1-1/+1
Change-Id: I3aaa92b2bfb01699ee8ae609272e93032b6f1a9d Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-27Update date of copyright noticesJosé Bollo1-1/+1
Change-Id: If9d7e7728df086fbb7214f1de5cbec35cd2f1d9b Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2017-10-09Atomic context initialisation for bindingsJosé Bollo1-1/+1
Change-Id: I3e81b64d57c917da1fba9b3a9387d0f4d7f3e6b7 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2017-10-09afb-context: add const qualifier for api_keyJosé Bollo1-1/+1
Change-Id: I138d70698342cc2350d4f9098bcf5c486d16faba Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2017-05-05Expose session UUID from contextJosé Bollo1-2/+3
Change-Id: Ifcf08e840b4ac92889874700c630495b6dfc3e66 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2017-05-05make function afb_context_set return a statusJosé Bollo1-1/+1
Change-Id: I5172c58288e5974001f3478f7cee94d7a98abe7d Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2017-05-05session: start to manage concurrencyJosé Bollo1-0/+1
Change-Id: I5895fa14fcb496e71fba600994e7e454cf1d110b Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2017-05-04Make LOA local to the bindingJosé Bollo1-4/+0
Change-Id: If0494a19a4ce2865af699491c1f6d7b73bce8f11 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2017-05-04add function to get the current LOAJosé Bollo1-0/+1
Change-Id: I0f2a0eae8b4de982549fa4a87e2e0f8150c7d6cc Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2017-04-04Introduce subcontext for subcallsJosé Bollo1-0/+2
Change-Id: I5460e9c502cee814c59a0ee60c2be001385e7b4a Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2017-03-27Replace session's value with sessions's cookiesJosé Bollo1-1/+1
This is a simplifaction with the benefits of only allocating needed memory and avoiding to create indexes on apis (path to dynanic?). Conversely it replaces a direct access with a linear search. Change-Id: Ibb130528ad8f23dfd6b420c228f51e181efb2664 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2017-01-03Improves naming of session's moduleJosé Bollo1-3/+3
Make names looking like other names Change-Id: I63ce3d8a3d84193eca9d517cecb1888d630a9b2d Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2017-01-03Adds 2017 to copyrightsJosé Bollo1-1/+1
Change-Id: Id85c4eb4e36a05b61346004ba95daa19faf5074f Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2016-05-23Setting and checking LOAJosé Bollo1-1/+1
Change-Id: I02c3795c6e212491605861228eb60b731be78537 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2016-05-22Fix AFB_SESSION_CREATE behaviourJosé Bollo1-1/+6
This commit allows to call methods having AFB_SESSION_CREATE at any time. This commit prepares the future LOA (level of authorization) implementation that wille soon replace the deprecated mechanism of AFB_SESSION_CREATE. Change-Id: Ia3e99186e012fcd55a6c81a7067ab5b4aca21e4d Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2016-05-13cleaning copyrightsJosé Bollo1-1/+1
Change-Id: I4ff7349b1a87f92a7d9f378c715054061f06df57 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2016-05-10Refactoring requests and context handlingJosé Bollo1-0/+53
Also adds a first (untested) implmentation of the afb services over dbus. Change-Id: Id1bdeccf75f3a70d3658bdaf0510d6e7b97f6c32 Signed-off-by: José Bollo <jose.bollo@iot.bzh>