Cisco VPN client on Ubuntu 16.04 LTS - vpn

I am trying to install Cisco VPN Client on Ubuntu, but I am facing problems.
So How can I install it on Ubuntu 16.04 LTS ?

Run
sudo apt-get install network-manager-vpnc network-manager-vpnc-gnome
Then open network manager and add a new VPN, it should show Cisco Compatible VPN in your list now.

I was using the Cisco AnyConnect Client for Linux during the last months, which was in general working, but had a few major bugs.
Most important: whenever you disconnected (also by just switching to another network), you would have to completely restart the computer to make the VPN work again.
I now switched to the open source client called OpenConnect, which is compatible with Cisco's AnyConnect SSL VPN but just works a lot more reliable. To install and enable the VPN, have a look at this: https://people.eng.unimelb.edu.au/lucasjb/oc.html
Edit: just saw that OpenConnect was already proposed in a comment. Leave this answer here as it provides some additional information and a step-by-step manual

OpenConnect offers an opensource command line alternative to Cisco's GUI:
echo "password" | sudo openconnect server --user=username --passwd-on-stdin
See here for more details/source I blatantly stole this answer from: https://askubuntu.com/questions/1043024/how-to-run-openconnect-with-username-and-password-in-a-line-in-the-terminal
Install info here: http://ubuntuhandbook.org/index.php/2014/11/connect-cisco-anyconnect-vpn-ubuntu/
First run command below to active the TUN module (I didn't need this in Ubuntu 18.04.3 LTS):
sudo /sbin/modprobe tun
Install OpenConnect:
sudo apt-get install openconnect
Run command above or:
sudo openconnect SERVERADDR

Related

Amazon linux install openvpn3-client

Trying to install openvpn3-client on my amazon Linux followed this documentation, facing below error
Packages skipped because of dependency problems:
openvpn3-13-0.beta1.el7.x86_64 from copr:copr.fedorainfracloud.org:dsommers:openvpn3
openvpn3-client-13-0.beta1.el7.x86_64 from copr:copr.fedorainfracloud.org:dsommers:openvpn3
openvpn3-selinux-13-0.beta1.el7.noarch from copr:copr.fedorainfracloud.org:dsommers:openvpn3
python36-dbus-1.2.4-4.el7.x86_64 from epel
python36-gobject-base-3.22.0-6.el7.x86_64 from epel
I have already installed epel following this
Amazon linux install openvpn3-client & dependencies as per
https://github.com/OpenVPN/openvpn3-linux
See the instructions on
https://community.openvpn.net/openvpn/wiki/OpenVPN3Linux how to
install pre-built OpenVPN 3 Linux packages on Debian, Ubuntu, Fedora,
Red Hat Enterprise Linux, CentOS and Scientific Linux.
1 solution was to switch from AWS Linux (lack of dependencies & updates) to Fedora on AWS. No longer have to build from source / add dependancices,
older versions had to add the repo as per the above.
When I did an upgrade to Fedora 36 the latest openvpn3-linux v18 client was built in. Did not have to manually upgrade / install it:
openvpn3-admin version --services
e.g: previous v17 suddenly stopped working spend 10 hours trying to debug
"Trying to install openvpn3-client" and reinstall:
openvpn3 config-import --config profile.udp.ovpn --persistent
openvpn3 config-manage --config profile.udp.ovpn --enable-legacy-algorithms true --show
openvpn3 session-start --config profile.udp.ovpn
openvpn3 sessions-list
openvpn3 session-manage --config profile.udp.ovpn --disconnect
Actually thinking it was a cipher AES-256-CBC legacy issue that others were having. It was not for some reason, permissions on install of the OpenVPN3 Linux client? as it was NOT creating a TUN.
So I made one myself (that was the actual issue) and it connected after asking for VPN Username & Password, no need to install again / reinstall afterall:
sudo ip tuntap add name tun0 mode tun
sudo ip link show
Other Amazon linux install openvpn3-client issues help is here: https://github.com/OpenVPN/openvpn3-linux/issues?q=cipher

QUIC traffic generation

I wanted to know if anyone in this community know/found a way to simulate QUIC traffic profile. For analyzing/simulating youtube over WLAN (WiFi), i wanted to know if there is a convenient package like iperf out there.
Thanks
Bharat C P
At the moment there are not any simulation frameworks that can be used to test QUIC traffic.
However there is a remarkable effort in order to provide stand alone implementations with the aim of testing and analyzing QUIC.
I cite just some references you might want to use to this purpose:
Official Google Guide which contains a sample server and client implementation in Chromium.
libquic a library extracted from Chromium's QUIC Implementation
quic-go is an implementation of the QUIC protocol in Go.
I was able to generate QUIC traffic using aioquic. I'm using KDE Neon, which is an Ubuntu derivative.
git clone https://github.com/aiortc/aioquic.git
sudo apt install libssl-dev python3-dev
virtualenv venv1
source venv1/bin/activate
cd aioquic/
pip install -e .
pip install asgiref dnslib httpbin starlette "werkzeug<2.1" wsproto
Then, in one terminal, run the server:
python examples/http3_server.py --certificate tests/ssl_cert.pem --private-key tests/ssl_key.pem
And in another, make an http3 request with the client:
python examples/http3_client.py --ca-certs tests/pycacert.pem https://localhost:4433/
Done.
You can see the traffic in Wireshark. The version that worked for me was 3.6.5. Note that you would need to sniff the loopback interface (Loopback: lo).
Here's how to install Wireshark 3.6.5:
sudo add-apt-repository ppa:wireshark-dev/stable
(need to press enter)
sudo apt update
sudo apt install wireshark

Cloudstack 4.6.0 system vm are stuck in Starting state

I just finished CloudStack 4.6.0 installation in CentOS 7 and system vms are not able to start, they are stuck in the Staring state. Hipervisor is KVM. I did download the system vm template by this:
/usr/share/cloudstack-common/scripts/storage/secondary/cloud-install-sys-tmplt -m /secondary -u http://cloudstack.apt-get.eu/systemvm/4.6/systemvm64template-4.6.0-kvm.qcow2.bz2 -h kvm -F
Please let me know what other information to provide. Thank you
been through this error and I can understand the stress :)
Just run the following command
sudo yum upgrade
And then restart cloudstack management server.
Hope this helps.

