INSUN PYO [Thu, 21 Dec 2017 03:50:04 +0000 (12:50 +0900)]
Remove unused dbus socket.
/run/user/%UID/dbus/user_bus_socket has been temporarilly remained
for previous version support.
Nobody uses this for now.
/run/user/%UID/bus is used instead.
Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: I10a5c4153201e5a620b9460f3b5f938bbbedcea7
INSUN PYO [Wed, 22 Nov 2017 07:38:15 +0000 (16:38 +0900)]
spec: Change useradd/groupadd to handle in security-manager.
I left useradd/groupadd to make this package available from open source
without security-manager.
Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: I3348c321a44df01c082c36bc09844a122adb669a
INSUN PYO [Wed, 22 Nov 2017 06:19:47 +0000 (15:19 +0900)]
spec: remove unused /var/lib/dbus directory
Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: Iee10a2a4b58f69f8bc90d7209fa6a11762fb11ad
Adrian Szyndela [Wed, 18 Oct 2017 09:27:57 +0000 (11:27 +0200)]
switch compilation mode from Thumb to ARM
This is needed to be able to put uprobes in the library code as
the uprobes in current kernel versions work only with ARM code.
Change-Id: I5e2ee2ac37fda354fa93f080e5553d2c823144ec
sanghyeok.oh [Thu, 12 Oct 2017 05:31:28 +0000 (14:31 +0900)]
kdbus: default allow receive_type=signal for session bus
Change-Id: Id6077d3f10567df5e1320cc66b9048160a2995a4
Signed-off-by: sanghyeok.oh <sanghyeok.oh@samsung.com>
Hyotaek Shim [Wed, 13 Sep 2017 01:58:13 +0000 (10:58 +0900)]
Remove Apache-2.0 in the dbus.spec
Change-Id: I91791d0efa0c2e42fb715c03293675da4fb7a4a3
Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
Hyotaek Shim [Tue, 12 Sep 2017 01:33:35 +0000 (10:33 +0900)]
Change the license of test-runner.c from the Apache-2.0 to the MIT license to avoid conflict with LGPL-2.1+/GPL-2.0+
Change-Id: I2f1ac40f78c692571bc11b1b9e5262bdd1c6c125
Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
Adrian Szyndela [Mon, 7 Aug 2017 14:38:00 +0000 (16:38 +0200)]
GVariant: fix for not having offset for empty arrays
GVariant requires offsets for variable length struct
members. Empty variable-size arrays which are at the beginning
of a struct have offset 0. However, 0 was used as
the indicator that there should be no offset added.
This patch changes 0 to the impossible value.
Change-Id: Icbc18e87831a20727f142a1218e6736e76bcce82
Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
sanghyeok.oh [Tue, 18 Jul 2017 08:28:16 +0000 (17:28 +0900)]
kdbus: check policy only for method call or unicast signal
Otherwise just send it. It will checked by receiver.
Change-Id: I9652f7548adf9605111d28cdc236f36fbe319c97
Signed-off-by: sanghyeok.oh <sanghyeok.oh@samsung.com>
sanghyeok.oh [Fri, 14 Jul 2017 09:09:05 +0000 (18:09 +0900)]
kdbus: libdbuspolicy: To perform policy check, pass unique name to libdbuspolicy
In case of signal broadcasting, message has null destination,
To perform policy check correctly, libdbus should pass unique name to libdbuspolicy as destination.
Change-Id: I62704ed838432823c0c11951bbb6234905167716
Signed-off-by: sanghyeok.oh <sanghyeok.oh@samsung.com>
Adrian Szyndela [Fri, 9 Jun 2017 09:32:40 +0000 (11:32 +0200)]
Remove legacy smack support, keep upstream smack support
This commit reverts four commits.
There was a need for additional minor changes to make it work.
Revert "GetConnectionCredentials - add smack support"
This reverts commit
13d888ca95c75c14a4919b36cc0a15979fb1d42b.
Revert "packaging: enable Smack support"
This reverts commit
54f95c99cf4d53f5566511fc0cdc21b230909b29.
Revert "Enforce smack policy from conf file"
This reverts commit
1d028039f5d34de8a1224d2ad0d8bc75b3da3ca4.
Revert "Enable checking of smack context from DBus interface"
This reverts commit
7af23db240c54e9923c76234b7e9c7a243d2d428.
Change-Id: I4bf7ce8d43717e1deb5d980f87be39220922b422
INSUN PYO [Fri, 23 Jun 2017 07:49:08 +0000 (16:49 +0900)]
spec: remove unused files
Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: Idbeb2980bb1ee7c1f5989ba6dc487b20f72c93b8
INSUN PYO [Mon, 27 Mar 2017 12:53:16 +0000 (21:53 +0900)]
cynara: add exception code for cynara_session_id retriving
If client exit as soon as async call, cynara_session_from_pid return null.
cynara_session_from_pid checks /proc/pid to verify client id.
===== reproduce =====
su - owner
dbus-send --type=method_call --system --dest=org.tizen.system.deviced /Org/Tizen/System/DeviceD/Display org.tizen.system.deviced.display.CustomBrightness
=====================
Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: Ic313e9d4f9531135865824d8512b9eb1ac6f4c9e
sanghyeok.oh [Thu, 25 May 2017 13:12:07 +0000 (22:12 +0900)]
kdbus:pass sender to dbuspolicy1_check_out
Change-Id: I23894a2e44484a896df441caa6dd3e86bbae9d78
Signed-off-by: sanghyeok.oh <sanghyeok.oh@samsung.com>
Adrian Szyndela [Fri, 26 May 2017 14:16:22 +0000 (16:16 +0200)]
kdbus: assure that GVariant footer is not split
Change-Id: I4a92adaf91c3205274be5d87302908ad35cb2dbf
Adrian Szyndela [Thu, 1 Jun 2017 11:41:09 +0000 (13:41 +0200)]
kdbus: make error messages more consistent with glib
Change-Id: Iccb88417fc83290ed70a32e86bc80c4a5c44c6ee
Adrian Szyndela [Tue, 9 May 2017 12:45:26 +0000 (14:45 +0200)]
kdbus: bugfix for return codes on call to non-existing destination
Calling a method on non-existing destination with auto start disabled
caused error org.freedesktop.DBus.ServiceUnknown.
Non-kdbus implementation gives org.freedesktop.DBus.NameHasNoOwner.
This patch makes kdbus return the same error as non-kdbus implementation.
Change-Id: Iadbf060159e91d5c4e10ea9a26abb50d02154a5f
INSUN PYO [Wed, 29 Mar 2017 16:04:52 +0000 (01:04 +0900)]
change user socket address from %t/dbus/user_bus_socket to %t/bus
Sync to upstream.
Upstream uses %d/bus, but tizen uses %t/dbus/user_bus_socket.
Some application use hard coded address %d/dbus/user_bus_socket.
So, I remain SymLinks temporary.
Later changing all application, I will remove SymLinks.
Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: I7d00fc96fdbae28a6bd610ced0adfdcc52ec8987
INSUN PYO [Sat, 11 Mar 2017 14:56:27 +0000 (23:56 +0900)]
remove unused code
Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: I1192579e02963b0246bb99d54f415cab673abbe6
sanghyeok.oh [Fri, 14 Apr 2017 06:26:46 +0000 (15:26 +0900)]
license:rearrange license from each packages
Change-Id: I6ec1d0ff94b9e237bb158d5c49031d0463ec3bc2
Signed-off-by: sanghyeok.oh <sanghyeok.oh@samsung.com>
sanghyeok.oh [Wed, 12 Apr 2017 11:24:27 +0000 (20:24 +0900)]
svace:fix leak
Change-Id: Ifce97dae8b9390d492708bfd7d7467c1af1ed132
Signed-off-by: sanghyeok.oh <sanghyeok.oh@samsung.com>
Adrian Szyndela [Fri, 7 Apr 2017 16:35:58 +0000 (18:35 +0200)]
GVariant: don't remove padding from no field
When a message is created with dbus_message_new() it gets no fields.
Then, while appending some values, but before setting path, interface,
etc. a single field appears - signature. If there would be more fields,
then after deleting the last field we would need to remove padding
from second-to-last field. In case of a single field, we have
no second-to-last field, only empty dictionary. Empty dictionaries do
not have padding at the end, so we do not need to remove it.
Change-Id: Idb15f3999a3ff0117f906ec632f462eb5cdaab09
INSUN PYO [Mon, 3 Apr 2017 03:36:45 +0000 (12:36 +0900)]
Increase release version for MCD.
Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: I8f115a821731b01727bc19510962f9b7720f3d89
INSUN PYO [Fri, 31 Mar 2017 03:17:31 +0000 (20:17 -0700)]
Merge "License: add license files - add COPYING" into tizen
INSUN PYO [Fri, 31 Mar 2017 02:58:09 +0000 (11:58 +0900)]
License: add license files - add COPYING
Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: Ib7372970eb1a1e24154de189848cd0ca2faa2563
INSUN PYO [Mon, 20 Mar 2017 16:36:32 +0000 (01:36 +0900)]
Replace user dbus.socket and dbus.service file.
The dbus source includes dbus.socket and dbus.service for user session.
But tizen uses its own files.
Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: Ied720b0fd5e792845ab626f680d01cbb3e9b2db9
INSUN PYO [Mon, 27 Mar 2017 13:17:42 +0000 (22:17 +0900)]
License: add license files
Change-Id: I2e1785ef0d14c2d5a9aa1d49904064b4fe80f9ee
INSUN PYO [Thu, 23 Mar 2017 07:49:21 +0000 (16:49 +0900)]
cynara: add exception code for disconnection code.
For disconnection connections, _dbus_connection_get_dispatch_status_unlocked always returns DBUS_DISPATCH_DATA_REMAINS.
So __bus_loop_dispatch is going around in an infinite loop.
If _dbus_loop_dispatch is out of the loop, _dbus_connection_get_dispatch_status_unlocked returns DBUS_DISPATCH_COMPLETE as normal.
It is dead-lock.
====================== reproduce ==================
su - owner
dbus-send --type=method_call --system --dest=org.tizen.system.deviced /Org/Tizen/System/DeviceD/Display org.tizen.system.deviced.display.CustomBrightness
dbus-send --type=method_call --system --dest=org.tizen.system.deviced /Org/Tizen/System/DeviceD/Display org.tizen.system.deviced.display.CustomBrightness
dbus-send --type=method_call --system --dest=org.tizen.system.deviced /Org/Tizen/System/DeviceD/Display org.tizen.system.deviced.display.CustomBrightness
dbus-send --type=method_call --system --dest=org.tizen.system.deviced /Org/Tizen/System/DeviceD/Display org.tizen.system.deviced.display.CustomBrightness
dbus-send --type=method_call --system --dest=org.tizen.system.deviced /Org/Tizen/System/DeviceD/Display org.tizen.system.deviced.display.CustomBrightness
===================================================
Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: I8565a757a62b50a27d2c6b6931e125af452ff74e
INSUN PYO [Sun, 5 Mar 2017 00:30:23 +0000 (09:30 +0900)]
Change bus connection check code : bus_connection_is_active () ==> dbus_connection_get_is_connected ()
Since dbus-daemon uses asynchronous cynara functions, some cynara functions are delayed.
In the cynara delay function, check if connection is valid or not.
If the connection is lost, the "connection->slot_list" is cleared. So bus_connection_is_active() will cause crash.
Since dbus_connection_get_is_connected() only checks for "connection->transport->disconnected" variables, it works fine if only the reference count is valid.
====================================================================================================================================
0 bus_connection_is_active (connection=<optimized out>) at connection.c:1291
1 0xb6f08134 in bus_deferred_message_dispatch (deferred_message=0xb7c93668) at check.c:498
2 0xb6f0c7ce in bus_connection_dispatch_deferred (connection=0xb7ca0008) at connection.c:2677
3 0xb6f0826a in bus_check_queued_message_reply_callback (deferred_message=0xb7cb5870, result=<optimized out>) at check.c:188
4 0xb6f0cdda in bus_cynara_check_response_callback (check_id=<optimized out>, cause=<optimized out>, response=<optimized out>, user_response_data=0xb7cb5870) at cynara.c:333
5 0xb6db2994 in Cynara::Logic::processCheckResponse (this=this@entry=0xb7c0cdb8, checkResponse=...) at /usr/src/debug/cynara-0.14.7/src/client-async/logic/Logic.cpp:277
6 0xb6db3a8e in Cynara::Logic::processResponses (this=this@entry=0xb7c0cdb8) at /usr/src/debug/cynara-0.14.7/src/client-async/logic/Logic.cpp:324
7 0xb6db4578 in Cynara::Logic::processIn (this=this@entry=0xb7c0cdb8) at /usr/src/debug/cynara-0.14.7/src/client-async/logic/Logic.cpp:348
8 0xb6db45d8 in Cynara::Logic::process (this=0xb7c0cdb8) at /usr/src/debug/cynara-0.14.7/src/client-async/logic/Logic.cpp:175
9 0xb6daf35a in operator() (this=<optimized out>) at /usr/lib/gcc/armv7l-tizen-linux-gnueabi/4.9.2/include/c++/functional:2439
10 Cynara::tryCatch(std::function<int ()> const&) (func=...) at /usr/src/debug/cynara-0.14.7/src/common/exceptions/TryCatch.h:42
11 0xb6dafa5e in cynara_async_process (p_cynara=0xb7c0c7a0) at /usr/src/debug/cynara-0.14.7/src/client-async/api/client-async-api.cpp:236
12 0xb6f0cdb4 in bus_cynara_watch_callback (watch=<optimized out>, flags=<optimized out>, data=<optimized out>) at cynara.c:288
13 0xb6f14f5a in _dbus_loop_iterate (loop=loop@entry=0xb7c0b618, block=block@entry=1) at dbus-mainloop.c:819
14 0xb6f1506c in _dbus_loop_run (loop=0xb7c0b618) at dbus-mainloop.c:883
15 0xb6f046f6 in main (argc=<optimized out>, argv=<optimized out>) at main.c:661
(gdb) info locals
d = 0x0
(gdb) f 1
(gdb) p *deferred_message->sender
$27 = {refcount = {value = 1}, mutex = 0xb7c41c70, dispatch_mutex = 0xb7c41cb0, dispatch_cond = 0xb7c41cd0, io_path_mutex = 0xb7c41c90, io_path_cond = 0xb7c41d08, outgoing_messages = 0x0, incoming_messages = 0x0, expired_messages = 0x0, message_borrowed = 0x0,
n_outgoing = 0, n_incoming = 0, outgoing_counter = 0xb7c41df8, transport = 0xb7c41778, watches = 0xb7c41b20, timeouts = 0xb7c41b40, filter_list = 0x0, slot_mutex = 0xb7c41d40, slot_list = {slots = 0xb7c41fc0, n_slots = 1}, pending_replies = 0xb7c41b60,
client_serial = 10, disconnect_message_link = 0x0, wakeup_main_function = 0x0, wakeup_main_data = 0x0, free_wakeup_main_data = 0x0, dispatch_status_function = 0x0, dispatch_status_data = 0x0, free_dispatch_status_data = 0x0, last_dispatch_status = DBUS_DISPATCH_COMPLETE,
objects = 0xb7c41f20, server_guid = 0x0, peer_smack_label = 0xb7c41c60 "System", dispatch_acquired = 0, io_path_acquired = 0, dispatch_disabled = 0, shareable = 0, exit_on_disconnect = 0, route_peer_messages = 1, disconnected_message_arrived = 1,
disconnected_message_processed = 1, have_connection_lock = 0, generation = 1}
(gdb) p deferred_message->sender->slot_list
$28 = {slots = 0xb7c41fc0, n_slots = 1}
(gdb) p *deferred_message->sender->slot_list->slots
$31 = {data = 0x0, free_data_func = 0x0}
(gdb) p connection_data_slot
$32 = 0
(gdb) p deferred_message->sender->slot_list->slots[0]
$35 = {data = 0x0, free_data_func = 0x0}
(gdb) p deferred_message->sender->transport->disconnected
$33 = 1
====================================================================================================================================
Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: Iab2abfb63030d15e380e11c057ee1f99124e102e
(cherry picked from commit
62fd017b7dbf577f736de7f8d44e6a94b4334472)
INSUN PYO [Wed, 15 Mar 2017 02:12:18 +0000 (11:12 +0900)]
kdbus: fix build error for emulator64-wayland.
After applying unify build, all profiles build kdbus unconditionally even if you do not use kdbus.
Before unify build, kdbus was not enabled in emulator64-wayland environment.
Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: I22f8dd17cdfeed17a3ef7aa8da5c738fc677f0ad
Geunsik Lim [Tue, 7 Mar 2017 08:53:38 +0000 (17:53 +0900)]
[4.0] Remove OBS Project Dependency (kdbus/TV)
- Please add "dbus-libs-extension-kdbus" for TV/arm-wayland images via JIRA-TRE issue.
- Without this commit, this package won't be built correctly in Tizen 4.0.
Change-Id: I94d98f44cad637af2acc22898c74a806e74f73bb
Signed-off-by: Geunsik Lim <geunsik.lim@samsung.com>
Reviewed-by: Insun Pyo <insun.pyo@samsung.com>
INSUN PYO [Mon, 6 Mar 2017 07:27:32 +0000 (16:27 +0900)]
Remove unused code (Don't use pgrep)
Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: I8809374f28baae65606b679b3ef15fc71a91f98d
INSUN PYO [Mon, 6 Mar 2017 01:46:23 +0000 (10:46 +0900)]
change socket.target.wants/dbus.service ==> socket.target.wants/dbus.socket
Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: Iad33b6770458d2e3e4e8507cfae5b1489da5bf0c
(cherry picked from commit
e1a4cf929e2095ae0bd1e503a59388791e18e1cb)
sanghyeok.oh [Tue, 28 Feb 2017 09:00:42 +0000 (18:00 +0900)]
patch: bus: Fix timeout restarts
patch from upstream
https://cgit.freedesktop.org/dbus/dbus/commit/?id=
529600397bcab47b9bed5da9208c2df05c8b86b4
author Michal Koutn? <mkoutny@suse.com> 2016-05-24 09:14:11 (GMT)
committer Simon McVittie <smcv@debian.org> 2017-02-01 10:42:50 (GMT)
commit
529600397bcab47b9bed5da9208c2df05c8b86b4 (patch)
tree
17e9af27f973a4e0132ee23e405ed7d52fdb0771
parent
befd186c0b005f1e1130cb3e4923c689085a8dbc (diff)
bus: Fix timeout restarts
The code counting pending fds relied on restart of timeouts when they are
enabled. This patch adds function that ensures that such enabled timeouts
have their timekeeping data reset (and not only when timeout is
registered into event loop processing).
When timeouts weren't reset, they'd fire at rather random and mainly
incorrect moments leading to interruption of connections of dbus-daemon.
Every time we reset the interval, we also need to re-enable the timeout
and mark its end time to be recalculated by the event loop, so combine
the old set_enabled(TRUE) with set_interval() as a new restart() method.
This leaves all the set_enabled() calls having a FALSE parameter, so
remove the parameter and rename the method to disable().
[smcv: fix minor coding style issues]
[smcv: replace set_reenabled()/set_interval() pair with restart()]
[smcv: replace set_enabled(FALSE) with disable()]
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=95619
Change-Id: Ia80641554800ae09ae22d4615b87eda0697c5f3e
Signed-off-by: sanghyeok.oh <sanghyeok.oh@samsung.com>
Hyotaek Shim [Wed, 1 Mar 2017 05:44:33 +0000 (21:44 -0800)]
Merge changes Icf330ba3,I7354c21e into tizen
* changes:
tests: general fix for tests setup
tests: generating coverage version of the library
INSUN PYO [Wed, 22 Feb 2017 02:38:43 +0000 (11:38 +0900)]
make link : /usr/lib/systemd/user/dbus.socket ==> /usr/lib/systemd/user/sockets.target.wants/dbus.socket
Until now, dbus.socket of user session was not running in the sockets.target.
dbus.socket has been triggered by dbus.service's dependencies.
The dbus.service is included in basic.target.
Therefore, there are some dependency issues.
If a service runs before dbus.service, the service can not accesses dbus system.
(Since dbus.socket is not yet activated, so you can not make a dbus connection.)
I have modified dbus.service to be explicitly run in sockets.target.
On the session bus, sockets.target is guaranteed to run before all services.
Signed-off-by: INSUN PYO <insun.pyo@ubuntu1604.playinsun.pe.kr>
Change-Id: Ic46f1a46b458e2017b0025c6e564ac1204eb8cc8
(cherry picked from commit
1beb067e73478b3948980eb19e379a8986dc365a)
Hyotaek Shim [Wed, 22 Feb 2017 00:04:31 +0000 (16:04 -0800)]
Merge "tizen: notify service readyness after successful config file parsing" into tizen
Karol Lewandowski [Fri, 10 Feb 2017 15:16:55 +0000 (16:16 +0100)]
tizen: notify service readyness after successful config file parsing
This commit works around systemd -> dbus -> (nss) -> systemd deadlock
occuring in Tizen.
Situation is depicted on diagram below:
systemd dbus nss
| . .
| . .
1> reads config . .
| . .
2> reg. nofification . .
| for dbus.service . .
| . .
| . .
3> exec. services . .
| | . .
| (start srv...) . .
| | . .
| 4>------------(exec) .
| | .
*-<---(notification)=<| .
\ | .
.\> call dbus.serv | .
. handler | .
. | 4a> read config .
. |> conn. to bus | .
. | 4b> resolve user .
. |> call dbus . and groups .
. \ . initgroups() .
. ------------>. | .
. (blocking) . \---------->select module
. . (blocking) based on conf.
. . |
(below not executed) . |> security-manager
. . | module selected
. . |
. . |
[sec-manager.socket]<---------------------<| call security-manager
. . (DEADLOCK) . on unix socket
. . .
Solid line (|) means active thread of execution, dot (.) means
code not executed (blocked).
The root cause of the problem is that systemd calls external
API in blocking manner, which, due to system configuration, requires
systemd to handle its request for successful completion.
(systemd should start security-manager service via sec-manager.socket
activation).
The exact place this situation is triggered is in dbus' initialization.
This commits works around this problem by delaying dbus.service readyness
notification - effectively - resolving the problem.
Situation becomes:
systemd dbus nss security-manager
| . . .
| . . .
1> reads config . . .
| . . .
2> reg. nofification . . .
| for dbus.service . . .
| . . .
| . . .
3> exec. services . . .
| | . . .
| (start srv...) . . .
| | . . .
| 4>------------(exec) . .
| | . .
| | . .
| | . .
| | . .
| | . .
| 4a> read config . .
| | . .
| 4b> resolve user . .
| . and groups . .
| . initgroups() . .
| . | . .
| . \---------->select module .
| . (blocking) based on conf. .
| . | .
| . |> security-manager .
| . | module selected .
| . | .
| . | .
[sec-manager.socket]<---------------------<| call security-manager .
. | . . on unix socket .
. | . .
. |> exec service ----------------------------------------------->(exec)
. | . . |
<--| . |<-------------------------<| handle call
| . | |
| |<-----------------| |
| | . |
| | . |
.\> call dbus.serv |>finish conf. file. |
. handler | parsing . |
. | | . |
*-<---(notification)-<|> explicitly . |
.\ | | notify startup . |
. \> call dbus.serv | finished . |
| handler | . |
. | | . |
. |> conn. to bus | . |
. | | . |
. |> call dbus | . |
. \ | . |
. ------------>* dispatch loop . |
. (blocking) | . |
. | . |
|<--------------------< handle call . |
| | . |
Change-Id: Ifeaf299fc8653b583cd06ca9fd4f9f8045a2bde0
INSUN PYO [Fri, 17 Feb 2017 02:19:31 +0000 (11:19 +0900)]
Change the method to get DBUS addres when changing user with "su -" command.
The adbd's privilege has been changed form "System::Privileged" to "User::Shell".
So, pgrep does not work with smack errors when accessing /proc.
If it fails to find DBUS address, the fixed address is used.
Signed-off-by: INSUN PYO <insun.pyo@ubuntu1604.playinsun.pe.kr>
Change-Id: I4f9e0bc0939de2ecd7b866df8a2f266b4258338b
(cherry picked from commit
4f11f164f44d78ec6a54892e5d4095ca52e7117d)
Adrian Szyndela [Thu, 16 Feb 2017 11:47:41 +0000 (12:47 +0100)]
tests: general fix for tests setup
Before this patch tests were installed into custom directory
/usr/lib/dbus-tests/test-suites/dbus-tests
Originally, dbus wants its installed tests in
/usr/lib/dbus/installed-tests/dbus
This path seems to be partially hardcoded in the configuration
files - it relies on defined datadir. As datadir is used
also for something else than tests, we don't want to change it.
This commit switches installation directory to the original,
and adds symbolic links in our custom directory.
Change-Id: Icf330ba3b5be59ee941d51b15a8f78a082297846
Adrian Szyndela [Mon, 6 Feb 2017 11:17:24 +0000 (12:17 +0100)]
tests: generating coverage version of the library
Additionally:
- immediate output of test results instead of caching and printing
at the end;
- removed manual-authz test, because it is not meant to be run
automatically.
Change-Id: I7354c21e0fa457ad7e2a4a53e1c898e5039b7f73
Konrad Lipinski [Fri, 3 Feb 2017 12:40:29 +0000 (13:40 +0100)]
gbs incremental build support
Change-Id: Ic1960a3b70df234a3e9ad141d6c335d373c331ec
Adrian Szyndela [Wed, 11 Jan 2017 11:54:07 +0000 (12:54 +0100)]
Merge tizen_3.0 into tizen
This merge commit adds integration tests.
Change-Id: I2b0ecb3c48fec72a6be1a7d6406b5580bbb38ec8
Hyotaek Shim [Wed, 28 Dec 2016 01:53:31 +0000 (10:53 +0900)]
Modify from APACHE-2.0 to Apache-2.0
Change-Id: I2e509fe1a4f275c9f5b35290bdd2d218c4b3692a
(cherry picked from commit
4f9a3114261606c3edf84655b2e5752dee33585f)
Hyotaek Shim [Wed, 28 Dec 2016 01:53:31 +0000 (10:53 +0900)]
Modify from APACHE-2.0 to Apache-2.0
Change-Id: I2e509fe1a4f275c9f5b35290bdd2d218c4b3692a
Hyotaek Shim [Wed, 28 Dec 2016 01:43:22 +0000 (10:43 +0900)]
Add .spec description about LICENSE.APACHE2.0
Change-Id: I127f90398b4fe33b3c3b412ef84a42ab2683efd5
(cherry picked from commit
44c73590bab90e63b21fadfffadbfa1d745d9613)
Hyotaek Shim [Wed, 28 Dec 2016 01:43:22 +0000 (10:43 +0900)]
Add .spec description about LICENSE.APACHE2.0
Change-Id: I127f90398b4fe33b3c3b412ef84a42ab2683efd5
Hyotaek Shim [Wed, 28 Dec 2016 01:39:34 +0000 (10:39 +0900)]
Add LICENSE.APACHE2.0
Change-Id: Icf4a2b514abfeb458305c58ab99aad4cfbab325d
(cherry picked from commit
4b5af3aba73865b45a144694fa9c918ed7f9233e)
Hyotaek Shim [Wed, 28 Dec 2016 01:39:34 +0000 (10:39 +0900)]
Add LICENSE.APACHE2.0
Change-Id: Icf4a2b514abfeb458305c58ab99aad4cfbab325d
Krystian Kisielak [Thu, 13 Oct 2016 13:01:27 +0000 (15:01 +0200)]
Adds package for dbus-integration tests.
Change-Id: I0175a6c710e418be7f3b06f1df6ad13396e40f8c
Signed-off-by: Krystian Kisielak <k.kisielak@samsung.com>
Adrian Szyndela [Fri, 14 Oct 2016 13:24:43 +0000 (15:24 +0200)]
Bugfix, GVariant: missing padding for fixed-size tuples.
There is a requirement for fixed-size tuples:
size of such tuple must be a multiply of its required alignment.
That part was overlooked in the implementation.
This commit adds padding accounting for both reading and writing.
Change-Id: I0825be6436b93b836dc333f5a395fdf1021f2a06
Adrian Szyndela [Thu, 13 Oct 2016 13:04:10 +0000 (15:04 +0200)]
Bugfix, GVariant: no padding in root-level tuples
Change-Id: If84df57e9985f484e3c3c63854df5ff666cc1794
sanghyeok.oh [Mon, 26 Sep 2016 06:24:35 +0000 (15:24 +0900)]
change socket in/out label
Change-Id: Ifcc7dacb077615c8f5392a6b213d402d4775af05
Signed-off-by: sanghyeok.oh <sanghyeok.oh@samsung.com>
Adrian Szyndela [Tue, 13 Sep 2016 07:59:34 +0000 (09:59 +0200)]
bugfix: sec_label was copied without ending byte
Change-Id: I3d9aa7f2d608e6706600a87ad5dc570033244f98
Lukasz Skalski [Mon, 5 Sep 2016 09:35:38 +0000 (11:35 +0200)]
kdbus: fix for GetConnectionSELinuxSecurityContext method call
To keep compatibility with dbus1, GetConnectionSELinuxSecurityContext
method call should always return SELinuxSecurityContextUnknown error
on systems without SELinux (even if other LSM systems, like for example
SMACK, are available on platform).
Change-Id: I347cdf665a03fc047d267752b23c4503bf5218e3
Hyotaek Shim [Thu, 1 Sep 2016 03:38:20 +0000 (20:38 -0700)]
Merge "calculate kdbus timeout based on user timeout" into tizen
Konrad Lipinski [Thu, 25 Aug 2016 09:07:26 +0000 (11:07 +0200)]
calculate kdbus timeout based on user timeout
Change-Id: I9fd1720e5c2a1edaa1fcd66b78df0b0238e9ce9f
sanghyeok.oh [Wed, 31 Aug 2016 08:35:40 +0000 (17:35 +0900)]
Bugfix:abnormal using of _dbus_validate_bus_name
Change-Id: I1eb91da587469381f69ada2939a980d8ea1f40e1
Signed-off-by: sanghyeok.oh <sanghyeok.oh@samsung.com>
sanghyeok.oh [Mon, 22 Aug 2016 07:15:49 +0000 (16:15 +0900)]
support NameAcquired & NameLost signal subscription
Change-Id: I6f7c2e39c8872ebae8a68157515ef247325b3cc4
Signed-off-by: sanghyeok.oh <sanghyeok.oh@samsung.com>
INSUN PYO [Fri, 19 Aug 2016 08:03:21 +0000 (17:03 +0900)]
Support Lazy-Mount feature - move user dbus.service from default.target.wants to basic.target.wants
Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: I5ec89ce65fe196d54a4b130e41a83a82acb40101
INSUN PYO [Fri, 19 Aug 2016 05:18:07 +0000 (14:18 +0900)]
Support Lazy-Mount feature - suprem.sec.samsung.net/confluence/display/SFH/Lazy+mount
Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: I4b9f4a435f2aae9215bb7d77bb423715884d01e1
Hyotaek Shim [Fri, 19 Aug 2016 04:28:33 +0000 (21:28 -0700)]
Merge "omit standard match iff sender=org.freedesktop.DBus" into tizen
Konrad Lipinski [Wed, 17 Aug 2016 12:27:55 +0000 (14:27 +0200)]
omit standard match iff sender=org.freedesktop.DBus
Change-Id: Ib8a1c138983124a2597b0c700f5c6a2c7dd4744e
Adrian Szyndela [Wed, 17 Aug 2016 14:38:06 +0000 (16:38 +0200)]
kdbus: fixed memory leak in reply_ListNames()
Additionally, added some documentation for _kdbus_list().
Change-Id: I267100ec123f33a1b10f3ce1c9aca3004ac1e9fc
INSUN PYO [Tue, 16 Aug 2016 09:15:48 +0000 (02:15 -0700)]
Merge "kdbus: fixed memory leak in "hello" command." into tizen
Hyotaek Shim [Tue, 16 Aug 2016 09:13:28 +0000 (18:13 +0900)]
Relocate ifdef LIBDBUSPOLICY to avoid build erros when libdbuspolicy is disabled
Change-Id: I8710e8d2ff1911ea11b48984ebda227a0a8658fe
Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
Adrian Szyndela [Tue, 16 Aug 2016 08:47:13 +0000 (10:47 +0200)]
kdbus: fixed memory leak in "hello" command.
Change-Id: I0f5c1882a9ffcc9a0186a834ad73e72a10b9f239
INSUN PYO [Tue, 16 Aug 2016 08:38:52 +0000 (01:38 -0700)]
Merge "%reconfigure instead of autoreconf" into tizen
INSUN PYO [Tue, 16 Aug 2016 07:57:32 +0000 (00:57 -0700)]
Merge "kdbus: policy: add more detailed errors descriptions" into tizen
Lukasz Skalski [Wed, 3 Aug 2016 15:23:37 +0000 (17:23 +0200)]
kdbus: policy: add more detailed errors descriptions
Change-Id: I683f77755c6fefafbcc255107839f10362abadb0
Konrad Lipinski [Thu, 11 Aug 2016 12:53:15 +0000 (14:53 +0200)]
%reconfigure instead of autoreconf
Change-Id: Icc74194668757c9e7ebc79d63d4a3b2ec65d0c34
Adrian Szyndela [Wed, 10 Aug 2016 12:38:09 +0000 (14:38 +0200)]
Bugfix: always set n_fds
Change-Id: Ib10e3eb7c102f63a5d63c550858ad4a5edee8c2b
Adrian Szyndela [Wed, 10 Aug 2016 12:03:09 +0000 (14:03 +0200)]
Bugfix: removed double-stripping of parentheses
GVariant keeps body inside structs. This fact is kept hidden from
libdbus user. Thus, struct parentheses have to be added, removed
in proper places. There was one such place in
_dbus_type_reader_gvariant_init(). However, it was not sufficient
and get_const_signature() also got stripping code. Unfortunately,
I didn't notice that stripping should be removed in the first
of these functions. This commit fixes that.
Change-Id: I5c2e6c7c8212d283fd6da1cc998a2711038905f3
Adrian Szyndela [Tue, 2 Aug 2016 12:05:41 +0000 (14:05 +0200)]
Bugfix: corrected sizeofs
Change-Id: I9281352c2afa0bb39c69df35ce28054fab83b994
Hyotaek Shim [Wed, 27 Jul 2016 08:38:04 +0000 (01:38 -0700)]
Merge "fix in system dbus.service (User=dbus, Group=dbus)" into tizen
Hyotaek Shim [Wed, 27 Jul 2016 08:37:35 +0000 (17:37 +0900)]
fix in system dbus.service (User=dbus, Group=dbus)
Change-Id: Iea127741bfe3f5fbe68eb13d98933307420007b2
Hyotaek Shim [Wed, 27 Jul 2016 08:33:33 +0000 (17:33 +0900)]
fix in system dbus.service (User=dbus, Group=dbus)
Change-Id: I5041323980664baecdde25a65230e7c6a3608bac
Hyotaek Shim [Wed, 20 Jul 2016 04:53:52 +0000 (13:53 +0900)]
Onlycap-related fix in system dbus.service (SmackProcessLabel=System)
Change-Id: I725049c020a107774f79cf2685c7505497b6723d
INSUN PYO [Tue, 19 Jul 2016 04:29:08 +0000 (13:29 +0900)]
[PATCH 1/2] kdbus: Fix the overflow for timeout calculation
The maximum value of unsigned long is
4294967295 which is too small
for storing nano second. It makes the overflow in calculation.
Use LLU instead of LU for timeout calculation.
======================================================================
Subject: [PATCH 2/2] kdbus: adjust the default value for timeout to 50 sec
This definition is used by the default value for timeout value.
But in the other places, 50 sec is used by default value for timeout,
instead of using it.
Let's align it with the others
Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: Idddaf3f095ad47206f8b6ac11bc46c43c3bc8bd3
Hyotaek Shim [Tue, 19 Jul 2016 01:44:09 +0000 (18:44 -0700)]
Merge "gvariant marshal: nested struct offset size accounts for fixed members" into tizen
Hyotaek Shim [Tue, 19 Jul 2016 01:42:50 +0000 (18:42 -0700)]
Merge "dbus-marshal-gavariant : Update offset bytes size whenever message is appended" into tizen
Karol Lewandowski [Mon, 11 Jul 2016 11:40:38 +0000 (13:40 +0200)]
cynara: Do not drop messages when sender connection is closed
Information about required sender credentials is cached in internal
structures at authentication stage.
Change-Id: Ibe0b3ba8b608728c11347d406c9ab2e4495cafc7
Konrad Lipinski [Thu, 7 Jul 2016 17:01:07 +0000 (19:01 +0200)]
gvariant marshal: nested struct offset size accounts for fixed members
Change-Id: Ib8c7876c9a0072bde28201cb754b26ed20bbf892
Jonghwa Lee [Tue, 5 Jul 2016 02:18:17 +0000 (11:18 +0900)]
dbus-marshal-gavariant : Update offset bytes size whenever message is appended
check_offsets_in_body_for_adding() is called only when former data is not fixed
sized data. If former written data is fixed size one (e.g. integer, boolean..)
it skips to update offset bytes size even message body size exceeds its limits.
It results invalid memory access on reciever-side.
This patch fixes it to update offset bytes size whenever message is appended.
Change-Id: I2b94955d40debc5129b5f3c193e197efb542141b
Signed-off-by: Jonghwa Lee <jonghwa3.lee@samsung.com>
INSUN PYO [Wed, 29 Jun 2016 04:32:55 +0000 (13:32 +0900)]
increase max_replies_per_connection to 1024 form 128
Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: I36556b8c5bc02a935a03e7cc18edb01633d1ae97
Hyotaek Shim [Tue, 28 Jun 2016 09:00:02 +0000 (02:00 -0700)]
Merge "bus check privilege : ignore dropping message about signal message when sender's connection is disconnected during checking privilege." into tizen
INSUN PYO [Tue, 28 Jun 2016 08:57:12 +0000 (17:57 +0900)]
bus check privilege : ignore dropping message about signal message when sender's connection is disconnected during checking privilege.
Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: Ibbb6b63f3efecf450ea2c34fcd87477ceb1bcc2c
Hyotaek Shim [Tue, 28 Jun 2016 07:38:07 +0000 (16:38 +0900)]
to defend against a security attack of changing external PATH
Change-Id: I5d2149d71b1c593fc337052becefc68f3cf7265c
Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
Lukasz Skalski [Mon, 27 Jun 2016 09:38:36 +0000 (11:38 +0200)]
bus: fix bus_context_check_security_policy checking
Change-Id: I41ead9532676d201bdd3396652e2de573136ea60
INSUN PYO [Fri, 24 Jun 2016 06:24:17 +0000 (15:24 +0900)]
Bug fix for signal hash(bloom filter) operations in dbus-transport-kdbus
Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: I9ad96a0eebf938c24d2531486c117a7096112573
INSUN PYO [Thu, 23 Jun 2016 06:05:24 +0000 (15:05 +0900)]
policy: fix: add missing free #2
Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: Ibe6c2f780ecf4ea5ff549266b102546dce6d88d6
Hyotaek Shim [Thu, 23 Jun 2016 05:47:35 +0000 (22:47 -0700)]
Merge "policy: fix: add missing free" into tizen
INSUN PYO [Wed, 22 Jun 2016 04:11:18 +0000 (13:11 +0900)]
increate max_connections_per_user to 512 from 256
Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: Ifb592255396e295fd9b34e63b9ba5831e85f2601
Karol Lewandowski [Tue, 21 Jun 2016 16:03:27 +0000 (18:03 +0200)]
policy: fix: add missing free
Change-Id: I4a7cca5935c1bddbdd94a44ebec1c814670380bf
Hyotaek Shim [Fri, 17 Jun 2016 06:24:33 +0000 (15:24 +0900)]
activation: set children oom_score_adj to 0
Change-Id: Ida85bcb12ea8ce0a1af948fb0f1600ed21f3323e
Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
INSUN PYO [Thu, 9 Jun 2016 07:06:11 +0000 (16:06 +0900)]
move pid file path of system dbus-daemon from /var/run/dbus/pid to /tmp/dbus_launch
Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: I5c8d33c56c84bbc00242109a0c10af5c2a7664fd
INSUN PYO [Thu, 9 Jun 2016 06:37:18 +0000 (15:37 +0900)]
Remove --nopidfile flags from system dbus-daemon
Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: I3ac61db553aa290288792f440e43c6dcd87add8e
Hyotaek Shim [Wed, 8 Jun 2016 06:20:39 +0000 (15:20 +0900)]
Removing some temp files
Change-Id: I4188c820422e41f9f7e3c41c0237c78eafc2c158
Hyotaek Shim [Wed, 8 Jun 2016 06:14:51 +0000 (15:14 +0900)]
Fix for smack error when dbus-daemon(session) accesses proc/cmdline
Change-Id: Ifadafc677821c6a8b0b747d31f1c4128533ce3ed
Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
Lukasz Skalski [Wed, 25 May 2016 12:46:10 +0000 (14:46 +0200)]
kdbus: always pack message header as as single PAYLOAD_VEC item
According to PORTING-DBUS1 document [1], the message header in its
entirety must be contained in a single PAYLOAD_VEC item. What's more,
in case of memfd transport, message footer (which contains body signature
and offsets size) has to be attached at the end of message as a yet another
PAYLOAD_VEC item.
[1] https://cgit.freedesktop.org/systemd/systemd/tree/src/libsystemd/sd-bus/PORTING-DBUS1
Change-Id: I282589c0641c1eb97f874fcfd6e3bee6ecacc8ae