RE: Issue found in service connman ordering

2015-01-29 Thread Priyaranjan Singh
Hello Tomasz & Patrik,

Thanks for your reply.

Here is my configuration of connman:

/etc/connman/main.conf
DefaultAutoConnectTechnologies = ethernet,wifi
PreferredTechnologies = wifi,ethernet,Bluetooth

1) Test 1:

Assumption:
Considering my Preferred Technologies (wifi > ethernet), WiFi discovered first 
and preferred over Ethernet, the Ethernet service will never be considered as 
default gateway till WiFi disconnected.

Basic steps:

Step 1) First connect target device with WiFi mobile phone (portable host spot 
enabled in Access point mode: data usage off)
# connmanctl services
List of all services:
*AR uttejSir { wifi_001cc1a25dff_757474656a536972_managed_none }


Step 2) Connect Ethernet device/phone (data usage on) with target

   Actual Service ordering:
#connmanctl services
List of all services:
*AO Wired{ ethernet_22d3f9d281a8_cable }
*AR uttejSir { wifi_001cc1a25dff_757474656a536972_managed_none }



   Expected Service ordering:
#connmanctl services
List of all services:
*AR uttejSir { wifi_001cc1a25dff_757474656a536972_managed_none }
*AR Wired{ ethernet_22d3f9d281a8_cable }


2) Test 2:

Assumption:
Considering my Preferred Technologies (wifi > ethernet), WiFi discovered second 
but preferred over Ethernet. But ethernet can still have default route if it 
goes to state 'online' while the WiFi one stays in 'ready'.

Basic steps:

Step 1) Connect Ethernet device/phone (data usage on) with target
~# connmanctl services
List of all services:
*AO Wired{ ethernet_4afaf413be54_cable }

Step 2) First connect target device with WiFi mobile phone (portable host spot 
enabled in Access point mode: data usage off)

   Actual Service ordering:
~# connmanctl services
List of all services:
*AR Wired{ ethernet_4afaf413be54_cable }
*AR uttejSir { wifi_001cc1a25dff_757474656a536972_managed_none }

   Expected Service ordering:
~# connmanctl services
List of all services:
*AO Wired{ ethernet_4afaf413be54_cable }
*AR uttejSir { wifi_001cc1a25dff_757474656a536972_managed_none }

There is a statement given in the documentation:
"After that the autoconnected service is continuously used and ConnMan won't 
select a new one until the network goes out of range.
When the service goes out of range or gets disconnected from the network 
infrastructure side, autoconnect is re-run and another favorite and 
autoconnectable service is selected.
The order in which services are considered can be modified by the 
PreferredTechnologies configuration in main.conf. "

As we have specified PreferredTechnologies, hence ordering should be modified.

2) Test 3:
Assumption:
Considering my Preferred Technologies (wifi > ethernet), WiFi discovered first 
and preferred over Ethernet


Basic steps:

Step 1) First connect target device with WiFi mobile phone (portable host spot 
enabled in Access point mode: data usage off)
# connmanctl services
List of all services:
*AR uttejSir { wifi_001cc1a25dff_757474656a536972_managed_none }


Step 2) Connect Ethernet device/phone (data usage off) with target

   Actual Service ordering:
# connmanctl services
List of all services:
*AR Wired{ ethernet_d2a3d4d7d613_cable }
*AR uttejSir { wifi_001cc1a25dff_757474656a536972_managed_none }

   Expected Service ordering:
#connmanctl services
List of all services:
*AR uttejSir { wifi_001cc1a25dff_757474656a536972_managed_none }
*AR Wired{ ethernet_22d3f9d281a8_cable }

Note:  Service ordering is as expected (WiFi default & top: *AO uttejSir  
followed by ethernet) when
WiFi mobile phone (portable host spot enabled in Access point mode: data usage 
on)
Ethernet device/phone (data usage on)

Yes, we will have to use Service.MoveAfter() or Service.MoveBefore() to make 
ordering user defined. But are these use cases a candidate for explicit service 
ordering?

Please correct my understanding if my assumptions are wrong.

Best Regards,
PriyarannjanS

-Original Message-
From: connman [mailto:connman-boun...@connman.net] On Behalf Of Tomasz Bursztyka
Sent: Thursday, January 29, 2015 6:45 PM
To: connman@connman.net
Subject: Re: Issue found in service connman ordering

Hi,

