⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 jiemi.java

📁 应用公钥加密体制的代表算法RSA 应用对称加密算法DES 应用散列算法MD5计算消息摘要 数字签名并验证
💻 JAVA
📖 第 1 页 / 共 2 页
字号:
/* * jiemi.java * * Created on 2007年10月23日, 下午8:41 */package b;import java.awt.*;import java.awt.event.*;import java.io.*;import java.security.*;import javax.crypto.*;import javax.crypto.spec.*;import java.security.interfaces.*;import javax.crypto.interfaces.*;import javax.swing.JOptionPane;import java.net.*;/** * * @author  guowen */public class jiemi extends javax.swing.JFrame {        /** Creates new form jiemi */    public jiemi() {        initComponents();    }        /** This method is called from within the constructor to     * initialize the form.     * WARNING: Do NOT modify this code. The content of this method is     * always regenerated by the Form Editor.     */    // <editor-fold defaultstate="collapsed" desc=" Generated Code ">                              private void initComponents() {        jLabel1 = new javax.swing.JLabel();        jTextField1 = new javax.swing.JTextField();        jButton1 = new javax.swing.JButton();        jLabel2 = new javax.swing.JLabel();        jTextField2 = new javax.swing.JTextField();        jButton2 = new javax.swing.JButton();        jButton4 = new javax.swing.JButton();        jLabel3 = new javax.swing.JLabel();        jTextField3 = new javax.swing.JTextField();        jButton5 = new javax.swing.JButton();        jLabel4 = new javax.swing.JLabel();        jLabel5 = new javax.swing.JLabel();        jLabel6 = new javax.swing.JLabel();        jTextField4 = new javax.swing.JTextField();        jButton6 = new javax.swing.JButton();        jButton7 = new javax.swing.JButton();        jLabel7 = new javax.swing.JLabel();        jButton3 = new javax.swing.JButton();        jButton9 = new javax.swing.JButton();        jButton10 = new javax.swing.JButton();        jLabel8 = new javax.swing.JLabel();        jTextField5 = new javax.swing.JTextField();        setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);        jLabel1.setText("\u89e3\u5bc6\u6587\u4ef6:");        jButton1.setText(".......");        jButton1.addActionListener(new java.awt.event.ActionListener() {            public void actionPerformed(java.awt.event.ActionEvent evt) {                jButton1ActionPerformed(evt);            }        });        jLabel2.setText("\u89e3\u5bc6\u6587\u4ef6:");        jButton2.setText(".......");        jButton2.addActionListener(new java.awt.event.ActionListener() {            public void actionPerformed(java.awt.event.ActionEvent evt) {                jButton2ActionPerformed(evt);            }        });        jButton4.setText(".......");        jButton4.addActionListener(new java.awt.event.ActionListener() {            public void actionPerformed(java.awt.event.ActionEvent evt) {                jButton4ActionPerformed(evt);            }        });        jLabel3.setText("\u79c1\u94a5:");        jButton5.setText("\u89e3\u5bc6");        jButton5.addActionListener(new java.awt.event.ActionListener() {            public void actionPerformed(java.awt.event.ActionEvent evt) {                jButton5ActionPerformed(evt);            }        });        jLabel4.setText("\u516c\u94a5\u52a0\u5bc6\u7b97\u6cd5\u89e3\u5bc6(RSA\u7b97\u6cd5)");        jLabel5.setText("\u5bf9\u79f0\u52a0\u5bc6\u7b97\u6cd5\u89e3\u5bc6");        jLabel6.setText("\u5bc6\u94a5:");        jButton6.setText(".......");        jButton6.addActionListener(new java.awt.event.ActionListener() {            public void actionPerformed(java.awt.event.ActionEvent evt) {                jButton6ActionPerformed(evt);            }        });        jButton7.setText("\u89e3\u5bc6");        jButton7.addActionListener(new java.awt.event.ActionListener() {            public void actionPerformed(java.awt.event.ActionEvent evt) {                jButton7ActionPerformed(evt);            }        });        jLabel7.setText("\u9a8c\u8bc1\u6570\u5b57\u7b7e\u540d");        jButton3.setText("\u8ba1\u7b97\u6d88\u606f\u6458\u8981");        jButton3.addActionListener(new java.awt.event.ActionListener() {            public void actionPerformed(java.awt.event.ActionEvent evt) {                jButton3ActionPerformed(evt);            }        });        jButton9.setText(".......");        jButton9.addActionListener(new java.awt.event.ActionListener() {            public void actionPerformed(java.awt.event.ActionEvent evt) {                jButton9ActionPerformed(evt);            }        });        jButton10.setText("\u9a8c\u8bc1\u6570\u5b57\u7b7e\u540d");        jButton10.addActionListener(new java.awt.event.ActionListener() {            public void actionPerformed(java.awt.event.ActionEvent evt) {                jButton10ActionPerformed(evt);            }        });        jLabel8.setText("\u8f93\u5165\u516c\u94a5");        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());        getContentPane().setLayout(layout);        layout.setHorizontalGroup(            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)            .addGroup(layout.createSequentialGroup()                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)                    .addGroup(layout.createSequentialGroup()                        .addContainerGap()                        .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)                            .addComponent(jButton3, javax.swing.GroupLayout.DEFAULT_SIZE, 413, Short.MAX_VALUE)                            .addComponent(jLabel7)                            .addComponent(jButton10, javax.swing.GroupLayout.DEFAULT_SIZE, 413, Short.MAX_VALUE)                            .addGroup(layout.createSequentialGroup()                                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)                                    .addGroup(layout.createSequentialGroup()                                        .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)                                            .addGroup(javax.swing.GroupLayout.Alignment.LEADING, layout.createSequentialGroup()                                                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)                                                    .addComponent(jLabel2)                                                    .addComponent(jLabel6))                                                .addGap(15, 15, 15)                                                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)                                                    .addComponent(jTextField4, javax.swing.GroupLayout.DEFAULT_SIZE, 238, Short.MAX_VALUE)                                                    .addComponent(jTextField2, javax.swing.GroupLayout.DEFAULT_SIZE, 238, Short.MAX_VALUE)))                                            .addGroup(javax.swing.GroupLayout.Alignment.LEADING, layout.createSequentialGroup()                                                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)                                                    .addComponent(jLabel3)                                                    .addComponent(jLabel1))                                                .addGap(9, 9, 9)                                                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)                                                    .addComponent(jTextField1, javax.swing.GroupLayout.DEFAULT_SIZE, 244, Short.MAX_VALUE)                                                    .addComponent(jTextField3, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, 244, Short.MAX_VALUE))))                                        .addGap(25, 25, 25))                                    .addGroup(layout.createSequentialGroup()                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)                                        .addComponent(jLabel8)                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)                                        .addComponent(jTextField5, javax.swing.GroupLayout.PREFERRED_SIZE, 275, javax.swing.GroupLayout.PREFERRED_SIZE)                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED))                                    .addGroup(layout.createSequentialGroup()                                        .addComponent(jLabel5, javax.swing.GroupLayout.PREFERRED_SIZE, 209, javax.swing.GroupLayout.PREFERRED_SIZE)                                        .addGap(123, 123, 123)))                                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)                                    .addComponent(jButton5, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, 81, Short.MAX_VALUE)                                    .addGroup(layout.createSequentialGroup()                                        .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)                                            .addComponent(jButton9)                                            .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)                                                .addComponent(jButton6, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)                                                .addComponent(jButton2, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)                                                .addComponent(jButton7, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)))                                        .addGap(6, 6, 6))                                    .addComponent(jButton4, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, 81, Short.MAX_VALUE)                                    .addGroup(layout.createSequentialGroup()                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)                                        .addComponent(jButton1, javax.swing.GroupLayout.DEFAULT_SIZE, 81, Short.MAX_VALUE))))))                    .addComponent(jLabel4, javax.swing.GroupLayout.PREFERRED_SIZE, 164, javax.swing.GroupLayout.PREFERRED_SIZE))                .addContainerGap())        );        layout.setVerticalGroup(            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)            .addGroup(layout.createSequentialGroup()                .addContainerGap()                .addComponent(jLabel4)                .addGap(21, 21, 21)                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)                    .addComponent(jLabel1)                    .addComponent(jButton1)                    .addComponent(jTextField1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)                    .addGroup(layout.createSequentialGroup()                        .addGap(33, 33, 33)                        .addComponent(jLabel5, javax.swing.GroupLayout.PREFERRED_SIZE, 35, javax.swing.GroupLayout.PREFERRED_SIZE))                    .addGroup(layout.createSequentialGroup()                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)                        .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)                            .addComponent(jButton4)                            .addComponent(jTextField3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)                            .addComponent(jLabel3))                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)                        .addComponent(jButton5)))                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)                    .addComponent(jTextField2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)                    .addComponent(jButton2)                    .addComponent(jLabel2))                .addGap(19, 19, 19)                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)                    .addComponent(jTextField4, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)                    .addComponent(jButton6)                    .addComponent(jLabel6))                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)                .addComponent(jButton7)                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)                    .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()                        .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)                            .addComponent(jButton9)                            .addComponent(jTextField5, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED))                    .addGroup(layout.createSequentialGroup()                        .addComponent(jLabel7)                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 38, Short.MAX_VALUE)                        .addComponent(jLabel8)                        .addGap(14, 14, 14)))                .addComponent(jButton3)                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -