Network Management

Contributor I

Perl API & Airwave

I'm trying to get a Perl script using LWP to talk to Airwave for API access. I found a link to curl commands ( which works fine. However, when I try to use the Perl script, I'm consistently getting certificate verify failed error messages. I installed a third-party CA certificate on Airwave and verified the functionality via a browser. I have a similar certificate on our Clearpass box and the API is working fine there - no issues at all. I don't know if it has something to do with the certificates on Airwave or something in my Perl script, but the Perl is dead-simple, just making a GET call to the Airwave URL.


I did notice when setting up the certificate on the Airwave box I did not have an ssl.conf file at /etc/httpd/conf.d and it is specifically referenced in the documentation for setting up certificates (


Any assistance would be greatly appreciated.


Re: Perl API & Airwave

If no one else replies, you might try opening a support case.

Rob Gin
Senior QA Engineer - Network Services
Aruba Networks, a Hewlett Packard Enterprise Company
Contributor I

Re: Perl API & Airwave

Update: I've opened a case with Aruba Support and received little traction on the issue. I've done some more testing on my end and I believe the issue has to do with no CA bundle being installed on the Airwave server.


I run the following command:


openssl s_client -host <airwave server> -p 443

and I immediately receive an error num: 20 - unable to get local issuer certificate and the certificate chain that is returned by the server is the actual server certificate itself. I can run the same command directly on the Airwave server, pointing the host to localhost and I get the same results.


The forementioned link that details installing a third-party certificate does not reference an intermediate certificate nor is an SSL.conf file referenced in the Apache config on the box itself. I tried to manually configure an SSL.conf file but an Apache restart failed.


We're planning a firmware upgrade early next week - not sure if this will make a difference or not, but the code we're running is only weeks old.



Contributor I

Re: Perl API & Airwave

I finally got past the SSL certificate error (appears to be a bug on the Airware server) but now I'm stuck getting Perl and LWP to either A) pass the relevant cookie information to access the information or B) leverage LWP/WWW::Mechanize to login to Airwave and generate the cookie for me.


I found the curl information and was able to generate the cookie jar file just fine, but attempting to load that file within the Perl script doesn't seem to be passing the cookie in the header at all and I'm getting a 403 - Forbidden from the Airwave server. Has anybody had any luck using Perl to access Airwave APIs?

Search Airheads
Showing results for 
Search instead for 
Did you mean: