Age | Commit message (Collapse) | Author | Files | Lines |
|
Change-Id: Ifb2de3c13f814f16f23ead9357f4fec97b3e675c
Signed-off-by: Stephane Desneux <stephane.desneux@iot.bzh>
|
|
This allows to acces monitoring interface using
url HOST/monitoring/ when option --monitoring is set.
Change-Id: If7dfc89e4c4db0d87ec5c8e74f9243691a3ec0e8
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
When set, this option will enforce a random
token in any cases.
Not using the option --token has the same effect
asking for a random token.
So the option now serves to enforce a random token.
Change-Id: Iea2cee44b95d5479c36217d312ab6e8ce6726005
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
Installs basic interface for monitoring and
add the option --monitoring / -M to activate
the alias /monitoring. This makes the page
/monitoring/monitor.html available.
Change-Id: Iebe0959f0a5e7c396fe7ce6862d0f9c883733824
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
Change-Id: Iae8475559ee2381ee7d687c6afc2e6ce7145ebf3
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
- use flex/css for correct layout
- handles disconnection nicely
- handles initial token
- fix typo in afb-api-so
Change-Id: I386b98f9d6a2182029d39a373a9820478f97cfa6
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
Change-Id: If7f576e8f4bdc613d836c158df6e5f0bbfea87b7
Signed-off-by: Stephane Desneux <stephane.desneux@iot.bzh>
|
|
Change-Id: Ibbc5924adef104d9ec7399e7943baa1d799d2572
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
Change-Id: Ib3133cbcd458fbd1ca1ee5aac64700c9ebc83b60
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
Change-Id: I476cb5c7cd873802273f243eb3454857c8723e96
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
Instead of writing --ldpaths=/dev/null simply use
the option --no-ldpaths
Change-Id: Ia278989b90a079d998ba0cbb7a6bb78c46d58090
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
This option allows to specify a loading path where
binding that fails on load are ignored.
Change-Id: Ie0646f88ba9207dd117737a8b251a7a42f424f02
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
Error detection wasn't reported when an
error occured in a subdirectory.
Also closes the opened directories on error
and allows a mode for ignoring binding errors.
Change-Id: I34e52de8ea71bf84556878a395b56c6628cc5d9a
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
Updating hooks is needed (at the moment) also for events.
Change-Id: If5f6259499b3d35a2fd5504185b9f751f96c4e06
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
Unitialized struct member.
Change-Id: Ib507aef4ceb459571b6bb70e5a879e1f34823a77
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
|
|
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
Updating hooks is needed (at the moment) after trace requests
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
- Fills the info fields
- take care of C in names
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
The client stub isn't connecting anymore
automatically to the apiset. The function
'afb_stub_ws_client_add' provides the feature.
The client now returns a afb_api structure.
name and on_hangup features added.
Change-Id: I204cc39adeb782f5d40360c22c79d14f54dd5c63
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
And use it in monitor.
Change-Id: I9efbd19cfbdc665d1d686831b529ebaa7bd917a2
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
After integration of UPGRADE in libmicrohttpd,
the header "Connection: Upgrade" has to be removed
because it is now sent 2 times.
This caused Webkit to fail to connect its websocket.
Bug-AGL: SPEC-821
Change-Id: Ib9744208cf7175f0c56e513b18b53ab0a9b60b9f
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
Change-Id: I197350dee4f85dfc167ea4ffcb54e6e3ceba89ad
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
Change-Id: Ia339dc1d1291ef52fbec3c928537721ed7410694
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
Send an error reply if no reply was sent.
Change-Id: Ibc5c98d22b9820f1f0b5370083f79a52213ddc61
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
Change-Id: Iea02e0720e40c2b4630a15606e798c53b4bbfe6c
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
Change-Id: I6bb1dffeb17fdcaf6e3a2686651d35dd0b0500b9
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
Thanks to Markus Fritzsch and clang-check
Change-Id: I4822eb14bff49680df05e472363228cc82566edf
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
Change-Id: Id21c444d6d18a78f731458a43519a131515385c0
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
Change-Id: I39c9295596e1c328533319354dddbf5191f11463
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
This api allows to receive events when particular actions
are reached.
At the moment, tracing is bound to the API monitor
and can trace anything. In the future, this will not be
the case and the API monitor will only allow to trace
requests of its session. The tracing of all will
be available for supervision only.
Change-Id: I880852612c2f77ff5329496b16c75fe602db4090
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
Because SO_PEERCRED returns without error even when no data
is available (tcp by example), the resulting uid is now tested.
Also, for tcp, by default avoid by default to create a default
user value. Instead, return NULL. This will allow client having
an HTTP/Websocket connection to get full rights on the binder.
Change-Id: I2defb585bf79c023e2391c2e18d6de17e5112770
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
The function 'afb_req_subcall_req' can be used to make asynchronous
subcalls. It improves the function 'afb_req_subcall' by automatically
keeping the request opened for the callback and by passing it, the
request, as an extra argument of the callback.
Change-Id: I2dc79c01fc25c7a65b9c8cc9e001a5b85fba99df
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
The file afb-subcall is now integrated within
afb-xreq. It improves memory allocation and
performance of synchronous calls.
Change-Id: I4190199babbe0559527438b530b19ac9a35ec38b
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
This allows afb_service_call to set NULL callback
and afb_service_call_sync to set a NULL result pointer.
Change-Id: Ie16ae5557e6851d2f1e730ad32450489242b5daa
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
Change-Id: Ibe8e0b4e59ad4d5f0b0cca82ccdb3d0f035b0501
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
Change-Id: Ie1ac2eb96fb29711c38750c3babe7cbd4b472079
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
The "for_all" functions are facilities for handling
collections of json objects
Change-Id: Icaecb39e9f0108e1fb1c42bef2a90935feb312ed
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
For the implementation of monitoring, the event
should be pushed without hooking internal.
Change-Id: I4372bbc55e78c851db660a69bb2e60995fbdc88f
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
Removes the api prefix of the event name.
Change-Id: I050dc86beb08659751c1e57b8d3ea233bac9e411
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
Change-Id: I3764edf986c01ef30e21ee1ec7e2b0098eec9e9e
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
Change-Id: Iceffd965f12f7afe658e374c29f13ab0abc8bb19
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
Fixes maybe-uninitialized warning
Change-Id: I5416fb2c6cc017ddc53984475432fff90c41d42b
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
Insertion of calls to personality for the only
pupose to be able to set breakpoint at some
strategic places.
The chosen places are:
- After the debug wait point. The intend is to
allow simulation of breakpoint after attaching
to the waiting process.
- Before starting the bindings but after loading
it. The intend is to allow loading of symbols and
setting of breakpoints in the debugged binding
without attaching to afb-daemon that comes without
debug symbols.
Change-Id: Ie3bfce0956c9844586c7a5f8bd820acb7f58772c
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
Change-Id: I634abe531606a30ba241c85bf650589c5f0ea4ca
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
Change-Id: Ibfcaa34c32cb4bbdedbaee08360ef829321c3035
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
The functions wrap_json_unpack, wrap_json_vunpack,
wrap_json_check, wrap_json_vcheck, wrap_json_match and
wrap_json_vmatch can be used to get items in a json
object.
These functions are likely to be compatible in the
format with the unpacking functions of the library
jansson [1].
[1] http://jansson.readthedocs.io/en/2.10/apiref.html#parsing-and-validating-values
Change-Id: I18ad702498b9a70215d88b2a3c13bd0f6194bb45
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
The functions wrap_json_pack and wrap_json_vpack
can be used to create json object. These functions
are likely to be compatible in the format with the
packing functions of the library jansson [1].
[1] http://jansson.readthedocs.io/en/2.10/apiref.html#building-values
Change-Id: I2e251bdb9b590ba55707c5a9ed60528cad927fb3
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
When AFB_DEBUG_WAIT is used, the file /tmp/afb-debug-<PID>
is created and contains the name of the awaiting point
(without tailing new line)
Signals other than SIGINT are ignored when waiting
for SIGINT. This improves the cleaning up. Example:
the signal SIGTERM is delayed until after removal of
the debugging indication file.
Change-Id: I5c896e4d9a3a098affc18d4282e260d9bb253611
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
When compiled with -DAGL_DEVEL or -DAFB_INSERT_DEBUG_FEATURES
afb-daemon interprets the environment variables
AFB_DEBUG_BREAK and AFB_DEBUG_WAIT.
The environment variable AFB_DEBUG_BREAK make afb-daemon emit
a break (SIGINT) that should be treated by the debugger.
The environment variable AFB_DEBUG_WAIT make afb-daemon wait
for a break (SIGINT) to continue. This can be used to attach
a debugger.
The content of the variables AFB_DEBUG_BREAK and AFB_DEBUG_WAIT
is a list of key names of the point where the action should
occur. The list is separated by spaces or commas ','.
Example:
AFB_DEBUG_WAIT=main-entry,start-load
The defined points are: main-entry, main-args, main-start,
start-entry, start-load, start-start, start-http, start-call,
start-exec.
Here some of their characteristic:
- main-entry: at the beginning befaore any other instruction
- main-args: after parsing arguments
- main-start: after daemonisation before starting
- start-entry: at start entry
- start-load: before loading bindings after initialisation of afb-daemon
- start-start: after loading bindings befaore starting it
- start-call: after init before starting HTTP server
- start-http: after http server, before calling startup calls
- start-exec: before running the --exec command
Change-Id: Id405e749c590fb95f32e30a7d37c30b6412cf0a5
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|
|
1: emits the correct PID even if daemonized
2: run the startup calls before executing the client (if any)
Change-Id: I7e06961d4a88bc6083aa1bc48ccedf57b76ea268
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
|