You are assuming the ordering based on the online state taking over the ready 
state.
However that's flawed, because there is no way you can guaranty for a service 
to get such online state all the time. There is quite a lot of logic behind the 
internet connectivity check, and it's not 100% bullet proof. (if you dns 
servers fails, if the distant connectivity check website is down, etc etc...) 
After all, being ready does not mean you cannot access the internet.

If you want to order service, you will have to order the

Patch to fix struct in6_pktinfo redefinition

2015-01-29 Thread Chris Hiszpanski
Here is the patch with a description of the issue and fix:

https://github.com/kuna-systems/connman/commit/685ec6af70824df85fe637f5f79565e9456211a0.patch

--
Chris Hiszpanski, Engineering
Kuna | San Francisco, CA
http://www.getkuna.com
___
connman mailing list
connman@connman.net
https://lists.connman.net/mailman/listinfo/connman


Connman test in C#

2015-01-29 Thread techi eth
Hi All,



Do we have any sample test written in C# for testing connman ?



I am trying to integrate one of my C# application running on Linux with
connman.



Regards,

Techi
___
connman mailing list
connman@connman.net
https://lists.connman.net/mailman/listinfo/connman


[PATCH] gsupplicant: Use OPEN auth_alg for open wifi networks

2015-01-29 Thread Slava Monich
With auth_alg set to "OPEN SHARED" some drivers (particularly bcmdhd)
won't connect to open wifi access points.
---
 gsupplicant/supplicant.c | 14 +-
 1 file changed, 13 insertions(+), 1 deletion(-)

diff --git a/gsupplicant/supplicant.c b/gsupplicant/supplicant.c
index e02a8d5..cd91f95 100644
--- a/gsupplicant/supplicant.c
+++ b/gsupplicant/supplicant.c
@@ -4069,6 +4069,14 @@ error:
g_free(data);
 }
 
+static void add_network_security_none(DBusMessageIter *dict)
+{
+   const char *auth_alg = "OPEN";
+
+   supplicant_dbus_dict_append_basic(dict, "auth_alg",
+   DBUS_TYPE_STRING, &auth_alg);
+}
+
 static void add_network_security_wep(DBusMessageIter *dict,
GSupplicantSSID *ssid)
 {
@@ -4414,8 +4422,12 @@ static void add_network_security(DBusMessageIter *dict, 
GSupplicantSSID *ssid)
char *key_mgmt;
 
switch (ssid->security) {
-   case G_SUPPLICANT_SECURITY_UNKNOWN:
case G_SUPPLICANT_SECURITY_NONE:
+   key_mgmt = "NONE";
+   add_network_security_none(dict);
+   add_network_security_ciphers(dict, ssid);
+   break;
+   case G_SUPPLICANT_SECURITY_UNKNOWN:
case G_SUPPLICANT_SECURITY_WEP:
key_mgmt = "NONE";
add_network_security_wep(dict, ssid);
-- 
1.8.3.2

___
connman mailing list
connman@connman.net
https://lists.connman.net/mailman/listinfo/connman


Re: Issue found in service connman ordering

2015-01-29 Thread Patrik Flykt

Hi,

>From the provided log I cannot figure out what goes on in your test
cases.

On Thu, 2015-01-29 at 13:01 +, Priyaranjan Singh wrote:
> ii) Connect USB  device in tether mode (data usage on): 
> ethernet_020c1e7b6205_cable

For example in this case, is the device connecting via USB? Why is
tethering mentioned here? If USB is tethering, then USB cannot be used
for connecting to an uplink Internet connetion at the same time.

> State: Online
> Favorite: true
> Connected first time: No
> Data Usage: Enabled
> 
> Service order: USB(AO), WiFi(AR)
> Test Result: Failed

What failed? Order, online or something else?

Cheers,

Patrik

___
connman mailing list
connman@connman.net
https://lists.connman.net/mailman/listinfo/connman


Re: Issue found in service connman ordering

2015-01-29 Thread Patrik Flykt
On Thu, 2015-01-29 at 15:15 +0200, Tomasz Bursztyka wrote:
> And, anyway, as pointed previously, switching to the latest and
> greatest version of ConnMan (1.27 now) is always a good idea!

...and with commit 3ac3eb0d092439247375886fd2a193538e2449df added on top
of version 1.27.

Cheers,

Patrik


___
connman mailing list
connman@connman.net
https://lists.connman.net/mailman/listinfo/connman


Re: Issue found in service connman ordering

2015-01-29 Thread Tomasz Bursztyka

Hi,

You are assuming the ordering based on the online state taking over the 
ready state.
However that's flawed, because there is no way you can guaranty for a 
service to get
such online state all the time. There is quite a lot of logic behind the 
internet connectivity
check, and it's not 100% bullet proof. (if you dns servers fails, if the 
distant connectivity check

website is down, etc etc...)
After all, being ready does not mean you cannot access the internet.

