## Calculating How Much Tax Was Added When Only Knowing The Percentage.

Recently I started work on an iPhone app and came across a small problem. As part of the application I needed to know how much tax was added to a value when I only knew the tax percentage and the total after tax. Now if the tax rate was a fixed amount a formula would have been easy to generate (for example the UK has 20% tax so to find the tax paid you simply divide the total by 12 and multiply this by 2), The problem I had is that the tax rate was unknown as it was to be a user input.

I asked a few people and found that nobody I spoke too really knew any way to find this out. Most people suggested just working out the percentage of the total amount however this of course will not work.

Here is how I eventually worked this out : Continue reading “Calculating How Much Tax Was Added When Only Knowing The Percentage.”

The obvious answer to this is course  no however I did wonder for a while.

I recently signed up to Twitter (begrudgingly) and after a while I started to find people I really knew being suggested as people in my “Who To Follow” list.

This got me thinking, I have been very specific with the information that I have posted on Twitter. I have also been very specific with who I follow. None of my posts relate or are similar subjects to tweets by other people I know, nor do any of the people I follow (or follow me) have any relation to the people I know out in the real world. This of course got me somewhat confused as to how Twitter knew I had a link to these people. Continue reading “Are Twitter Psychic”

## Secrets and Lies: Digital Security in a Networked World (Bruce Schneier)

While doing my usual browsing of Amazon I came across Secrets and Lies by Bruce Schneier. I of course added this to my wish list and decided I would take another look at a later date. Some time later I decided to do a cull of my wish list. Unlike most people thou when I do a cull I tend to buy the item to remove it from my wish list.

When I bought the book I though that it was a bit of a gamble but looked ok so worth the risk. How more wrong could I be, this was certainly not a gamble at all.

Bruce starts the book by requesting that you read it numerous times so that the information sinks in and so that information obtained later in the book can be better understood.

The main part and bulk of the book explains many security concerns and explains why traditional thinking of security is incorrect (such as using a 256 bit encryption key is pointless and contains little security if the key was generated from for example the word password). Many aspects of security are covered within this ranging from network security to standard O/S security. At this point the book appears very negative and seems to suggest that there is little you can do to actually stop the impending security breaches.

Luckily as the book goes on the mood changes slightly and prepares you for methods to help combat the security implications that any system will have. These methods range from creating attack tree’s and how you can best decide on the viability of any attack vector and how to start bringing things into your favor instead of the intruders.

Since this book was written there have been many security breaches that have cost the companies involved large amounts of money both from lost revenue and the cost of picking up the pieces. For example this year Sony had a succession of attacks and the cost of the clean up was estimated to be around \$140,000,000, this estimate could quite easily increase substantially as Sony’s insurer is also seeking methods for removing their own liability over the issue meaning that any law suits will come out of Sony’s pocket instead of the insurer.

A short while after this Lockheed Martin were found to have been compromised. On investigation it became clear that RSA had been compromised allowing someone to obtain information on the systems which aided in the Lockheed Martin compromise. As a result of this RSA were essentially forced to replace 40,000,000 secure ID devices.

It is not only the financial cost that these companies have suffered there is also the untold damages to their company profile with which the cost can never really be calculated.

Now you may be wondering my point at this stage, well the point is that if only the security of these companies read this book they may have been better prepared. The frightening thing however is that too many companies take security as an after thought. If the price is too high they decide to disregard the advice or not bother.

## Conclusion

Although this is a 10 year old book this is certainly worth a read. You can learn so much from this book and it will completely change your perception of security. This book is highly recommended.

Title: Secrets and Lies: Digital Security in a Networked World
Author: Bruce Schneier
Publisher: John Wiley & Sons
ISBN 10: 0471453803
ISBN 13: 978-0471453802
Official Site – Buy On Amazon

## Mac – Mouse Scroll Inverted

** This was originally written for Lion. More recent versions display the option differently. Instructions at the bottom **

Yesterday Apple officially released the final version of 10.7 of their OS named Lion. For those of you that have upgraded you will notice that when trying to scroll up a page you actually scroll down and vice versa.

This seems a very strange choice for a desktop OS but is perfect for the iPhone (maybe they are trying to cater more for touchscreen monitors). Continue reading “Mac – Mouse Scroll Inverted”