title: Can't use an undefined value as a symbol reference
body: <p>I'm trying to use an API for a Palo Alto Networks software. The code is supposed to submit username and ipaddress of user network logins to a web interface.</p>
  
  <p>When I try using PANs' API with their sample code for a windows machine the following exception is thrown:</p>
  
  <pre><code>Can't use an undefined value as a symbol reference at
  C:/Perl/lib/PAN/API.pm line 179 (#1)
  
  PAN::API::UID::login('PAN::API::UID=HASH(0x7fd113828598)', 'SCU-DSM22/pmmertens', 172.16.6.117) called at API_events.pl line 12
  </code></pre>
  
  <p>This is the code-example that comes with the API documentation:</p>
  
  <pre><code>#!/usr/bin/perl -w
  
  use strict;
  use PAN::API;
  
  my     $useridagent    = '10.0.0.99'; #I changed this to our PAN server address
  
  my     $useridapi      = PAN::API::UID-&gt;new($useridagent);
  
  my     $user           = $ENV{USERDOMAIN}.'/'.$ENV{USERNAME};
  my     $ipaddress      = unpack('W4',gethostbyname($ENV{COMPUTERNAME}));
  
      $useridapi-&gt;login($user,$ipaddress);
  </code></pre>
  
  <p>I've ensure that all variables are retrieved correctly. Substituting literal values did not help either. Googling this error turned up references about hard and soft references but I don't see any infractions of these rules in the code below.</p>
  
  <p>This is the codeblock from PAN/Api.pm. Line 179 is where the print starts.</p>
  
  <pre><code>sub submit () {
      my  $self               = shift;
  
      use IO::Socket::INET;
      use IO::Socket::SSL;
  
      my  $socket             = IO::Socket::INET-&gt;new(PeerAddr =&gt; $self-&gt;{server},
                                                  PeerPort =&gt; $self-&gt;{port},
                                                  Proto    =&gt; 'tcp');
  
      my  $socketssl          = IO::Socket::SSL-&gt;start_SSL(   $socket,
                                                      SSL_version     =&gt;'TLSv1');
      print   $socketssl $self-&gt;xml;
              $socketssl-&gt;close;
              $socketssl-&gt;stop_SSL;
  }
  </code></pre>