If you want to order service, you will have to order them by yourself 
through Service.MoveAfetr()

or Service.MoveBefore() methods.

And, anyway, as pointed previously, switching to the latest and greatest 
version of ConnMan (1.27 now)

is always a good idea!

Tomasz


___
connman mailing list
connman@connman.net
https://lists.connman.net/mailman/listinfo/connman


RE: Issue found in service connman ordering

2015-01-29 Thread Priyaranjan Singh
Hello,

Thanks for reply.

Sorry, I pasted table from MS Word document.

Here are the service ordering issues mentioned in my last email.

Please confirm the failures or clarify in case my understanding is wrong.

Test index: 1
i) Connect WiFi  mobile phone  (data usage on): 
wifi_001cc1a25dff_757474656a536972_managed_none
State: Online
Favorite: true
Connected first time: Yes
Data Usage: Enabled

Service order: Wifi(AO)

ii) Connect USB  device in tether mode (data usage on): 
ethernet_020c1e7b6205_cable
State: Ready
Favorite: true
Connected first time: Yes
Data Usage: Enabled

Service order: Wifi(AO), USB(AR)
Test Result: Passed


Test index: 2
i) connect WiFi mobile phone with data usage disable: 
wifi_001cc1a25dff_757474656a536972_managed_none
State: Ready
Favorite: true
Connected first time: No
Data Usage: Disabled

Service order: Wifi(AR)

ii) Connect USB  device in tether mode (data usage on): 
ethernet_020c1e7b6205_cable
State: Online
Favorite: true
Connected first time: No
Data Usage: Enabled

Service order: USB(AO), WiFi(AR)
Test Result: Failed


Test index: 3
i) connect WiFi mobile phone with data usage disable: 
wifi_001cc1a25dff_757474656a536972_managed_none
State: Ready
Favorite: true
Connected first time: No
Data Usage: Disabled

Service order: Wifi(AR)

ii) Connect USB  device in tether mode (data usage off): 
ethernet_020c1e7b6205_cable
State: Ready
Favorite: true
Connected first time: No
Data Usage: Disabled

Service order: USB(AR), WiFi(AR)
Test Result: Failed

Test index: 4
i) connect WiFi mobile phone with data usage disable: 
wifi_001cc1a25dff_757474656a536972_managed_none
State: Ready
Favorite: true
Connected first time: No
Data Usage: Disabled

Service order: Wifi(AR)

ii) Connect another USB device with data usage enable: 
ethernet_c66422b41680_cable
State: Online
Favorite: true
Connected first time: Yes
Data Usage: Enabled

Service order: USB(AO), WiFi(AR)
Test Result: Failed

Tested on: Connman version: 1.23

Best Regards,
PriyaranjanS



-Original Message-
From: connman [mailto:connman-boun...@connman.net] On Behalf Of Sven Schwedas
Sent: Thursday, January 29, 2015 6:16 PM
To: connman@connman.net
Subject: Re: Issue found in service connman ordering

On 2015-01-29 13:24, Priyaranjan Singh wrote:
> We are using Connman version: 1.23

1.27 is the last release, and the git master branch has a lot of additional 
fixes. You should re-test with either (and appropriately recent versions of 
wpa_supplicant et. al.) and report any still existing issues in a more readable 
format.

--
Mit freundlichen Grüßen, / Best Regards, Sven Schwedas Systemadministrator TAO 
Beratungs- und Management GmbH | Lendplatz 45 | A - 8020 Graz
Mail/XMPP: sven.schwe...@tao.at | +43 (0)680 301 7167 http://software.tao.at

This message contains information that may be privileged or confidential and is 
the property of the KPIT Technologies Ltd. It is intended only for the person 
to whom it is addressed. If you are not the intended recipient, you are not 
authorized to read, print, retain copy, disseminate, distribute, or use this 
message or any part thereof. If you receive this message in error, please 
notify the sender immediately and delete all copies of this message. KPIT 
Technologies Ltd. does not accept any liability for virus infected mails.
___
connman mailing list
connman@connman.net
https://lists.connman.net/mailman/listinfo/connman