Arduino Tools > Serial Port greyed out

I am running Debian 7 (Linux Crunchbang) and wanted to use The Arduino IDE to program my Arduino UNO. To do that I installed the package arduino. When I started the Arduino I was asked to add my user to the dialout group. So I did with sudo usermod -a -G dialout <my-username>.
However when I start the Arduino IDE using arduino in the commandline the IDE opens but I am not able to load my program to the Arduino. The error message is "Serial port COM1 not found. Did you select the right one from the Tools > Serial Port menu?" And when I went to select the Serial Port, the option "Tools > Serial Port" is greyed out.
I thought it is because I did not grant read and write permissions on my usb port (ttyACM0). So I did sudo chmod a+rw /dev/ttyACM0 but the option is still greyed out.
chdmod works for my under debian (proxmox):
# chmod a+rw /dev/ttyACM0
For installing arduino IDE:
# apt-get install arduino arduino-core arduino-mk
Add the user to dialout group:
# gpasswd -a user dialout
Restart Linux.
Try with the File > Examples > 01.Basic > Blink, change the 2 delays to delay(60) and click the upload button for testing on arduino, led must blink faster. ;)
sudo arduino is the only way I get the Arduino IDE working (serial port and upload) on ubuntu 12.04 (64)
Indeed the serial port to use is /dev/ttyACM0 in my case too.
The other two (ttyS4 and ttyS0) gave an error when trying to upload to Uno.
Have fun
Try Disconnecting the usb and plugging it back in. Its only grayed out because the ide cannot find any com ports that the uno has been plugged into.
another solution is to try all the com ports and see which one works.
finally if all fails try restarting your computer.
Close all instances of the arduino IDE
open ~/.arduino/preferences.txt and look for the line:
serial.port=<not your port>
and change it to your port:
serial.port=/dev/ttyACM0
you may have to log out for it to take effect
open $arduinoHome/arduino in text editor and modify last string:
java -Dswing.defaultlaf=com.sun.java.swing.plaf.gtk.GTKLookAndFeel processing.app.Base "$#"
to
java -Dswing.defaultlaf=com.sun.java.swing.plaf.gtk.GTKLookAndFeel -Dgnu.io.rxtx.SerialPorts="/dev/ttyACMN" processing.app.Base "$#"
(set property gnu.io.rxtx.SerialPorts to /dev/ttyACMN,where ttyACMN is name of serial port which you use)
it may temporary fix bug in rxtx library. helped me to upload sketch with arduino1.0.5 IDE.
Maybe would helpful for someone.
In my case this turned out to be a bad USB hub.
The 'lsusb' command can be used to display all recognized devices. If the unit is not plugged in the option to set the speed will be disabled.
The lsusb command should output something like the string 'Future Technology Devices International, Ltd Bridge(I2C/SPI/UART/FIFO)' if your device is recognized. Mine was an RFDuino
In my case I solved this issue by uninstalling the version of Arduino that I installed via apt-get and instead installed via the official website.
With the latest version of Arduino I didn't have the problem described on Ubuntu 18.04.
So I did with sudo usermod -a -G dialout <my-username>.
You need to log out after you add yourself to a group so those changes are applied. Just log out and log in again and the menu should be available.
install rx-tx lib for java run this command in terminal
sudo apt-get install librxtx-java -y
output port
sudo usermod -aG dialout $USER
sudo apt-get install gnome-system-tools
help regconize usb device
I solved following serial port related problems in ubuntu 18.04 as follows:
Problem 1 : Cannot open /dev/ttyACM0: Permission denied
Solution : Grant permissions to read/write to the serial port with this terminal command ---> sudo chmod a+rw /dev/ttyACM0
Here replace tty port with your respective ubuntu port.
Problem 2 : Failed to open /dev/ttyACM0 (port busy)
Solution : This problem appears when serial port is busy or already occupied. So kill the busy serial port with command ---> fuser -k /dev/ttyACM0. Here replace tty port with your respective ubuntu port.
Problem 3 : Board at /dev/ttyACM0 is not available
Solution : In this case your serial port in tools menu will be greyed out. I googled a lot for this, but I none of solution worked for me. Atlast I tried different arduino board and usb connector and it was working for me. So, if you are having old arduino board (can be solved using required drivers) or defected arduino board then only this problem arises.
If it is helpful to anyone, I had this problem using Ubuntu 22.04. The issue stemmed from:
apparmor (apparmor denied error, logging with dmesg)
brltty (ch34x converter now disconnected from ttyUSB0)
Solved it by removing both:
https://www.simplified.guide/ubuntu/remove-apparmor
sudo apt remove brltty
You can disable apparmor and it should work, however this made applications like firefox useless. My recomendation would be to totally remove it
Same comment as Philip Kirkbride.
It wasn't a permission issue, but using the Arduino IDE downloaded from their website solved my problem.
Thanks!
Michael
The following steps install the IDE and remove the error java.lang.NullPointerException thrown while loading gnu.io.RXTXCommDriver which usually comes with arduino installed with apt-get command in Ubuntu.
Install the IDE
sudo apt-get install arduino
for removing java error in IDE
sudo add-apt-repository ppa:webupd8team/java
sudo apt update
sudo apt install oracle-java8-set-default
This also shows the Serial Port which was grayed out due to the error.
I had the same problem, with which I struggled for few days, reading all the blog posts, watching videos and finally after i changed my uno board, it worked perfectly well. But before I did that, there were a few things I tried, which I think also had an effect.
Extracted the files to opt folder, change the preference --> behavior --> executable text files --> ask what to do. After that, double clicked arduino on the folder, selected run by terminal
added user dialout like described in other answers.
Hope this answer helps you.
For a Windows solution I've found that disabling and re-enabling the Arduino in Device Manager, then restarting the Arduino IDE does the trick without fail (no unplugging necessary). Why this error occurs in the first place is beyond me. Perhaps the corresponding method for Linux will fix your problem.
Slightly related (not really), I had an issue with an AVR board a while back which was fixed by setting the device to a new COM port in the driver settings. Again, however you linux bunnies do it, I'm sure it'll be cookies and cream.
Cheers brother,
I encountered the same issue. My solution was to install and use java7:
sudo apt-get install openjdk-7-jre
sudo update-alternatives --config java
Select the number referring to the java-7 path.
You probably don't have the correct permissions. Try adding yourself to these groups.
sudo adduser username ttyl
sudo adduser username serial
sudo adduser username uucp
Then restart your system and check if you got added to the groups.
groups username
Good Luck!
Try to run as an administrator...
Run terminal, type sudo arduino, type your root password, and... :)

