Thursday, 14 June 2012

1984 is here



(Shamelessly stolen from the BBC News website to comment on it)

Details of internet use in the UK will have to be stored for a year to allow police and intelligence services to access it, under government plans.
Records will include people's activity on social network sites, webmail, internet phone calls and online gaming.
Home Secretary Theresa May said the change was needed to keep up with how criminals were using new technology.
But senior Tory David Davis said it was "incredibly intrusive" and would only "catch the innocent and incompetent". (At last a politician with a bit of sense)
The Communications Bill is to be published in draft form on Thursday - but the government faces a battle to get it through Parliament intact, with Lib Dem MPs and Conservatives such as Mr Davis calling for it to be watered down or abandoned altogether.
Local authorities are likely to be stripped of their current powers to access phone call data in an effort to win over critics but the proposals have still been branded a "snooper's charter" by civil liberties campaigners.
Rachel Robinson, policy officer for Liberty, said: "It's good that local councils won't be able to watch the entire population but even law enforcement should be targeting suspects - not all citizens.
"Just like the internet, any private home can be a crime scene, but should we install hidden cameras and microphones in every bedroom in the land?"
'Stopping terrorists' (Bullshit.....)
Under current legislation, communications companies must keep phone records and information about messages sent via their own email services for 12 months.
The new proposals would require UK communications companies to keep details of a much wider range of data including use of social network sites, webmail, voice calls over the internet, and gaming. Websites visited could be recorded, although pages within sites would not be. (yeah and my name is Boris Yeltsin and I can fly like superman)
Mrs May told BBC Breakfast: "It's not about the content, it's not about reading people's emails or listening to their telephone calls. (YES IT IS, We aren't all morons you know)
"This is purely about the who, when and where made these communications and it's about ensuring we catch criminals and stop terrorists." (What a load of tosh...... so all they will be gathering is who they talked to when they talked to and where they talked to.... all of which they will need to view the entire communication to get that information)
The police and security services are concerned that criminals and terrorists are increasingly evading detection by using social media and online gaming sites to communicate with each other.
Officers would still need to obtain a warrant to gain access to the content of the online communication.
But the government would be able to request any service provider to keep data about internet usage, although initially it will involve about a dozen firms including BT, Virgin and Sky.
'Total war'
The previous government was forced to abandon plans to store every citizen's internet data on a single, giant database following protests - and Mrs May says she has no plan to resurrect this idea.The proposals will be subject to scrutiny by a joint parliamentary committee before the legislative process begins in earnest. (lets hope it falls at the first fence)
Metropolitan Police commissioner Bernard Hogan-Howe, writing in the Times, said having greater powers to access data was essential in waging a "total war on crime" - and he warned that police risked losing the fight against crime unless MPs passed a law enabling them to collect more communications data. (So I guess the data protection act doesn't apply should this go through ?)
He wrote: "Put simply, the police need access to this information to keep up with the criminals who bring so much harm to victims and our society." 
Tory backbencher David Davis, a former shadow home secretary who fought a by-election in the last Parliament on the issue of civil liberties, described the proposals as "incredibly intrusive".
He said the ban on local authority officials accessing data was "important but minor".
He told BBC Radio 4's Today programme: "If they really want to do things like this - and we all accept they use data to catch criminals - get a warrant. Get a judge to sign a warrant, not the guy at the next desk, not somebody else in the same organisation.
"The only people who will avoid this are the actual criminals, because there are ways around this - you use an internet cafe, you hack into somebody's wi-fi, you use what's called proxy servers, and they are just the easy ways."



http://www.bbc.co.uk/news/uk-politics-18434112

Thursday, 31 May 2012

How amazing is this ?

As most of you know my wife Andrea is a keen runner, she's done quite a few marathons since she started three years ago or so.... and I'm very proud of her achievements.... but her latest run has knocked the rest of her "marathons" into a cocked hat

She recently completed the Cardiff 50 Ultra... which as you will have guessed by now is a 50 mile ultra marathon basically running from Brecon to Cardiff along the Taff Trail, she came 96th out of 131... so far from last 


96 14 ANDREA BRABROOK F 01:31:03 03:35:47 05:41:47 08:22:47 10:56:12



in a very respectable 10 hours and 56 Minutes or to put it another way 12th overall female competing out of a field of 22 females ..... (she also beat 19 male participants).... 

which is no mean feat when you consider that her training for the event amounted to practically nothing.... there are not many people that can get up in the morning and run 50 miles before tea time......

Immensely proud of her :)




