Sunday, January 26, 2020

Vigenère Cipher C Program

Vigenà ¨re Cipher C Program Write a C program to implement a Vigenà ¨re cipher. You may use whatever IDE you wish but the program must be compile with the standard gcc compiler. Your program should give the user the option to either encrypt or decrypt a message. The user should be prompted to enter the passphrase to be entered and the keyword to be used in the cipher. The output should be text printed to stdout. Comments should be used to explain the rationale behind the design of your code. You must also provide a critical analysis as to the robustness of the Vigenà ¨re cipher and provide a recommendation as to whether or not it would be it would be sufficient for use in communications between colleagues within a non-technical environment. C Programme /* Vigener Ciper*/ /*This is the program to Encrypt and to Decrypt the text using the Vigener ciper method*/ /* User has to choose the option either to Encrypt or to Decrypt */ /*The user has to enter the text to be Encrypted and the Key to*/ /*The user has to enter the Encrypted Text and Key to Decrypt the text*/ #include #include main() { int select;// variable declairation int i,j; char passphrase[256]; char keyword[33]; int value; while(1)// infinite loop { printf(n1.Encrypt n);// Display options for the user printf(2.Decryptn);// Encrypt or Decrypt scanf(%d,select);// read the option selected if (select == 1) { printf(Please Enter Message to be encryptedn);//text to be encrypted scanf(%s,passphrase); printf(Please Enter keywordn); // key word scanf(%s,keyword); for(i=0,j=0;i { if(j>=strlen(keyword))// repeat the key word { j=0; } value = (((passphrase[i])-97)+((keyword[j])-97)); //logic (passphrase+key)%26 printf(%c, 97+ (value %26)); // display Encrypted text } } else if (select == 2) { printf(Please Enter Encrypted Message to be Decryptedn); //text to be decrypted scanf(%s,passphrase); printf(Please Enter keyn);//key scanf(%s,keyword); for(i=0,j=0;i { if(j>=strlen(keyword)) { j=0;// repeate the key } value = ((passphrase[i])-96)-(keyword[j]-96); //logic (passphrase-key)%26 if( value { value = value * -1; //make the value positive } printf(%c,97 + (value % 26)); // display dencrypted message } } else printf(Please Choose a correct optionn); } } Introduction The c-program gives the user to choose either to encrypt or to decrypt a message. The user will be prompted to enter the passphrase to be entered and the keyword to be used in the cipher. Vigenere cipher is a form of polyalphabetic substitution cipher which is used for encrypting a plain text. Vigenere cipher can be explained by Caesar cipher method of encryption. In a Caesar cipher encryption method, every letter of the plain text is shifted to some number of places where as in vigenere cipher every letter is shifted with different shift values. Method of Encrypting and Decrypting The logic to obtain the cipher text by vigener cipher is by modular addition of plaintext and repeating keyword. The formula for the encryption is as follows C(i) = T(i) + K(i) (mod 26) C(i) i-th letter of the cipher text T(i) i- th letter of the plain text K(i) i-th letter of keyword (Key word will be repeated at its end) Similarly, the logic to decrypt the message is by modular subtraction of Encrypted text and keyword The formula for the decryption is T(i) = C(i) K(i) (mod 26) C(i) i-th letter of the cipher text T(i) i- th letter of the plain text K(i) i-th letter of keyword (Key word will be repeated at its end) The flow of the c- program is explained by the bellow flowchart Flow chart for the C-program 1. Encryption Flow chart for Decryption Function Robustness of the vigenere cipher When the Vigener cipher was first invented and came into use, it was difficult to break as it uses 26 different cipher alphabet. Vigenere cipher is a polyalphabetic cipher and these kinds of ciphers are difficult to decipher because of their resistance to letter frequency analysis and the same text will not be encrypted with same key each time. In the year 1854 a British cryptographer Charles Babbage found the method to decipher the message. The vulnerability for vigenere cipher is repetition of key When a word in plain text repeats it gives the hint to guess the length of the key Once the length of the key is found it is easy to crack the vigenere cipher The above example illustrates how the vigener cipher can be cracked. The plain text used in this is maths is short for mathematics and keyword used is key. Since the plain text contains the word math twice, cipher text also contains the same encrypted text WERR twice with 15 letters apart. Now it can be guessed that keyword must be a factor of 15. 1,3,5,15 are the factors, if it is 1 then it is simple caesar cipher , key word cant be of 15 letter in this case, between 3 and 5 it can be found easily by closely analyzing the ciphertext. Recommendation Considering the colleges within the non-technical environment Vigenere cipher can be recommended because, As the vigener cipher is difficult to break since it uses 26 different cipher alphabets. The method of encryption is difficult to understand by non-technical people. Without the key, it is difficult to decrypt the message Conclusion Vigener cipher is implemented by using the c-program and the flow of the program is explained with the help of flow chart. Vigener cipher is critically analyzed and its robustness is explained. Recommendations are made on use of this method for the communication between colleges in non-technical environment.      Ã‚   Reference http://crypto.interactive-maths.com/kasiski-analysis-breaking-the-code.html

