Jump to content

auto-run bug with fix


Recommended Posts

I've found another bug with the auto run scripts. When I moved the log file from /karma to /tmp I missed one reference to it in /karma/bin/logwatch . There is a line that starts

time_ssid=

In the middle it references status.log, the file should be /tmp/status.log.

I also found another possible bug in here, if Jasager has been restarted since a client connected the time_ssid line won't find any reference to the association in the log file so the ssid field will be blank. This causes problems because it is supposed to be the second parameter passed to the scripts, as it is blank all the other parameters move down one position and the IP address becomes the second parameter rather than the third. To fix this add the following lines under the ssid= line

if [[ "$ssid" == "" ]]
then
  ssid="Unknown"
fi

This isn't the best fix as it sets the ssid as "Unknown" which means we can't tell if that is what the user was probing for of if it is the result of this bug. I'll have a think about a better fix.

A combination of these problems could have caused the issues some people have seen with the auto port scan complaining about not getting an IP address, it is getting one, just in the wrong place in the argument list.

I've got another couple of issues to look at and when I get them sorted I'll put up a new version or give a list of files upgrade for people who don't want to do a full upgrade.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...