• No results found

private void menuExit_Click(object sender, EventArgs e) {

Application.Exit();

}

private void MainForm_Load(object sender, EventArgs e) {

private void button1_Click(object sender, EventArgs e) {

RSACryptoServiceProvider RSAKey = new RSACryptoServiceProvider(2048);

this.textBoxKeyLength.Text = RSAKey.KeySize.ToString();

System.Text.Encoding ByteEnc = System.Text.Encoding.ASCII;

logStreamWriter.Write("\t");

textBoxPowerEnd.Text =

for (int i = 0; i < n; i++)

logStreamWriter.Write(this.textBoxPowerEnd.Text);

public void CreateTxtFile(string FileName, string content) {

myStreamWriter.Close();

} } }

private void menuItemGenerateFiles_Click(object sender, EventArgs e) {

this.textBoxDump.Text = this.textBoxDump.Text + "Generating text files.... ";

CreateTxtFile("Temp\\160B.txt", RandomString(160));

CreateTxtFile("Temp\\1KB.txt", RandomString(1000));

CreateTxtFile("Temp\\10KB.txt", RandomString(10000));

CreateTxtFile("Temp\\100KB.txt", RandomString(100000));

string LogFileHeader = "Loop\tMode\tKey\t Input\tIterations\tDuration\tPowerStart\tPowerEnd\tOutput

Length\r\n===============================================================================

=============================== \r\n";

CreateTxtFile("Temp\\Baselinelog.txt", LogFileHeader);

CreateTxtFile("Temp\\RSAlog.txt", LogFileHeader);

CreateTxtFile("Temp\\AESlog.txt", LogFileHeader);

this.textBoxDump.Text = this.textBoxDump.Text + "done.\r\n ";

}

private void menuItem1_Click(object sender, EventArgs e) {

this.menuItemRSA.Checked = true;

this.menuBaseline.Checked = false;

this.textBoxCurrentMode.Text = "RSA";

}