Saturday, January 18, 2020

Child Sex Abuse

Child Sexual abuse â€Å"All my childhood lived a dual life-when I was being abused, and the life when I wasn't. â€Å"-Harris leery, an Indian survivor of child sexual abuse, who had a tremendously shocking childhood. Whenever I think about his suffering, my soul starts to tremble with nauseating. For about 11 years of his life, he used to get raped in the place, what we call home; however†¦ For a 7 year old Harris, his home used to be worse than the hell whenever his soul used to be sucked by a Demented of his family.It's not only about Harris or Indian children; all around the world children have been victimized by inhumane abusers. â€Å"In JACK, 1 in 20 children have been sexually abused†-NSP. 18,91 5. This humongous number is the number of children sexually abused in 2012/2013 in England and Wales; imagine the number in the UK, Europe and the world. Think! May be, the person sitting next to you might was, is or going to be sexually abused. You, your friend or your family member might be one of them. Is this the modern world: the 21st century?I don't think so! These children are the future; and our future seems to be blemishing because these buds are put to sleep before they emerge and blossom as flowers. Help! Help! The children's soul screams but in the silence. Those little and pure minds are tortured, threatened and tormented till they give up. New research suggests children who are repeatedly abused, or are abused by a member of their immediate family, are at higher risk of attempting suicide in later life. Help these children. It feels nice.

Friday, January 10, 2020

John Locke Paper Essay

