lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Date:	Fri, 26 Mar 2010 11:12:57 +0800
From:	dove xia <dovexia@...il.com>
To:	Marcel Holtmann <marcel@...tmann.org>
Cc:	linux-kernel@...r.kernel.org, linux-bluetooth@...r.kernel.org
Subject: Small issue to receive "org.bluez.AudioSource" dbus message

Hi,

	This is Dove as a new comer to Linux-bluetooth group.
	
	Currently, I am developing BlueZ stack works as A2DP Sink. After the
BlueZ runs, it works smoothly. I have developed a program run on Linux
user space to catch the BlueZ DBus messages. But the program can't
receive DBus messages from "org.bluez.AudioSource".
	I have test the BlueZ works as source before, I can receive DBus
messages from  "org.bluez.AudioSink".
	
	The test step is:
	1. Update the audio.conf to set the bluetooth works as A2DP Sink.
	2. Set the bluetooth into discoverable mode.
	3. Use another bluetooth device (a mobile), search and connect BlueZ.
	3. Play music from mobile.
	4. use a test program on Linux user space to catch the BlueZ
AudioSource DBus messages.
	The test case will expect the test program can catch the AudioSource
dbus messages, but it failed.
	
	I have traced the BlueZ source code, found a little clew in
audio/a2dp.c, the function sbc_setconf_ind() and mpeg_setconf_ind()
have not called source_new_stream() while the a2dp_sep->type is
AVDTP_SEP_TYPE_SINK, I patched code to call source_new_stream().
base on BlueZ 4.62, in audio/a2dp.c

@@ -341,6 +341,8 @@

 	if (a2dp_sep->type == AVDTP_SEP_TYPE_SOURCE)
 		sink_new_stream(dev, session, stream);
+	if (a2dp_sep->type == AVDTP_SEP_TYPE_SINK)
+		source_new_stream(dev, session, stream);

 	return TRUE;
 }
@@ -445,6 +447,8 @@

 	if (a2dp_sep->type == AVDTP_SEP_TYPE_SOURCE)
 		sink_new_stream(dev, session, stream);
+	if (a2dp_sep->type == AVDTP_SEP_TYPE_SINK)
+		source_new_stream(dev, session, stream);

 	return TRUE;
 }

	After I patched the code, my test program can receive the
"org.bluez.AudioSource" DBus messages. the BlueZ work smoothly as
before. so I think this is a correct fix.

	Need your confirm.
	
-- 
BR
Dove
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