private void menuItemAES_Click(object sender, EventArgs e) {

private void menuBaseline_Click(object sender, EventArgs e) {

APPENDIX B. SECURE CHAT

private MessageInterceptor SMSInterceptor = new MessageInterceptor(InterceptionAction.NotifyAndDelete, true);

private MessageCondition msgCondition = new MessageCondition();

string ToPhoneNumber = "";

private void SMSMessageReceived(object sender, MessageInterceptorEventArgs e) {

RSACryptoServiceProvider RxRSA = new RSACryptoServiceProvider(1024);

SHA1CryptoServiceProvider RxSHA = new SHA1CryptoServiceProvider();

if (msg.Body.Substring(0,2)=="**")

//Read private key for decryption

FileStream RxReadPrivfs = File.OpenRead("Program Files\\SecureChat\\" + MyPhoneNumber + ".prv");

FileStream RxReadPubfs = File.OpenRead("Program Files\\SecureChat\\" + FromPhoneNumber+ ".pub"); ByteConverter.GetString(RxdecryptedData, 0, RxdecryptedData.Length) + "\r\n";

}

private void MainForm_Load(object sender, EventArgs e) {

// Intercept SMS starting with *

msgCondition.Property = MessageProperty.Body;

msgCondition.ComparisonType = MessagePropertyComparisonType.StartsWith;

msgCondition.ComparisonValue = "*";

SMSInterceptor.MessageCondition = msgCondition;

//set up event handler to process incoming messages SMSInterceptor.MessageReceived += new

MessageInterceptorEventHandler(SMSMessageReceived);

this.comboBoxToPhoneNumber.SelectedItem = "+18319175596";

this.textBoxMsgToSend.Focus();

this.textBoxToPhoneNumber.Text = "+1";

}

private void menuItemExit_Click(object sender, EventArgs e) {

Application.Exit();

}

private void buttonSend_Click(object sender, EventArgs e) {

dataToEncrypt = ByteConverter.GetBytes(this.textBoxMsgToSend.Text);

//Set Recipient phone number

ToPhoneNumber=this.comboBoxToPhoneNumber.SelectedItem.ToString();

}

//Create a new instance of RSA

RSACryptoServiceProvider TxRSA = new RSACryptoServiceProvider(1024);

SHA1CryptoServiceProvider TxSHA = new SHA1CryptoServiceProvider();

//Read private key from file

FileStream TxReadPrivfs = File.OpenRead("Program Files\\SecureChat\\" + MyPhoneNumber + ".prv");

FileStream TxReadPubfs = File.OpenRead("Program Files\\SecureChat\\" + ToPhoneNumber + ".pub");

MsgToSend.Send();

private void menuItem2_Click(object sender, EventArgs e) {

RSACryptoServiceProvider RSAKey = new RSACryptoServiceProvider(1024);

byte[] MyPubKeyBlob = RSAKey.ExportCspBlob(false);

private void menuItemSendPubKey_Click(object sender, EventArgs e) {

//Read my public key from file

FileStream ReadMyPubfs = File.OpenRead("Program Files\\SecureChat\\" + MyPhoneNumber + ".pub");

BinaryReader ReadMyPubbr = new BinaryReader(ReadMyPubfs);

byte[] MyPubKeyBlob = ReadMyPubbr.ReadBytes(148);

ReadMyPubbr.Close();

ReadMyPubfs.Close();

string TxPubKeyString = "*x" + Convert.ToBase64String(MyPubKeyBlob);

//Send my public key;

SmsMessage KeyToSend = new SmsMessage(ToPhoneNumber, TxPubKeyString);

KeyToSend.Send();

this.textBoxDump.Text += "Public key sent to " + ToPhoneNumber + "\r\n";

}

private void comboBoxToPhoneNumber_SelectedIndexChanged(object sender, EventArgs e)

{ }

private void buttonSendClear_Click(object sender, EventArgs e) {

if (checkBoxToPhoneNumber.Checked) {

ToPhoneNumber = this.textBoxToPhoneNumber.Text;

} else {

ToPhoneNumber = this.comboBoxToPhoneNumber.SelectedItem.ToString();

}

SmsMessage SendClear = new SmsMessage(ToPhoneNumber, this.textBoxMsgToSend.Text);

SendClear.Send();

this.textBoxDump.Text += "SMS sent to " + ToPhoneNumber + "in CLEAR!\r\n";

} } }

THIS PAGE INTENTIONALLY LEFT BLANK

LIST OF REFERENCES

[1] Rafat, Ali, The SMS Privacy Problem, Textually.org website,

http://www.textually.org/textually/archives/2004/04/003489.htm, last accessed 19 October 2006

[2] Breed, Allen G., Ubiquitous message technology can be powerful tool for good or ill, TMCNet Website,

http://www.tmcnet.com/usubmit/2006/10/17/1985881.htm, last accessed 19 October 2006.

[3] Jones, Nick, Don't Use SMS for Confidential Communication, Gartner Website, 26 November 2002,

http://www.gartner.com/DisplayDocument?doc_cd=111720, last accessed 19 October 2006.

[4] GSM World, GSM Facts and Figures,

http://www.gsmworld.com/news/statistics/index.shtml, last accessed 17 October 2006.

[5] GSM World, GSM Services,

http://www.gsmworld.com/services/index.shtml, last accessed 17 October 2006.

[6] European Telecommunications Standards Institute, GSM 02.01, Digital cellular telecommunications system; Principles of telecommunication services supported by a GSM Public Land Mobile Network (PLMN).

[7] Vijay, K. Garg and Joseph E. Wilkes, Principles & Applications of GSM, Prentice Hall 1999.

[8] European Telecommunications Standards Institute, GSM 02.09, Security aspects.

[9] A. Mehrotra, GSM System Engineering. Norwood, MA: Artech House, 1997.

[10] European Telecommunications Standards Institute, GSM 02.17, Subscriber Identity Module

[12] Margrave, David, GSM Security and Encryption,

http://www.hackcanada.com/blackcrawl/cell/gsm/gsm-secur/gsm-secur.html, last accessed on 17 October 2006.

[13] Pesonen, Lauri , GSM Interception, Helsinki University of Technology, 21.11.1999, http://www.dia.unisa.it/professori/ads/corso-security/www/CORSO-9900/a5/Netsec/netsec.html, last accessed 17 October 2006.

[14] GSM Cloning, http://www.isaac.cs.berkeley.edu/isaac/gsm.html, last accessed 17 October 2006.

[15] Josyula, R. Rao, Pankaj Rohatgi and Helmut Scherzer. IBM Watson Research Center, Proceedings of the 2002 IEEE Symposium on Security and Privacy (S&P‘02).

[16] GSM Security, http://www.gsm-security.net/faq/gsm-encryption-algorithm-a5-cipher.shtml, last accessed 25 October 2006.

[17] Elad, Barkan, Eli Biham, Nathan Keller, Instant Ciphertext-Only Cryptanalysis of GSM Encrypted Communication, CS-2003-05,

Proceedings of Crypto 2003.

[18] Traynor, Patrick, William Enck, and Patrick McDaniel and Thomas La Porta, Mitigating Open Functionality in SMS-Capable Cellular Networks, Proceedings of the ACM Twelfth Annual International Conference on Mobile Computing and Networking (MobiCom), September 2006.

[19] Guthery, Scott and Cronin, Mary, Mobile Application Development with SMS and the SIM Toolkit, McGraw Hill, 2002.

[20] Mobile/Cellular Technology, SMS (Short Message System) Mobile Technology, International,

http://www.mobilecomms-technology.com/projects/sms/, last accessed 23 October 2006.

[21] Starhub Mobile Service: Price Plans, Starhub Website,

http://www.starhub.com/mobile/mobileservice/voiceplans.html#voice, last accessed 25 October 2006.

[22] ETSI Technical Specification TS 101 181 V8.9.0 (2005-06) Digital cellular telecommunications system (Phase 2+); Security mechanisms for SIM

application toolkit; Stage 2 (3GPP TS 03.48 version 8.9.0 Release 1999).

[23] Ponemon Institute, LLC, U.S. Survey: Confidential Data at Risk,

http://www.securitymanagement.com/library/Ponemon_laptoptheft1106.pdf, last accessed on 30 October 2006.

[24] GSM Association Press Release 2006, Mobile Networks to Cover 90% of the World's Population by 2010,

http://www.gsmworld.com/news/press_2006/press06_51.shtml, last accessed 30 October 2006.

[25] Singh, Gurminder, Mobile Alerts Project Slides, May 2006,

http://www.nps.navy.mil/cs/singh/CMDC/MobileAlerts.pdf, last accessed on 1 July 2006.

[26] Le, Phong and Hsu, Michael, Web Portal for the Integrated Messaging System. M.Sc. Dissertation, Naval Postgraduate School, Monterey, CA, 2006.

[27] General Dynamics C4 Systems, General Dynamics Announces First Type 1 Secure Phone for GSM, http://www.gdc4s.com/news/detail.cfm?prid=96, last accessed 27 October 2006.

[28] Schneier, Bruce, Applied Cryptography, Second Edition, John Wiley &

Sons, 1996.

[29] Kaufmann, Charlie, Perlman Radia, Speciner Mike, Network Security:

Private Communications in a Public World, Prentice Hall, 2002.

[30] Denning, Dorothy, Information Warfare and Security, Addison Wesley, 1999.

[31] Saltzer, Jerome H. and Schroeder, Michael D., The Protection of

Information in Computer Systems. Proceedings of the IEEE, 63(9):1278–1308, 1975.

[32] Hagai, Bar-El, Introduction to Side Channel Attacks,

http://www.discretix.com/PDF/Introduction%20to%20Side%20Channel%20Attack s.pdf, last accessed 13 November 2006.

[33] Handys-Mobile Website,

http://www.handys-mobile.de/img/eten_m600.jpg, last accessed 7 November 2006.

[34] Microsoft Developer Network, Learn Windows Mobile: Overview,

http://msdn.microsoft.com/windowsmobile/learning/#WMApps, last accessed 7 November 2006.

[35] Microsoft Developer Network, Windows Mobile Version 5.0 SDK

[36] Bishop, Matt, Computer Security: Art and Science, Addison Wesley, 2005.

[37] Alex Varshavsky, Mike Y. Chen, Eyal de Lara, Jon Froehlich, Dirk Haehnel, Jeffrey Hightower, et al. , Are GSM phones THE solution for

localization?, http://placelab.org/publications/pubs/GSM-hotmobile2006.pdf, last accessed 24 November 2006.

INITIAL DISTRIBUTION LIST

1. Defense Technical Information Center Ft. Belvoir, Virginia

2. Dudley Knox Library

Naval Postgraduate School Monterey, California

3. Professor Yeo Tat Soon

Director, Temasek Defence Systems Institute (TDSI) National University of Singapore

Singapore

Related documents