summaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)AuthorFilesLines
2018-06-13fdev: Improve fdev handling with epollJosé Bollo5-16/+74
Change-Id: I53c6eb394772e40f87000a0e5383be923f5d15f1 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-06-13jobs: Cosmetic changesJosé Bollo1-4/+10
Change-Id: I7505c3c5bcec9e2b7af645a59a3716cf9bfec552 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-06-13afb-hsrv: remove dependency to systemdJosé Bollo1-15/+16
Change-Id: I42428e7e57cb104b8575b60b1c7985782e9f779f Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-06-13Make DBUS transparency optional (off by default)José Bollo5-20/+62
The implementation of API transparency through DBUS is not used at the moment. To improve independancy to systemd (it relies on systemd library) removing it should be possible. Change-Id: I5750a92527dc3e9cf7dcd27625dce6a020797a3d Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-06-13afb-hswitch: Improve HTTP scanning of API/VERBJosé Bollo1-10/+25
The previous version wasn't accepting verbs containing slashes (/) but the websocket did. Some interesting use-cases are allowed by accepting to include slashes in verbs. Change-Id: I2786b5ed0e2686c3e68bb9b74923064d8953243c Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-06-13afs-supervisor: Fix typoJosé Bollo6-21/+35
Change-Id: Icc3c15f577f04117cdfaf2bcbcc4d15a99d02138 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-05-05Convert pc.in from UTF-8 to US-ASCIIRonan Le Martret2-2/+0
Change-Id: I14fd54002c6df3b3e566a9f5a61bc89b595f4e3d Signed-off-by: Ronan Le Martret <ronan.lemartret@iot.bzh>
2018-05-03CMakeLists: Fix c++ buildRonan Le Martret1-0/+1
On debian, for example, we need to specify C14 compatibility Change-Id: I4fd4d6dbca03d085def61e373617ab5336ebcb0b Signed-off-by: Ronan Le Martret <ronan.lemartret@iot.bzh>
2018-03-16fdev: Improve readabilityJosé Bollo1-3/+3
Change-Id: If81cdf43703b6ff3128ea79940ce240f56918b9d Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-03-16afb-websock: Fix a double freeJosé Bollo2-2/+13
The commit 0ebdff94d461abd4328cf45a6281c15139a045eb of libmicrohttpd fixed a bug but introduced a double free of hreq resource attached to the connection. That commit is between versions 0.9.59 and 0.9.60 of libmicrohttpd. Now, hreq is freed in 'end_handler' of afb-hsrv.c Change-Id: Ia865d65c5f9ef5ce787eb6545802ac8ea37ae468 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-03-16afb-websock: Fix double closeJosé Bollo1-0/+2
Integration with newer versions of libmicrohttpd was closing two times the file descriptor: - one time by the websocket within afb - one time by the upgrade close of libmicrohttpd Thanks to 'autoclose' feature of 'fdev', the solution is quiet easily. Bug-AGL: SPEC-1345 Change-Id: Ifb691b3f69c095b5ff44bfd7f7267ea24d52df6d Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-27Update date of copyright noticesJosé Bollo153-153/+153
Change-Id: If9d7e7728df086fbb7214f1de5cbec35cd2f1d9b Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-27afs-supervisor: Enforce session check (for token)José Bollo1-10/+10
Change-Id: I6fdc419923944183d12c9c931e90e276f3dc8ac6 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-27afs-supervisor: Force replyJosé Bollo1-0/+3
Change-Id: Iba3a80e327b4324c1bdb4f8a0e7b73021d6e4ad6 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-27afb-supervision: Fix typoJosé Bollo1-1/+1
Change-Id: Iaff0340d64b02ee24f45caadd01d74314afabacd Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-26afs-supervisor: Fix supervisor deafnessJosé Bollo1-0/+1
Change-Id: I68fc2799d1789cbcf5516539ab2af3ecd9b61e56 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-26afs-supervisor: Add systemd service and configJosé Bollo3-7/+35
Change-Id: I64bf8de01dbb8cf9581ed0be358d81fa84106520 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-26afs-supervisor: Remove dependency to systemdJosé Bollo1-16/+7
Change-Id: I74b455f569f9bf1a6e6970163fb50a946875e42d Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-26supervisor: Make it a HTTP serverJosé Bollo10-1127/+964
The supervisor now run as an HTTP server by default. Change-Id: Ia0a654cd97c941f15b212c5364d739e2196662e4 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-26afb-session: Fix bugsJosé Bollo1-2/+3
Change-Id: Ib45e2db47827b4527435a40c4b79d02fb3ab488a Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-26afb-stub-ws: cosmetic improvementsJosé Bollo1-6/+9
Change-Id: Ib6adf0ca4bdfee9d3da07055430bfe1974ac28bc Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-26afb-config: Add traceses for tracing sessionsJosé Bollo3-1/+20
Change-Id: I9d36eb9eb4991066f94b1340262ad27467fc591e Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-22memo-supervisor: added a memo for supervisorJosé Bollo1-0/+1102
Change-Id: I2bf91ef9b1407d1a72eea3708782836c625ebdc0 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-22afb-supervision: Fix error on 'trace'José Bollo2-3/+3
Change-Id: I81c89e6c9406df583087845d6b38a19fff8ab0eb Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-22xreq: export a function to get reqJosé Bollo4-24/+45
Change-Id: Ie7eac225f514349926341b7db61ea0eb9029c5d8 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-22fdev: Introduce fdev for file event handlingJosé Bollo26-133/+649
This is an effort to keep cutting dependency to systemd. Change-Id: I9a0c032a1095e297c7f3ac5b67827fda3658b8d9 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-21afb-systemd: Integrate sd-fds featuresJosé Bollo7-100/+43
Change-Id: I59d194ba675912a42922f0905933b1cea796c78a Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-21afb-systemd: Isolate systemd main entriesJosé Bollo12-71/+117
This change prepares the possibilty to remove the dependency to systemd/libsystemd. Change-Id: Ife4181d6c7195230a11a32e527b8973af6a096e1 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-21Bump version to 5.99-FFRC0José Bollo2-3/+3
Change-Id: I58829d86b871260538ce40d4be8480849d7f4b80 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-15afb-monitor: Add session and rework permissionsJosé Bollo3-66/+99
The new verb session is available to get session info and to renew the token. See examples below. The permission required is now just to being check meaning having the token. Example: afb-client-demo -H localhost:5555/api?token=456 monitor session ON-REPLY 1:monitor/session: OK { "response":{ "uuid":"5a30c118-319c-43a2-82d5-fc2198d01938", "token":"", "timeout":32000000, "remain":31999985 }, "jtype":"afb-reply", "request":{ "status":"success", "uuid":"5a30c118-319c-43a2-82d5-fc2198d01938" } } monitor session {"refresh-token":true} ON-REPLY 5:monitor/session: OK { "response":{ "uuid":"5a30c118-319c-43a2-82d5-fc2198d01938", "token":"2f60faf8-ad04-457e-9f56-5c0c20b5f1fc", "timeout":32000000, "remain":32000000 }, "jtype":"afb-reply", "request":{ "status":"success", "token":"2f60faf8-ad04-457e-9f56-5c0c20b5f1fc" } } Change-Id: Ic93bae80616e5dad1640e73ac9f472b7b385104f Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-15afb-session: Verbs for timeout and remining timeJosé Bollo2-11/+29
Change-Id: Ia1922187aa78d8633835c4a77e8aa533fa5d5f7d Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-15afb-context: Early token changeJosé Bollo1-0/+4
Change-Id: If27d84a702513b92f08c97ef91bf8cf89b5af238 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-15afb-config: Fully exclude config monitoringJosé Bollo1-0/+4
Change-Id: I93b3d49f46d4dec607b08cc439b6cb06cf68ec32 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-15afb-config: Increase the default timeout of sessionsJosé Bollo1-2/+2
The management of sessions is not very well understood actually. People are using it without refreshing the token. This has the effect that the binder closes sessions after one hour. So no demo can run more than one hour! Increasing the timeout to more than one year will solve the demo problem but will not fully solve the overall problem. Bug-AGL: SPEC-1296 Bug-AGL: SPEC-1293 Change-Id: Icb9adb4939a138c19be36280bf1e6643d04489ae Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-15afb-session: Use clock insensitive to time changesJosé Bollo1-1/+9
Bug-AGL: SPEC-1296 Bug-AGL: SPEC-1293 Change-Id: I1838175b48dff8fbf1fd65bd304f9cfe917ced80 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-14afs-supervisor: Add verb for running discoveryJosé Bollo1-3/+20
Change-Id: Iea9e54fa7a1c93ba3927c836d6ca5bcded77ca66 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-14afs-supervisor: Add discovery mechanicJosé Bollo4-13/+125
Change-Id: Icfcdcc16d0433454c9bb0785d0690f7f173980ae Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-13afs-supervisor: Improve name of supervisor apiJosé Bollo3-7/+8
Change-Id: Id0b43cecb91fa0a405c07f63d4f8c2f026c8a70c Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-13supervision: Add retrieval of configJosé Bollo3-56/+75
Change-Id: Id7bb91c267037cbd36c6cafef62d3c39a67e77db Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-13afb-config: export config to jsonJosé Bollo2-2/+95
Change-Id: I8918733753ec791e77eb8a71032ccdb35fa68d71 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-13supervision: Add supervision and supervisorJosé Bollo6-0/+984
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-13afb-stub-ws: Fix segfault on diconectionJosé Bollo1-1/+2
Change-Id: I7826b86e4d4cc921b2daaca5c8dda0fd27faae10 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-13afb-stub-ws: Protect against self-destructionJosé Bollo1-0/+2
Change-Id: I43b15b8f675173a693816a0b8efd05fd024278f0 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-13afb-trace: Add tracing of sessionsJosé Bollo3-132/+255
Change-Id: Ieba4032bed526ca158dc69558177a038df95988b Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-13afb-session: Add function to enumerate sessionsJosé Bollo2-0/+23
Change-Id: Ifaa1aa02d0562c40763ac03b7c05df7f9f9c8127 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-13test-session: Add check of hookingJosé Bollo2-18/+142
Change-Id: I3ac86b41537651e360e7ea21ad425f2e1bffb852 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-13afb-session: Insert call to hookingJosé Bollo1-7/+20
Change-Id: I7d91b133761c7c751300bf1344321e295cce1bc3 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-09afb-hook: Add hooks for sessionJosé Bollo2-4/+228
Change-Id: I4fbd6bf57958abb366a742b12afb92bfc03ad299
2018-02-09afb-session: Refactor and test unitJosé Bollo6-242/+549
The session are refactored and now to include a test unit. Change-Id: Ia8c4b707191f3af95c0549b333d14b384a81eaa7 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
2018-02-09afb-stub-ws: Fix a session leak bugJosé Bollo1-1/+1
Change-Id: I55b72d7a4e7ca18e61addb3b0efa2ec75729060b Signed-off-by: José Bollo <jose.bollo@iot.bzh>