예제 #1
0
        private void loadButton_Click(object sender, RoutedEventArgs e)
        {
            BitmapFrame frame = FileManager.LoadImage(this);

            byte[] data = ImageConverter.ImageToBinary(frame);
            loadedTextBox.Text = TextCrypter.BytesToString(data, privText);
            loadedImage.Source = frame;
        }
예제 #2
0
        private void generateKeyButton_Click(object sender, RoutedEventArgs e)
        {
            KeyValuePair <string, string> keys = TextCrypter.GetKeys();

            privateBox.Text = keys.Key;
            publicBox.Text  = keys.Value;

            privateKeyText.Text = keys.Key;
            publicKeyText.Text  = keys.Value;
        }
예제 #3
0
 private void generateButton_Click(object sender, RoutedEventArgs e)
 {
     byte[] data = TextCrypter.StringToBytes(inputTextBox.Text, pubText);
     createdImage.Source = ImageConverter.BinaryToImage(data);
 }