Group:  English: General ยป microsoft.public.windows.networking.wireless
Thread: WlanSetProfile...how to create an adhoc connection

DotNetBag
.NET Development Newsgroups

HTVi
TV Discussion Newsgroups

Our Hot Pick: Rising Antivirus 2006 - Certified by TUV & Checkmark! Get 10% discount by entering this coupon code: ONDISCOUNT10
Rising Antivirus 2006

WlanSetProfile...how to create an adhoc connection
"Arsalan Ahmad" <arsalan_ahmad[ at ]fornntp.com> 09.07.2007 07:58:27
Hi all,

I am trying to create an adhoc connection between two computers running
vista.

For this i am creating a custom profile and then tryint to set the profile
using WlanSetProfile() API. The xml is given below:

<?xml version="1.0" ?>
- <WLANProfile xmlns="http://www.microsoft.com/networking/WLAN/profile/v1">
<name>NetTest1-adhoc</name>
- <SSIDConfig>
- <SSID>
<name>NetTest1</name>
</SSID>
</SSIDConfig>
<connectionType>IBSS</connectionType>
- <MSM>
- <security>
- <sharedKey>
<protected>FALSE</protected>
<keyType>passPhrase</keyType>
<keyMaterial>0896745231</keyMaterial>
</sharedKey>
- <authEncryption>
<authentication>open</authentication>
<encryption>WEP</encryption>
</authEncryption>
</security>
</MSM>
</WLANProfile>

However, I am getting error with error code
WLAN_REASON_CODE_INVALID_PROFILE_SCHEMA.

Could any one please tell me what am I missing here?

I want to create a network with open or shared authentication and WEP
encryption.

Thanks,

Arsalan

Re: WlanSetProfile...how to create an adhoc connection
"Arsalan Ahmad" <arsalan_ahmad[ at ]fornntp.com> 09.07.2007 08:03:22
What I have observed that if i remove sharedKey and change encryption from
WEP to none then the function returns successfully.


"Arsalan Ahmad" <arsalan_ahmad[ at ]fornntp.com> wrote in message
news:A5535CED-DEAF-4007-A7DF-C8CC9E93A0FC[ at ]microsoft.com...
[Quoted Text]
> Hi all,
>
> I am trying to create an adhoc connection between two computers running
> vista.
>
> For this i am creating a custom profile and then tryint to set the profile
> using WlanSetProfile() API. The xml is given below:
>
> <?xml version="1.0" ?>
> - <WLANProfile
> xmlns="http://www.microsoft.com/networking/WLAN/profile/v1">
> <name>NetTest1-adhoc</name>
> - <SSIDConfig>
> - <SSID>
> <name>NetTest1</name>
> </SSID>
> </SSIDConfig>
> <connectionType>IBSS</connectionType>
> - <MSM>
> - <security>
> - <sharedKey>
> <protected>FALSE</protected>
> <keyType>passPhrase</keyType>
> <keyMaterial>0896745231</keyMaterial>
> </sharedKey>
> - <authEncryption>
> <authentication>open</authentication>
> <encryption>WEP</encryption>
> </authEncryption>
> </security>
> </MSM>
> </WLANProfile>
>
> However, I am getting error with error code
> WLAN_REASON_CODE_INVALID_PROFILE_SCHEMA.
>
> Could any one please tell me what am I missing here?
>
> I want to create a network with open or shared authentication and WEP
> encryption.
>
> Thanks,
>
> Arsalan

Home | Search | Terms | Imprint | Contact
Newsgroups Reader - provided by WiredBox.Net