USB HASP dongle
It was not so hard to set up usb dongle key to get access in linux... I use it for Microsip
Download
Device Drivers for USB HASP keys
http://www.aladdin.com/support/hasp/hasp4/linuxdrv.aspx
wget ftp://ftp.aladdin.com/pub/hasp/new_releases/linux/HDD_Linux_USB_daemon.tar.gz
NetHASP License Manager
http://www.aladdin.com/support/hasp/enduser.aspx
wget ftp://ftp.aladdin.com/pub/hasp/hl/linux/hasplm_linux_8.30.tgz
Untar de tarballs to /usr/sbin
Mount usbfs
mount -t usbfs none /proc/bus/usb
To connect to USB dongle run:
/usr/sbin/aksusbd
and it will create /tmp/.aksusb
To start service on UDP:475
/usr/sbin/hasplm
UPDATE: 24/Dic/2015
I've have issues regarding dongle disconnection
I had to desconect the power of the usb port and then connect again with:
There is a link on how to install microsip 2007 on linux using winehq
Unfortunatelly, laters version of microsip use HASP SRM Dongle, which is not yet suported according with Etersoft Support for HASP dongles in Wine
UPDATE: 7/March/2017
Driver update can be downloaded from Gemalto Downloads
License version 7.51 on release October/2016
Nagios monitoring configuration for hasplmd segfault:
Download
Device Drivers for USB HASP keys
http://www.aladdin.com/support/hasp/hasp4/linuxdrv.aspx
wget ftp://ftp.aladdin.com/pub/hasp/new_releases/linux/HDD_Linux_USB_daemon.tar.gz
NetHASP License Manager
http://www.aladdin.com/support/hasp/enduser.aspx
wget ftp://ftp.aladdin.com/pub/hasp/hl/linux/hasplm_linux_8.30.tgz
Untar de tarballs to /usr/sbin
Mount usbfs
mount -t usbfs none /proc/bus/usb
To connect to USB dongle run:
/usr/sbin/aksusbd
and it will create /tmp/.aksusb
To start service on UDP:475
/usr/sbin/hasplm
UPDATE: 24/Dic/2015
I've have issues regarding dongle disconnection
usb 1-3: usbfs: USBDEVFS_CONTROL failed cmd aksusbd rqt 192 rq 161 len 8 ret -71
I had to desconect the power of the usb port and then connect again with:
echo 0 > /sys/bus/usb/devices/1-3/authorized
echo 1 > /sys/bus/usb/devices/1-3/authorized
echo 1 > /sys/bus/usb/devices/1-3/authorized
After that, retart the aksusb daemon with
/etc/init.d/aksusbd restart
There is a link on how to install microsip 2007 on linux using winehq
Unfortunatelly, laters version of microsip use HASP SRM Dongle, which is not yet suported according with Etersoft Support for HASP dongles in Wine
UPDATE: 7/March/2017
Driver update can be downloaded from Gemalto Downloads
License version 7.51 on release October/2016
Nagios monitoring configuration for hasplmd segfault:
define service{
use generic-service
host_name localhost
service_description hasp_proc
check_command check_hasp
# Minutes to wait before next "regular" check.
normal_check_interval 2
# Minutes to wait before re-checking a non-OK service.
# A value of 1 = 60 seg, a value of 0.50 min = 30 seg
#retry_check_interval 1
retry_check_interval .25
# Number of times to retry a service check when a non-OK state is returned.
max_check_attempts 3
event_handler restart-aksusbd
}
define command{
command_name check_hasp
command_line /usr/lib/nagios/plugins/check_procs -c 1: -C hasplmd
}
define command{
command_name restart-aksusbd
command_line /usr/local/bin/aksusbd_eventhandler.sh "$SERVICESTATE$" "$SERVICESTATETYPE$" "$SERVICEATTEMPT$"
}
Add path to /etc/init.d/aksusbd
visudo
/usr/local/bin/aksusbd_eventhandler.sh

PATH=/sbin:/usr/sbin:/bin:/usr/bin
visudo
nagios ALL=NOPASSWD: /etc/init.d/aksusbd start
/usr/local/bin/aksusbd_eventhandler.sh
!/bin/sh
#
# Event handler script for restarting the web server on the local machine
#
# Note: This script will only restart the web server if the service is
# retried 3 times (in a "soft" state) or if the web service somehow
# manages to fall into a "hard" error state.
#
# What state is the AKSUSB service in?
LOG=/tmp/eventhandler.log
echo $UID >> $LOG
echo $(date) $@ >> $LOG
# kill -ABRT $(pidof hasplmd)
case "$1" in
OK)
# The service just came back up, so don't do anything...
;;
WARNING)
# We don't really care about warning states, since the service is probably still running...
;;
UNKNOWN)
# We don't know what might be causing an unknown error, so don't do anything...
;;
CRITICAL)
# Aha! The AKSUSB service appears to have a problem - perhaps we should restart the server...
# Is this a "soft" or a "hard" state?
case "$2" in
# We're in a "soft" state, meaning that Nagios is in the middle of retrying the
# check before it turns into a "hard" state and contacts get notified...
SOFT)
# What check attempt are we on? We don't want to restart the service on the first
# check, because it may just be a fluke!
case "$3" in
# Wait until the check has been tried 2 times before restarting the web server.
# If the check fails on the 4th time (after we restart the web server), the state
# type will turn to "hard" and contacts will be notified of the problem.
# Hopefully this will restart the web server successfully, so the 4th check will
# result in a "soft" recovery. If that happens no one gets notified because we
# fixed the problem!
2)
echo -n "Restarting AKSUSB service (3rd soft critical state)..."
# Call the init script to restart the AKSUSB services
#chmod o+w /sys/bus/usb/devices/1-3/authorized
#echo 0 > /sys/bus/usb/devices/1-3/authorized
#echo 1 > /sys/bus/usb/devices/1-3/authorized
sudo /etc/init.d/aksusbd start
;;
esac
;;
# The AKSUSB service somehow managed to turn into a hard error without getting fixed.
# It should have been restarted by the code above, but for some reason it didn't.
# Let's give it one last try, shall we?
# Note: Contacts have already been notified of a problem with the service at this
# point (unless you disabled notifications for this service)
HARD)
echo -n "Restarting HTTP service..."
# Call the init script to restart the HTTPD server
#chmod o+w /sys/bus/usb/devices/1-3/authorized
#echo 0 > /sys/bus/usb/devices/1-3/authorized
#echo 1 > /sys/bus/usb/devices/1-3/authorized
sudo /etc/init.d/aksusbd start
;;
esac
;;
esac
exit 0