Throughout the 17th century, John Locke presented society with his teachings and theories that clarified the order of natural law and fulfilled humanity’s divine purpose for living. It all began in 1647, as a young boy when he attended the prestigious Westminster School in London under the sponsorship of Alexander Popham. During his years at the Westminster School, he found the work of modern philosophers more interesting than the material being taught at the university. Much of Locke’s influence and later work was characterized by opposition to authoritarianism, which focused on both the level of the individual person and on the level of institutions such as government and church. Locke wanted each of us to use reason to search after truth rather than simply accept the opinion of authorities or be subject to superstition. He wanted us to proportion go along with the proposition to the evidence for them. Locke came to the conclusion that there must be a balance and mutual understanding between individuality and social institutions where society will not feel suppressed under man made law and restrictions. John Locke believed that all knowledge comes from experience. Experience is composed of two parts: external and internal. External experiences are ideas of supposed external objects. These objects enter our minds through sensation. Examples of sensations would be hot, cold, red, yellow, hard, soft, sweet and bitter. Internal experiences are reflections that make us understand the operation on the objects of sensation. Examples of reflections are thinking, willing, believing, doubting, affirming, denying, and comparing. Once again Locke goes back to his foundation of principles by reaffirming that in order to achieve success and sensation there must be a working relationship between individual goals and the law of society. Sensation and reflection are called the two fountains of knowledge. All of our ideas we can naturally have or have so already come from these two experiences. Sensible qualities convey into the mind, and they produce most of the perceptions and most of the great sources of ideas we have. Sensation and reflection differ from each other because sensation is what happens outside the body, and reflection has to do what happens inside the body with our mind. Also reflection has to do with the ideas it affords being such only as the mind gets by reflecting on its own operations within itself, the mind takes over its own operations and the manner of them. Besides having sensible qualities one also contains primary and secondary qualities. Locke explains that these qualities are two kinds of properties that an object could have. Primary qualities contain solidity, figure, extension, motion and number. They are properties that are objective and independent on senses. On the other hand, secondary qualities consist of color, smell, taste, sound and touch. They are properties that are subjectively perceived. In Locke’s, An Essay Concerning Human Understanding, he states, â€Å"sensible qualities; which, whatever reality we by mistake attribute to them, are in truth nothing in the objects themselves, but powers to produce various sensations in us†¦Ã¢â‚¬  (John Locke, 77). In other words, secondary qualities are dependent on the primary qualities. According to Locke, ideas are anything that is â€Å"the immediate object of perception, thought, or understanding† (William Lawhead, 91). Locke states that sensation and reflection are classified as simple and complex ideas. Simple ideas are red, yellow, hard, soft, etc and for example, you touch an ice cube, your mind is telling you its cold and it’s hard, you learn that from experience. Locke believed that the mind cannot know an inexperienced idea or create a new simple idea. Although the mind cannot create simple ideas, it can process them into complex ideas. Complex ideas are made up of several simple ideas, such as beauty, gratitude, a man, an army, the universe. Complex ideas are also broken down into three parts: ideas of substance which is a constant collection of simple ideas, ideas of mode which is a combination of several ideas, which form a mode, like a triangle, last but not least ideas of relationship, which is a comparison of one idea to another. From experience it goes to sensation and reflection, and those are based on simple ideas and that’s all contained in the passive mind, after simple ideas it goes to complex ideas and that’s located in the active mind. Overall in Locke’s theory he uses epistemological dualism, which is the mind that consists of knowing and its ideas. He also states the object in the external world is known by ideas, and our ideas represent those objects. After researching about Locke’s theory of knowledge I would have to agree with what he has stated. Locke states that you go through an internal and external experience and I feel that today’s youth do go through the motions of the internal and external experiences. As a result the youth are able to gain the knowledge from those experiences by allowing the mind to willingly accept these new ideas. For example, when I was younger I put my hand near a hot stove and from the heat irritating and pressuring my hand my mind told me it was a negative stimuli and it was essential to remove my hand from the stove and to keep that memory as a basic instinct. Society goes through experiences throughout life of internal and external and eventually gains knowledge through these experiences. John Locke also stated that the mind does all the knowing and its ideas are known. I agree with what he is saying because your mind is always working, it’s always active, we receive ideas internally through our mind and we receive ideas from the outside that goes into our mind. The balance is necessary between internal and external factors to keep society and individuals stable and yet progressive to adapt to new changes that rise up.

Thursday, January 2, 2020

Bullying Is Just A Part Of Growing Up And There Is Nothing...

