Protect Windows with Virtualbox, pfsense, ipcop, ipfire and t1n1wall

This is a precursor of possible a long post about configuring a software firewall using virtualbox together with an open source firewall distribution such as ipcop, pfsense and t1n1wall (one of the successors of m0n0wall).

I will jot down the most important elements here and these are the results of hours of tests on various combination of configurations.

My network settings

  1. One external IP address directly connected to the outside world.
  2. One physical network card.
  3. MS Loopback network card (installed under Windows to function as the Bridged Network interface).

Network properties in the host machine

Instead of keeping just the Bridge Protocal of vmware and Bridged Networking Driver of virtualbox, I ticked another two additional protocols:

  1. Link-layer Topology Discovery Mapper I/O Driver
  2. Link-layer Topology Discovery Responder

In particular, Link-layer Topology Discovery Responder is essential for connecting to the wireless network. When it is unticked, the WAN interface under ipcop or pfsense finds it very difficult to connect to the wireless router. As a result, the network property for the physical network interface on the Windows host machine looks as follows:

Keep both the bridge protocols and the Link-layer protocols in the host machine
Keep both the bridge protocols and the Link-layer protocols in the host machine

Network configuration under virtualbox

  1. The most important thing is the network configuration under virtualbox. Both the adapter 1 and adapter2 need to be attached to Bridged Adapter (see attached pictures).
  2. I did limited tests and it appeared that selecting the Host-only adapter can also work, since there is a virtualbox bridged network driver ticked for “VirtualBox Host-Only Network”. However, if I choose Host-Only network for adapter2, t1n1wall cannot forward traffic from the host Windows machine to the outside world. For t1n1wall, and maybe other BSD flavored firewalls, it is better to set the adapter2 as bridged — although I assume making adapter2 the Host-Only network will make the host machine safer.
  3. I also installed Debian+arnos iptables firewall in virtualbox, and the adapter2 can be Host-Only or Bridged, both will work. In arno’s iptables firewall, just enable NAT and the host Windows machine will be able to visit the outside world.
  4. To easily identify which NIC is designated to WAN or LAN, click on Advanced and manually edit the automatically generated MAC address to something you can identify. I change the last two digits of the WAN MAC address into something like 080027276FAA and the last two digits of the LAN MAC address into something like 080027698CBB.
virtualbox.adapter1
virtualbox network configuration for ipcop, pfsense adapter1
virtualbox.adapter2
virtualbox network configuration for ipcop, pfsense adapter2. For adapter2, selecting host-only network should also work, but I am not so sure if portforwarding will be affected or not.

Do you need to setup VLAN under t1n1 and pfsense?

No. If you use bridged network, there is no need to setup VLAN.

If you choose to attach the network adapter to Internal Network, you may need to setup VLAN for the LAN to access the Internet, however, I didn’t test it. I am not so sure if you can even choose Internal Network when you want the host Windows machine to access the Internet.

Pfsense

I experienced several problems with pfsense and I don’t recommend using it with virtualbox and vmware if your sole purpose is using a firewall to protect your Windows PC with a firewall.

  1. Time drifts under vmware. pfsense experienced serious time drifts under vmware workstation 9.0. I simply can’t get the accurate time for pfsense under vmware. There is no time-drifting problems for virtualbox and pfsense.
  2. Port forwarding does not work. after numerous attempts, I still can’t reliably forward the ports to bittorrent clients running on the Windows host machine. I setup both NAT and firewall rules, and set the log to record the hits of the rules, however, it either turns up a few hits or no hits at all — even though the bittorrent client is working heavily with multiple downloads. Port forwarding works well under t1n1wall and ipcop, and the firewall log shows up the hit records with no problems.
  3. Overkill for the purpose. I run a single Windows PC as a host and I don’t need all the bells and whistles of pfsense, which have numerous configurations and settings I will never use.

ipcop vs ipfire

  1. Ipcop is simple and elegant. Its settings are easy to understand and intuitive. Just works and serves the purpose as a firewall very well.
  2. Ipfire has many features and packages. It appears it uses much more resources with my limited tests.

t1n1wall and smallwall

  1. t1n1 is simple to use and port forwarding for bittorrent clients works well. Its development is more recent than smallwall.
  2. smallwall should work almost identically with t1n1wall, and I chose t1n1wall simply because its releases are newer.

vmware and its network configuration

  1. For the LAN interface, I created vmnet2 and designated it as host-only network. There is no problems installing ipcop running on it, although I haven’t tested port forwarding heavily on it.
  2. You can also install MS Loopback NIC, create a new vmnet interface and designate it as bridged network.
  3. In virtual machine settings, in the Network Adapter section, click on Advanced, and modify its MAC address so that you will know which interface is assigned to WAN or LAN in the firewall.

