Thanks so much for your reply!

Your advice makes sense, but it doesn't return a list of the Network 
ESSID's it only returns a number. Is there a more secure way i can do this. 
I know the application running on the raspberry pi is trying to access this 
information as a "www-data". how would i give temporal access to sudo. 
Security is a bid issue with this app.

Thanks again!

Cheers
Tolu

On Saturday, May 11, 2013 10:10:29 AM UTC-5, Massimo Di Pierro wrote:
>
> You can do 
>
> import os
> os.system('sudo iwlist wlan0 |"ESSID" > output.txt')
> output = open('output.txt').read()
>
> assuming the user running the web app has sudo access to iwlist. Look into 
> sudoers to add the permission.
>
> On Friday, 10 May 2013 16:35:12 UTC-5, si...@ymail.com wrote:
>>
>> Hello,
>>
>> Please i need some help and guaidiance.
>>
>> I have a web2py application running on a raspebery pi. The raspberry pi 
>> runs "Linux  3.6.11+ #371 PREEMPT Thu Feb 7 16:31:35 GMT 2013 armv6l 
>> GNU/Linux"
>>
>> I am trying to run this Linux command from a web2py controller..... "sudo 
>> iwlist wlan0 |"ESSID""
>>
>> This is supposed to bring up a list of all the available wifi networks in 
>> the area.
>>
>> How do i go about this
>>
>> Any help will be appreciated
>>
>> Cheers
>> Tolu
>>
>

-- 

--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to