DealMakerz

Complete British News World

Surfshark has developed a GUI VPN for Linux! – Linux and Unix

VPN companies haven’t messed up Linux with a graphical interface for their VPN solution. As far as I know, only Swedish OVPN and Mullvad provided a graphical interface for Linux users (there are probably a few that I don’t know of) most of whom need to use the device to handle. Those who like to take advantage of it don’t mind, but someone else who wants it smoothly, so to speak, appreciates companies that put a little love on Linux users. So these things are worth paying attention to :)

But now Surfshark, a reliable and stable VPN provider I’ve used for a long time along with OVPN (to be able to use iPlayer) has joined the crowd that puts some energy into Linux users.
It’s fast, it’s only marginally “slower” than OVPN. As most people know, the connection encryption makes it a little slower when downloading. Although I use OVPN Vilfo’s VPN router with OVPN’s VPN on the bottom, so to speak, I find around 390-420 Mbit/s on my 500 Mbit line, towards the nearest server in Stockholm. Against London, I get the same thing (measured with speedtest.net) but with a higher ping (34ms) which is remarkably fast considering I have a working VPN then : a
With surfshark’s browser extension it happens sometimes, not often but nevertheless, that it loses connection (Firefox), but I haven’t tested it yet with this app.
However, there seems to be at least one bug that I’ve noticed in debian-based MX-Linux. in another meaning. When I unplug the wave cannon, I have to stop and start the network connection for it to go and surf again. But it could be because of something kidding that, like I said, I’m running a dual VPN when I start Surfsharks as well.
You could add that it uses the new Wireguard protocol (which is faster) by default, but you can switch to OpenVPN if you want.

See also  How many land mammals are there in the world?

But anyway for those who are interested in using Surfshark’s VPN in Linux, here is a tip if you don’t want to stick with the device and run it..


Edited by Hackinger

// Wait for the 'consent limbo event document.addEventListener(self.plugin.event.limbo, function(e) { self.logEvent(); }); } },

// Shorthand function that will run callback function on granted consent onGranted : function (callbackFunction) {

// If promise is not set, run init() if (this.onGrantedPromise === null) this.init();

this.onGrantedPromise.then(function(isGranted) { if(isGranted) { callbackFunction(); } }); },

// Shorthand function that will run callback function on revoked consent onRevoked : function (callbackFunction) {

// If promise is not set, run init() if (this.onRevokedPromise === null) this.init();

this.onRevokedPromise.then(function(isGranted) { if(!isGranted) { callbackFunction(); } }); },

// This will run when either the granted or the revoked promises is resolved onGrantedOrRevoked : function(callbackFunction) {

// Run init() if promises are not set if (this.onGrantedPromise === null && this.onRevokedPromise === null) this.init();

Promise.race([this.onGrantedPromise, this.onRevokedPromise]).then(function(isGranted) { callbackFunction(isGranted); }); },

/** * Insert a pixel on consent = granted. * * @param pixel {object} | string | int. The pixel argument can be an object,string or int, containing at least the segment id. * If an object is supplied as argument, it should contain the props 'dc_seg' and 'dc_ui' {dc_ui: yyy, dc_seg: xxx} */ insertPixel : function(pixel) {

this.onGranted(function() {

pixel = (typeof pixel === 'number') ? pixel.toString() : pixel; pixel = (typeof pixel === 'string') ? {'dc_seg':pixel} : pixel;

// Check if segment ID exists if(typeof pixel.dc_seg !== 'undefined' || pixel.dc_seg !== '') {

// Default DFP network code is 8456 pixel.dc_ui = (typeof pixel.dc_ui === 'undefined' || pixel.dc_ui === '') ? '8456' : pixel.dc_ui;

// Remove 'DFPAudiencePixel' and all the '/', '?', ';' from the string pixel.dc_ui = pixel.dc_ui.replace('DFPAudiencePixel', ''); pixel.dc_ui = pixel.dc_ui.replace(/\//g, ''); pixel.dc_ui = pixel.dc_ui.replace(/\;/g, '');

pixel.dc_seg = pixel.dc_seg.replace(/\?/g, '');

// Insert a pixel in the body (src="https://pubads.g.doubleclick.net/activity;dc_iu=/{dfp-network-code}/DFPAudiencePixel;ord=1;dc_seg={segment_ID}?") var a = Math.floor(Math.random()*(9999999)); var pixelImg = document.createElement('img'); pixelImg.style="display:none;"; pixelImg.width = 1; pixelImg.height = 1; pixelImg.src="https://pubads.g.doubleclick.net/activity;dc_iu=/"+pixel.dc_ui+'/DFPAudiencePixel;ord='+a+';dc_seg='+pixel.dc_seg+'?'; document.body.appendChild(pixelImg); } else { console.log('IDG_CONSENT_CHECK: tracking pixel missing segment ID (dc_seg)'); }

}); },