questions that remains to be solved

  1. Linux firewalls appears to be less “secure”, because I don’t have to set port-forwarding rules to make bittorrent clients directly connect to the outside. With BSD flavored firewalls, I will need to specifically configure NAT rules and portforwarding to allow bittorrent work properly. Don’t know why this happens.
  2. Is for the LAN adapter, is Host-Only network safer than than Bridged network?
  3. For BSD firewalls, using Host-Only adapter does not seem to work. It has to be bridged network.

acknowledgements

These two resources provides very useful information for sett

  1. http://www.dowdandassociates.com/blog/content/howto-software-routers-on-virtual-machines/
  2. http://timita.org/wordpress/2011/07/31/protect-windows-with-pfsense-and-virtualbox-part-3-installing-virtualbox-and-creating-a-new-vm-for-pfsense/

What’s wrong with Hollywood?

Gravity is mediocre. The Internship is a commercial for Google. This is the End is a disaster. These are all getting high scores from IMDB. When the bad things get good reviews and high scores, it means the whole industry is at risk — the trust is lost. When movie watchers know the hard earned money and precious time are spent on manipulated reviews and scores, they will stop going to movie theaters. What’s coming next Hollywood? Depression.

AxCrypt is evil and it installs heinous Adware on your computer. Avoid at all costs!

AxCrypt is a nightmare for my computer. It downloaded many exe files and installed Conduit Adware across the system. My Firefox starting pages are deleted and the homepage is changed into http://search.conduit.com. An ugly and intrusive toolbar is also install on Internet Explorer (IE).

A virus total scan report shows that AxCrypt is infected with OpenCandy Adware. Actually it is worse than normal Adware because it is so pervasive and intrusive — most important of all, no user consent was acquired before this heinous AxCrypt infected system with Trojan like malicious applications: Malwarebye scan reports that there are about 140 folders, files and registry keys which are infected with conduit malware. Please avoid using AxCrypt at all cost. You have been warned.

To the developers of AxCrypt: shame on you!

Don’t watch Gravity

Gravity’s score and reviews on IMDB is dubious. For a stunning high score of 8.7 and over 48 thousand votes, I thought this movie must be very good. However, the result is disappointing. I will just give this movie a 6.0 for its visual effects but the story line is very simple and hurried to the end.

The inflated score on IMDB, just like it is on Taobao, will hurt the whole movie industry as the disappointed audience will no longer pay to watch movies with good reviews, knowing that the scores have been rigged. The good movies will suffer because they will not get the attention they deserve and are easily drowned in the noises created by illicit promotional activities. The individual’s voice will not be easily heard, although they supposedly have an equal vote with the movie ticket they buy.

In a digital age, the public opinion can be easily created and swung by a few key strokes and clicks — the monopoly of media tycoon can manipulate the statistics and the masses will buy into it and buy the mediocre products — the best ones do not even have a chance.

Some notes in the aftermath of Breaking Bad

OK, I was wrong about the finale of Breaking Bad and Heisenberg did die. The most unforgettable line in the last episode is, when talking about why he did what he did, “I liked it. I am good at it”. This explained why he wasn’t successful as chemistry teacher, because he didn’t fulfill his destiny — to do the things he is good at. The scene when the hidden machine gun in the trunk mowed down all the gang members is a cathartic outbreak of revenge. It is well done. However, it could be even better if he used his chemistry skills to deal with the gangs.

Now here is some new information I found about Breaking Bad. Bob Odenkirk performs the lawyer role brilliantly in the movie. He grew up in Naperville, Illinois. From his biography on IMDB, he is “three credits shy of graduation” and wrote extensively for comedian shows. He also won a few Emmy awards. One day, I perhaps need to write a book to list the successful college dropouts and the unsuccessful college graduates. Bryan Cranston certainly know the importance of sticking to it. I think when he was at the lowest point of his career, he had thought about quitting and became an insurance salesman. However, he didn’t. Here is what he said about why he didn’t give up: “You know, this business is pure luck. It truly is. There is a tangible amount of luck that is necessary for a successful career, and the only way that luck happens is if you’re prepared for it and you stick with it. If you drop out of the scene, your opportunity for luck diminishes greatly. No one’s going to say, ‘Hey you’re an insurance salesman. Come and do this movie.'” “I don’t need to work, but I love to work and I will make the movie if I would want to go and see it. ” “It is also interesting to learn he drove motorcycle around the US. It was just two confused boys running away. My brother was on the verge of becoming a deputy sheriff, and I was grappling with whether I wanted to be a police officer or an actor. So we got on our motorcycles and just left California with no plan. I had $70 in my pocket, and that soon ran out. We got odd jobs wherever we could. We worked at cafés, in carnivals, at beachfront hotels selling suntan lotion, earning just enough to get back on the road. We camped everywhere, the cheaper the better. Just a patch of grass was all we needed. A few times we stayed at midnight missions, in Texas and Louisiana, and those were always scary.”