Re: Issue found in service connman ordering

2015-01-29 Thread Sven Schwedas
On 2015-01-29 13:24, Priyaranjan Singh wrote:
> We are using Connman version: 1.23

1.27 is the last release, and the git master branch has a lot of
additional fixes. You should re-test with either (and appropriately
recent versions of wpa_supplicant et. al.) and report any still existing
issues in a more readable format.

-- 
Mit freundlichen Grüßen, / Best Regards,
Sven Schwedas
Systemadministrator
TAO Beratungs- und Management GmbH | Lendplatz 45 | A - 8020 Graz
Mail/XMPP: sven.schwe...@tao.at | +43 (0)680 301 7167
http://software.tao.at



signature.asc
Description: OpenPGP digital signature
___
connman mailing list
connman@connman.net
https://lists.connman.net/mailman/listinfo/connman

Issue found in service connman ordering

2015-01-29 Thread Priyaranjan Singh
Hello All,

We are using Connman version: 1.23

We executed couple of service ordering scenarios, looks to me some of them are 
not giving correct output.

Please clarify in case my understanding is wrong.

Please confirm the failures, incase known issue then which version of connman 
will have fix?

Test index

Test Steps

Service

State

Favorite

Serviceorder

Connected first time

Data

Result

1

Connect WiFi  mobile phone  (data usage on)

wifi_001cc1a25dff_757474656a536972_managed_none

Online

boolean true

Wifi(AO)

yes

Enabled

OK

Connect USB  device in tether mode (data usage on)

ethernet_020c1e7b6205_cable

Ready

boolean true

Wifi(AO)
USB(AR)

yes

Enabled



2

Disable data usage of connected WiFi mobile phone

wifi_001cc1a25dff_757474656a536972_managed_none

Ready

boolean true

Wifi(AR)

No

Disabled

NOK



ethernet_020c1e7b6205_cable

Online

boolean true

USB(AO)
Wifi(AR)

No

Enabled



3



wifi_001cc1a25dff_757474656a536972_managed_none

Ready

boolean true

Wifi(AR)

No

Disabled

NOK

Disable data usage of connected USB device

ethernet_020c1e7b6205_cable

Ready

boolean true

USB(AR)
Wifi(AR)

No

Disabled



4



wifi_001cc1a25dff_757474656a536972_managed_none

Ready

boolean true

Wifi(AR)

No

Disabled

NOK

Remove connected USB and connect new USB device with data usage enable

ethernet_c66422b41680_cable

Online

boolean true

USB(AO)
Wifi(AR)

yes

Enabled



5

1) Disconnect WiFi mobile phone
2) Disable data usage of connected USB device

ethernet_c66422b41680_cable

Ready

boolean true

USB(AR)

NO

Disabled

OK

1) Connect another USB device in tethering mode and data usage disable

ethernet_026406750174_cable

Ready

boolean true

USB(AR-USB connected first)
USB(AR-USB connected second)

yes

Disabled



6



ethernet_026406750174_cable

Ready

boolean true

USB(AR)

NO

Disabled

OK

Remove connected USB device and reconnect. (To verify Favorite attribute)

ethernet_c66422b41680_cable

Ready

boolean true

USB(AR-USB connected first)
USB(AR-USB connected second)

NO

Disabled



7



ethernet_026406750174_cable

Ready

boolean true

USB(AR)

NO

Disabled

OK

Enable data usage of the connected USB device

ethernet_020c1e7b6205_cable

Online

boolean true

USB(AO-USB connected second)
USB(AR)

NO

Enabled


Thanks.

Best Regards,
PriyaranjanS
This message contains information that may be privileged or confidential and is 
the property of the KPIT Technologies Ltd. It is intended only for the person 
to whom it is addressed. If you are not the intended recipient, you are not 
authorized to read, print, retain copy, disseminate, distribute, or use this 
message or any part thereof. If you receive this message in error, please 
notify the sender immediately and delete all copies of this message. KPIT 
Technologies Ltd. does not accept any liability for virus infected mails.
___
connman mailing list
connman@connman.net
https://lists.connman.net/mailman/listinfo/connman