# MOAR codey stuff

I turned my last post on cryptography into a two-parter because there was a fair ton of stuff that I wasn’t able to cover in that particular 1200 words that I consider to be interesting/relevant, so here the rest of it comes.  I’m not going to bother for an intro this time though, so go and read my last post (if you haven’t already’ before this one to make sure we’re all on the same level here.

We all good? OK, let’s talk about public keys.

When one encodes or decodes a cipher, you perform a slightly different process when performing each process, but each process is mathematically related to the other. For example, when encrypting a Caesar cipher you ‘add three’ to the ‘value’ of each letter, and when decrypting you subtract three; the one process is the inverse of the other. These different types of key, or parts of the overall key, are known as the encryption and decryption keys. Since the two are mathematically related, knowledge of the one allows an enemy cryptanalyst to discover the other with relative ease in most cases; thus, both keys have to be kept very secret to avoid exposure, and making the distribution of keys a dangerous business.

However, in the RSA algorithms talked about at the end of the last post the tool for its encryption (the massive number M and the power P it is raised to) are no use to a foe if he does not have the two prime factors of M needed to decrypt it (I still don’t get how that works mathematically) with any degree of ease. Thus the encryption key needed to send messages to a person secretly can be distributed freely and be known to anyone who wants to, without fear of these secret messages being decoded; incredibly useful for spy networks, since it allows multiple operatives to use the same key to send messages to someone without fear that the capture of one agent could compromise everyone else’s security. In this kind of cryptography, the key distributed publically and which anyone can access is known as the ‘public key’, whilst the secret key used to decrypt it is called the ‘private key’.

RSA algorithms are not the only methods employed in public key cryptography, but any cryptographical methods it does employ are inherently secure ones. Public and private keys have other uses too beyond secure encryption; when encrypting a message using somebody else’s public key, it is possible to add a digital ‘signature’ using your private key. The recipient of your message, upon decrypting it with their private key, can then use your public key and a special algorithm to verify your signature, confirming that the message came from you (or at least someone in possession of your private key- I still don’t know how the maths works here). You can also ‘share’ private and public keys with another person to produce a ‘shared secret’, but here my concept of what the hell is going on takes another large step back so I think I’ll leave this subject there.

Despite all its inherent security, there is one risk still associated with public-key cryptography and techniques similar to the RSA algorithm. The weak link lies in the key itself; the transferring of a private key is (mostly) only ever necessary when old lines of communication are insecure, meaning that a key can often be intercepted by a sharp enemy cryptanalyst. If he is smart, he’ll then send the key straight on to its intended recipient, meaning they are likely to carry on using it oblivious of the fact that the other side can intercept and translate every message sent to him. Therefore, it is advantageous to remove this weak link by ensuring the recipient can tell if the message has been intercepted; and here we enter the weird and wonderful world of quantum cryptography.

The name is actually a misnomer; quantum theory and effects cannot be used to encrypt secure messages, and the term refers to two ideas that are only related to cryptography. One is the theoretical possibility that future quantum computers may be able to crack the RSA problem and throw the world of cryptanalysis wide open again, whilst the other, far more practical, side of things refers to this method of confirming that a message has not bee intercepted (known as quantum key distribution, or QKD). The theory behind it is almost as hard to get your head around as the maths of the RSA algorithm, but I’ll try to explain the basics. The principle behind it concerns Heisenberg’s uncertainty principle; the idea that attempting to observe a quantum effect or system will change it in some way (just go with it). The two parties sending a message to one another communicate in two ways; one via a ‘quantum link’ with which to send the secret message, and another via an open channel (e.g. the internet). The first party (who convention dictates is called Alice) sends her message via the quantum channel, polarising each bit of quantum data in one of two types of direction (just go with it). The receiving party (traditionally called Bob) receives this polarised quantum data, but since he doesn’t know which type of polarisation Alice has uses he just picks one at random each time (just go with it). About half of the time, therefore, he’ll get the right answer. Alice then tells him over the open channel which polarisation she used for each bit (usually, for reasons of speed, this is all done automatically via computer), and Bob tells her which type of polarisation he checked for each bit. They both discard the ones where they did it a different way around, and keep the ones where they did it the same way as a shared key- thus is the key exchanged.

However, if somebody (Eve, conventionally) has been eavesdropping on this little conversation and has measured the polarisation of the quantum bits, then the polarisation of the bits will have been changed by this process (just go with it). This introduces error into Bob’s reading, some of which can just be put down to the mechanics of the process; if, however, more than p bits show an error (p is picked to be a suitable number- I couldn’t give you an example), then the line and key is presumed to be insecure and the whole process is started again. Simple, isn’t it?

# Think of the CHILDREN!

My last post dealt with the way that sex in our society is something kept very much under wraps, dusted under the carpet and kept out of the conversation of everyday life as much as possible. This post however could be said to be completely debunking every point I made in the last one, for today I will be considering the issue of the increasing use & prevalence of sex, sexuality and sexual connotations in society today.

The main people voicing a strong opinion against this trend are, of course, the kind of militant parents who started a war in the South Park movie (good film, see it if you can). They argue that modern media and marketing strategies place a lot of emphasis on the use of sex symbols and sexual connotations, and that these strategies are, more worryingly, being aimed at a steadily younger audience. Young girls in particular are often quoted as being aggressively targeted by clothing companies from as young as 8, companies trying to buy them into the whole ‘looks and clothes are the most important thing ever’ mentality in order to turn them into fashion-obsessed consumers as early as possible.

There’s certainly a lot of evidence to support their theory as to the increased prevalence of sexual symbolism in today’s culture. Sport may be a good place to look for examples- modern female sports stars are nowadays judged mainly by the way they look, and in many sports where men and women have roughly equal exposure (such as tennis) female competitors often have larger sponsorship deals. Is this because they are better at persuading people that sports equipment is awesome? No, it’s because they are capable of advertising perfume by wearing hardly any clothes and exploiting their sex appeal (think Maria Sharapova, whose game suffered heavily in the few years after she won Wimbledon as she turned into more of a model than a tennis player). And then what about tabloid newspapers and their page 3 hooks for readers, ‘lads mags’ that now have enough status to be invited as judges for the nomination of Sports Personality of The Year (not the BBC’s proudest moment), and clothes companies that now market ‘sexy high heels’ at under 10s?

So… where can this be traced back to? Well, if we, as the pressure groups tend to, blame everything on businesses and clothing companies, their reasoning is actually very simple. Firstly, to consider the issue of children being targeted in one way or another, it’s a well recognised fact that kids love to appear grown-up. They get fussy about their ages (“I’m not 10, I’m 10 and a half!”), copy their parents’ habits and what they see on TV, hate not being able to do stuff on account of age or size and might even try on Mummy and Daddy’s clothes when they’re a bit younger. A child’s ultimate fantasy (and probably one shared by a few adults as well) is to live with all the opportunity and ability of an adult, and without any of the responsibility. For them, therefore, all this sexually-related material that permeates their life is not about sex (which they probably don’t understand properly if at all), but about adulthood, and this just screams ‘awesome’ directly at them. We must also remember that it’s not just the kids who’re at it either; parents love it when their children appear ‘grown-up’ and mature because it makes them seem special, a cut above their peers, subtly suggesting to parents that not only are their kids better than everyone else’s, but that they themselves are better parents. Therefore, whilst some parents might be appalled at the sight of a 9 year old in heels and a miniskirt, others might think of her as quite the young woman, and perhaps even be jealous of the maturity that child seems to have compared to theirs.

And then we must consider a fact that countless bits of market research has shown- sex appeal sells stuff. Even if children don’t get the symbolism, their parents do, and whether the stuff they’re buying is for them or their kids, a bright, smiling, good-looking woman is more likely to encourage them to buy something than an advert featuring a dour looking bloke showing no interest whatsoever. This is especially true when we consider fields such as scent, beauty products and fashionable clothing, all of which are selling products actively designed to make you seem more attractive and, according to Freud at least, get you more sex. Even if you don’t make that connection consciously, there’s no doubt that your subconscious mind picks up on the connection, and that’s before we even consider how totally blatant use of sex, such as in tabloid page 3 columns, acts as a straight marketing hook to sell things. Put simply, sex appeal is an undeniably successful marketing strategy that makes perfect sense, from a purely fiscal point of view, to use.

To finish off, I would like to offer just a snippet of a history lesson. The 1920s were a great time for the USA, producing an economic boom thanks to the likes of Henry Ford,  massive growths in cultural areas such as major league sport, and reinventing social mobility. For the first time, women had a degree of social freedom, particularly among those known as ‘flappers’, who would cut their hair short, drink and smoke in direct and deliberate contravention of the classical female norm. The invention of the car gave young people freedom from their parents and invented the date for the first time, and in jazz music the young of the Roaring Twenties had their own music and social scene as well. This lead, among other things, to a huge increase in sexual freedom among the young, and the media of the time reflected this. This was especially true in the cinema, a relatively new phenomenon, which quickly developed the first sex symbols in the likes of Rudolf Valentino and Clara Bow, prompting advertising and marketing of the time to begin exploiting sex appeal as a means to sell their products. Understandably, the older generation went into uproar over this cultural revolution, but it didn’t make a scrap of difference, and a fresh wave of American culture swept across the world.

Sound familiar? It should do- it’s the same thing people are complaining about now, and people have complained in the same way about the changes in every successive generation, be it teenagers in the 50s, hippies in the 60s, or metal in the 70s. Culture changes, and that’s just a fact of life. There’s nothing wrong with being angry about it, but we must remember that society has survived each new wave of culture and come through each none the worse for wear. If you want to uphold society, then forming a pressure group for each successive thing that offends you probably isn’t the bet way to weather the storm. You’ll have far better results just sticking to what you do like, upholding the values you think are important, and trying to pass those off to your children. It’ll be a lot less painful.