/** * Insert a iframe on consent = granted. * * @param iframe {object} | string | int. The iframe argument can be an object or string, containing at least the iframe scr. * If an object is supplied as argument, it should contain the props 'src' and 'name' {src: yyy, name: xxx} */ insertIframe : function(iframe) {

this.onGranted(function() {

if(typeof iframe !== 'undefined' || iframe !== '') {

// If iframe only contains the scr as a string iframe = (typeof iframe === 'string') ? {'src':iframe} : iframe; iframe.name = (typeof iframe.name === 'undefined') ? 'tracking iframe' : iframe.name;

// Prepend //, if src is missing // iframe.src = (iframe.src.indexOf('//') === -1) ? '//' + iframe.src : iframe.src;

var iframeElement = document.createElement('iframe'); iframeElement.name = iframe.name; iframeElement.src = iframe.src; iframeElement.style="width:0;height0;display:none;"; document.body.appendChild(iframeElement);

} else { console.log('IDG_CONSENT_CHECK: tracking iframe is missing src-attribute'); }

}); },

/** * Insert a facebook pixel on consent = granted. * * @param pixelID string | int. The pixelID argument can be an string or int. (Example ID: 114844478880251) */ insertPixelFacebook : function(pixelID) {

// Wait for consent = granted this.onGranted(function() {

// Check if segment ID exists if(typeof pixelID !== 'undefined' || pixelID !== '') {

// If number pixelID = (typeof pixelID === 'number') ? pixelID.toString() : pixelID;

// Load the facebook pixel !function(f,b,e,v,n,t,s){if(f.fbq)return;n=f.fbq=function(){n.callMethod? n.callMethod.apply(n,arguments):n.queue.push(arguments)}; if(!f._fbq)f._fbq=n;n.push=n;n.loaded=!0;n.version='2.0'; n.queue=[];t=b.createElement(e);t.async=!0; t.src=v;s=b.getElementsByTagName(e)[0]; s.parentNode.insertBefore(t,s)}(window, document,'script', 'https://connect.facebook.net/en_US/fbevents.js'); fbq('init', pixelID); fbq('track', 'PageView'); } else { console.log('IDG_CONSENT_CHECK: Facebook pixel missing ID'); } }); },

/** * Insert a Linkedin pixel on consent = granted. * * @param partnerID string | int. The partnerID argument can be an string or int. (Example ID: 61326) */ insertPixelLinkedin : function(partnerID) {

// Wait for consent = granted this.onGranted(function() {

// Check if segment ID exists if(typeof partnerID !== 'undefined' || partnerID !== '') {

// If number partnerID = (typeof partnerID === 'number') ? partnerID.toString() : partnerID;

window._linkedin_data_partner_id = partnerID; (function(){ var s = document.getElementsByTagName("script")[0]; var b = document.createElement("script"); b.type = "text/javascript";b.async = true; b.src = "https://snap.licdn.com/li.lms-analytics/insight.min.js"; s.parentNode.insertBefore(b, s); })();

} else { console.log('IDG_CONSENT_CHECK: Linkedin pixel missing Partner ID'); } }); },

/** * Insert a comscore pixel on consent = granted. * * @param comscoreID string | int. The comscoreID argument can be an string or int. The default ID: 6035308, will be used if undefined or empty. */ insertPixelComscore : function(comscoreID) { // Wait for consent = granted this.onGranted(function() { // Set default ID comscoreID = (typeof comscoreID === 'undefined' || comscoreID === '') ? '6035308' : comscoreID; comscoreID = (typeof comscoreID === 'number') ? comscoreID.toString() : comscoreID; // Load the comscore pixel window._comscore=window._comscore||[]; _comscore.push({c1:"2",c2:comscoreID}),function() { var a=document.createElement("script"),b=document.getElementsByTagName("script")[0]; a.async=!0,a.src=("https:"==document.location.protocol?"https://sb":"http://b")+".scorecardresearch.com/beacon.js",b.parentNode.insertBefore(a,b) }(); }); },

}

// Run init function before the consent plugin has loaded to add all eventlistners IDG_CONSENT_CHECK.init();

// Load consent plugin script, append version number appendAsyncJSTag(IDG_CONSENT_CHECK.plugin_src + '?ver=" + IDG_CONSENT_CHECK.version);