Lersch 1 Katherine Lersch Coach berry Computer Literacy 3 December 2014 Behind Bullying Some parents think bullying is just a part of growing up and there is nothing wrong with it. That is the wrong way to think of bullying, and something needs to be done. Now there are so many campaigns about stopping bullying, and I bet in the future there will be no bullying. There are several questions, the first one is, what are the different types of bullying? You probably think bullying is only hitting, kicking, and punching, but there are six different types. There are: physical, verbal, hidden, sexual, cyber bullying, and relational aggression. The first one is the most common, physical. It includes hitting, kicking, tripping, pinching, and damaging someone s property. This one is easy to figure out if a kid is being bullied. Another type is verbal, and it is an emotional type of bullying. This one attacks self-confidence, and/or self-esteem. It includes name calling, insults, teasing, intimidation, homophobic remarks, racial remarks, and verbal abuse. The third type is hidden, this one is the hardest to detect. Sometimes the victim doesn t know that they are being bullied. This type of bullying is supposed to harm someone s reputation and/or cause humiliation. To make it hidden it includes lying, spreading rumors, nasty facial or physical gestures, mean looks, playing cruel jokes, rudely mimicking someone, encouraging others to socially exclude someone, andShow MoreRelatedBullying Argumentative essay970 Words   |  4 PagesArgumentative Essay 25 November 2013 Bullying Have you ever seen or experienced bullying and the dramatic effects it has on its victims? Unfortunately nine out of every ten students have experienced bullying in school or online. Many people believe that bullying is a part of growing up and kids do not know any better. Bullies are intentionally causing mental and or physical damage to their victims, which will affect them for the rest of their lives. Bullying has shown that it can cause self inflictedRead MoreThe Effects Of Bullying On The Person That Is Being Bullied1147 Words   |  5 Pagestreated like they weren’t important? It is time to take a stand! When someone is bullying you, they are using their strength to influence or intimidate you or someone else to do what they want to be done. They are this way to people that seem smaller and weaker to them. While some believe that bullying makes a person stronger, it actually damages the victim which can lead to a lowered self-esteem and suicidal thinking. Bullying is bad for everyone whether you are old or young. It has long term effectsRead MoreSocial Media Plays an Important Role on How Children Act730 Words   |  3 Pagessee can affect their entire view on what is right and what is wrong. Children also spend endless hours doing nothing except staring at screens, which could lead to mental and/or health issues. New technology is making bullying easier at school and now at home. Modern culture is ruining childhood by exposing children to inappropriate things too soon, causing mental and health issues, and bullying. Social Media plays a big part in how kids act, what they think, what they say, and how theyRead MoreThe Effect Of Teen Bullying Essay1618 Words   |  7 PagesEffects of Teen Bullying Bullying is defined as a superior strength or influence to intimidate someone, typically to force him or her to do what they want. Teenage bullying is a serious problem in school and it is not always physical. There are several types of bullying including physical, verbal ,emotional, covert and cyberbullying. Physical bullying can include fighting, hitting, kicking, etc. while emotional bullying can include gossiping or leaving someone else out on purpose(Bullying Info and FactsRead MoreBullying And Its Effect On Bullying1225 Words   |  5 Pagesnew part of their group ridicule, it may give pause. Any pause in this situation is too much time wasted while another child suffers at the hands of bullying. There is no way to put a complete stop to bullying. Even if people responded to the issue in an ideal way, which almost no one does, there is not a one-size-fits-all solution to the problem (Whitson). People too often refer to an understood goal to stop bullying. They use terms like prevention and the phrase, â€Å"bring an end to bullying.† ARead MoreBullying Is An Emotionally Draining Issue Prominent Across The World Today1111 Words   |  5 PagesSenior English 18 January 2017 Rough Draft Bullying is an emotionally draining issue prominent across the world today. Bullying is unacceptable, and there are many, if not several movements in an effort to end bullying once and for all. Throughout the course of this essay, I am going to discuss the issue of bullying, and formulate an argument towards the issue at hand. In this argument, I will show my support in the fight against bullying. A lot of things have changed throughout the courseRead MoreAdvice for Dealing With Bullying Essay924 Words   |  4 PagesDealing With Bullying If you are worried discuss this with a teacher. Bullying is not easy to define. Sometimes it involves hitting or kicking. But threats, teasing, and taunting are more common and can be more damaging. The word bullying is used to describe many different types of behaviour ranging from teasing or deliberately leaving an individual out of a social gathering or ignoring them, to serious assaults and abuse. Sometimes it is an individual who is doing the bullying and sometimesRead MoreEssay Bullying1404 Words   |  6 PagesBullying What is bullying? We might have seen it every day, and we still do not know what it is. In the short story â€Å"Black Boy,† Richard Wright shows how he was bullied as a young African American boy. However, bullying is not limited to one type of person living in one time period. It still exists today in the form of young people getting bullied on the streets, and at school. It could be very harmful, and could lead to serious damages, but sometimes it could help  by making people stand  up forRead MoreBullying Is A Form Of Action Made By An Aggressive Person1673 Words   |  7 PagesBullying is a form of action made by an aggressive person, and which it involves a direct or indirect approach to another person. The imbalance of power between the parties involved are dominating and submission. This behavior involves a negative pattern, having to deal with physical, verbal, gestural or non- verbal actions. The impact of emotional effects, and the long term consequences it h olds for a person being targeted by this action. The new form of bullying is â€Å"Cyberbullying† through electronicRead MoreBullying Should Be Addressed For The Proper Development Of Children1347 Words   |  6 PagesBullying is a very strong word to all the people around the world but some time people may not know if they are bullying other people. Bullying to all of us means something different. This is why I consider it very hard to judge and punish bullying as definitely what is bullying? Is bullying when you just fight with a kid or simply insult him and he insults you back, is it when you tease him for something he does, or is it when you take things from him without his permission is that bullying? Studies