Why doesn't wireshark detect my interface?

I just installed Wireshark, but when I click capture > interfaces, the dialog box appears, but it does not contain my network interface.
When click on capture > interfaces it appears as in the screenshot below. What can cause this?
This is usually caused by incorrectly setting up permissions related to running Wireshark correctly. While you can avoid this issue by running Wireshark with elevated privileges (e.g. with sudo), it should generally be avoided (see here, specifically here). This sometimes results from an incomplete or partially successful installation of Wireshark. Since you are running Ubuntu, this can be resolved by following the instructions given in this answer on the Wireshark Q&A site. In summary, after installing Wireshark, execute the following commands:
sudo dpkg-reconfigure wireshark-common
sudo usermod -a -G wireshark $USER
Then log out and log back in (or reboot), and Wireshark should work correctly without needing additional privileges. Finally, if the problem is still not resolved, it may be that dumpcap was not correctly configured, or there is something else preventing it from operating correctly. In this case, you can set the setuid bit for dumpcap so that it always runs as root.
sudo chmod 4711 `which dumpcap`
One some distros you might get the following error when you execute the command above:
chmod: missing operand after ‘4711’
Try 'chmod --help' for more information.
In this case try running
sudo chmod 4711 `sudo which dumpcap`
In Windows, with Wireshark 2.0.4, running as Administrator did not solve this for me. What did was restarting the NetGroup Packet Filter Driver (npf) service:
Open a Command Prompt with administrative privileges.
Execute the command sc query npf and verify if the service is running.
Execute the command sc stop npf followed by the command sc start npf.
Open WireShark and press F5.
Source: http://dynamic-datacenter.be/?p=1279
For *nix OSes, run wireshark with sudo privileges. You need to be superuser in order to be able to view interfaces. Just like running tcpdump -D vs sudo tcpdump -D, the first one won't show any of the interfaces, won't compalain/prompt for sudo privileges either.
So, from terminal, run:
$ sudo wireshark
As described in other answer, it's usually caused by incorrectly setting up permissions related to running Wireshark correctly.
Windows machines:
Run Wireshark as administrator.
By Restarting NPF, I can see the interfaces with wireshark 1.6.5
Open a Command Prompt with administrative privileges.
Execute the command "sc stop npf".
Then start npf by command "sc start npf".
Open WireShark.
That's it.
On Fedora 29 with Wireshark 3.0.0 only adding a user to the wireshark group is required:
sudo usermod -a -G wireshark $USER
Then log out and log back in (or reboot), and Wireshark should work correctly.
I hit the same problem on my laptop(win 10) with Wireshark(version 3.2.0), and I tried all the above solutions but unfortunately don't help.
So,
I uninstall the Wireshark bluntly and reinstall it.
After that, this problem solved.
Putting the solution here, and wish it may help someone......
Just uninstall NPCAP and install wpcap. This will fix the issue.

Resources