Tuesday, 22 May 2012

OpenSSH and Proxy drilling

For those you behind a very restrictive firewall where the only ports open to you are the local proxy port, port 80 and the SSL port 443... there is a way to drill a hole through and access your network/PC at home....

I won't go deeply into details of how to get the packages I'll leave that to you, if you can't use the apt-get install or synaptic yet.... then you probably shouldn't be even contemplating this......

This walk through is aimed at linux users .....


For the server side (your home PC) 

1. An OpenSSH server on your Linux box where the default port listening port of 22 has been changed to port 443....

sudo apt-get install openssh-server


once installed open up a nano/gedit session and load the following which can be found in /etc/.ssh/sshd_config

look down the config file until you see Port 22 and replace with Port 443 (there is nothing to stop you keeping both ports open if you so desire, but remember the more ports you have open especially default ports the more vulnerable you are)

# What ports, IPs and protocols we listen for
Port 443

save the file

restart your SSH server (reboot if you don't know how to restart it) to pick up the new listening port, then check you can SSH into your SSH server locally on that port.......

If all goes well and it should you then need to configure your router for port forwarding on port 443 to your internal IP address (obviously you will have to manually configure your PC's IP address and not use DHCP on your local LAN so it remains constant ), obviously this is router dependant and beyond the scope of this walk through....

That's it for your OpenSSH server side.

For your client side you will need to install 

Corkscrew 


once installed you will need to configure it and that can me done with the ~/.ssh/config file ......here is an example of a typical corkscrew configuration in the ssh config file, it's actually my config file but with personal stuff changed

(find/create that in ~/.ssh/  .... it's simply called "config" ) 


## Inside the firewall, with HTTPS proxy
Host home
hostname homepc.dyndns-at-home.com
ProxyCommand /usr/bin/corkscrew XXX.XXX.XXX.XXX 8080 %h 443 ~/.ssh/pass
ControlMaster auto
ControlPath ~/.ssh/master-%r@%h:%p
ServerAliveInterval 30

XXX.XXX.XXX.XXX can be either a hostname or the IP address of the proxy server (at work)

The %h parameter replaces itself with your hostname or alias in this case "home" and lastly the ~/.ssh/passs simply parses the password file to the proxy server. Otherwise you will get Error 407 proxy Authentication required......


Obviously you need to replace "homepc.dyndns-at-home.com" with your own hostname (or IP address if it's a fixed IP address)  and if your proxy at work requires a password then you will need to create a separate password file (called pass or whatever) in the ~/.ssh directory in the format of username:password.... the first line in the config file is simply an alias for the full hostname you enter.

once that is done all you have to do to connect to your home PC is to drop to a terminal prompt and type the following

ssh username@home 

and corkscrew will do the rest for you... if all goes well you should be prompted to accept the keys from your home server and then be presented with a shell prompt.

If you want to use remote desktop such as Remmina, you will have to configure your home server to accept remote desktop requests and to NOT prompt you to accept (otherwise you'll be waiting all day)... you will also have to do some port mapping with SSH ... fortunately that is quite easy.... by entering the following you will be able to see your remote desktop at work   

ssh -C -c blowfish-cbc -L 5900:127.0.0.1:5900 username@home (<-- @home picked up from ~/.ssh/config file)

(obviously put your own usual username in front of the @home)

all this line of gibberish does is :-

invoke ssh -C (with compression) -c blowfish (encryption type) -L (maps port 5900 on your remote PC to port 5900 on 127.0.0.1 on your local machine) 5900:127.0.0.1:5900 username@home (invokes the corkscrew script and reads the config file in ~/.ssh 

All being well should drop you back to a shell prompt on your remote PC with everything remapped and ready to go.

Fire up Remmina (or A.N.Other VNC client) and point it to 127.0.0.1 (not localhost !!) on your PC at work and it should prompt you for your password which you will have previously set on your remote PC (you did do that right ?) 


Caveat lector ..... there are a few most of which are easily solvable please feel free to leave a question and I'll do my best to answer it for you :)