Walter White will not die

I haven’t watched the last episode of Breaking Bad, but I am pretty sure Water White did not die in the finale. The producers and script writers have two choices: one is letting Mr. White put up a good fight and kill all his enemies and died a heroic death. The rationale behind this ending is Mr. White has late stage cancer and he will die anyway. The second ending is Mr. White will kill all his enemies and walk into the setting sun as Heisenberg — with his tell-tale hat.

I think the second ending will be favored because if Mr. White is dead, there won’t be opportunities to produce a possible sequel and even a movie on this brilliant story again. The death of Heisenberg means the loss of commercial interests, so he will not definitively die in the denouement.

In all circumstances, Mr. White will join hands with Jessie and annihilate the new meth cooks in a violent way. After the revenge, he will reclaim his money and leave for good, leaving behind the suspense that he would come back one day in a sequel TV series.

The focus of the last episode will be his revenge with the gangs, reconciliation with Jessie, temporary reunion with his family, and most of all, the redemption of his name — he is still Heisenberg!

The mechanization and standardization of American life

When I am reading the little and old book called America in Perspective, which collects over 30 essays written by foreigners to describe American way of life. The excerpt written by Richard Muller-Freienfels offered very penetrative insights by characterize as a country of mechanization and standardization. Although it was published in 1927, the descriptions are still exactly true in today’s America. I couldn’t help but dogear the page and jog down his insights as follows:

In a purely external sense, the mechanization of life is conditioned by the size of the country… A vast network of railways covers the land; the telegraph and the telephone, both largely American inventions, have reached a high degree of development… Above all, the motor-car is not a luxury, but an article of everyday utility, which is obvious from the shabby conditions of most of the cars one sees… In the eyes of the American all these things have a positive value… This general mechanization of life is, of course, due to the co-operation of a number of factors. The lack of domestic servants, which I shall presently consider as a social factor, has of necessity resulted in the mechanization, even in the home, of many tasks which in Europe are performed by human labor.Everyone who has visited the United States will be able to recall similar characteristics, all of which go to prove the same thing, namely, that the whole of life has been mechanized in a far greater degree than with us.. the prevalence of practical thinking, of the concentration of the intellect on the practical, useful, and efficient, and the obverse of this attitude is the repression and suppression of all that is merely agreeable, emotional, and irrational in the personality. This rationality, as a form of thinking and willing, expresses itself in constructions and instruments and machines which impress the purposeful will of humanity, with the aid of the inorganic forces of Nature, on the outer world. The machine is above all the typical creation and manifestation of the utilitarian and practical reason. It is pure practicality, embodied rationality.

The mathematization and technicalization of life is connected inextricably with a further trait of Americanism–with the typicalization, or, to use the American expression, the standardization of life. Nowadays one may also call this Fordization, since Mr. Ford is regarded a peculiarly representative of his country. Standardization is a consequence of mass-production, mathematization, and mechanization, for it implies the unlimited mass-production — for the most part by mechanical means — of a definite type of product … At all events, an observant eye will note the conspicuous appearance of the same features everywhere, in spite of obvious differences. This typification will be seen in the most prominent features as well as in the least conspicuous.

In every sizable town, there is a WalMart, Home Depot and Blockbuster. A visit to McDonald’s will show you the array of devices and equipment which makes fast food delivery even faster. It appears to me that for every problem, there is a technical solution and for every illness, there is a magic pill for it.

One unifying character of American society, which encompasses all the characteristics in this dazzling diversity in this country, is the inherent belief individualistic capitalism. Everyone is a business and you need to run it as you do with a business. You make personal choices and accept consequences. No one, even the parents, cannot run the business for the child, because they cannot face the liabilities of infringing upon another individual’s business. The consecration of individual capitalism began as early as when the egg is fertilized. As to the question of how closely this celebration of individual enterprise is related to the fundamental changes of Christian belief system, I am not so sure. But I know it does have a connection and has manifested itself ever since the first English immigrant steps on the new continent.

I hope to write a book on this topic one day.

IMDB score is inflated

Like the ongoing inflation, the rating score on IMDB is inflated. The movies with a rating of 7 or above are tedious and boring. Honestly, the 2012 movie Lincoln, which has a rating of 7.6, is unbearable to watch. After the first twenty minutes, I just quit. On the other hand, some movies are underrated. For example, Identity Thief is a good road trip comedy, but it is only rated 5.3. My experience is that any comedy with a rating of 5 or above is worth watching if you just want to relax and have some fun time.

Nicolas Cage and Jim Carrey, as your fan, I hope you can keep making good movies.