diff --git a/PublicKeyDecryption/KeyGen_Top.v b/PublicKeyDecryption/KeyGen_Top.v index a05fb57..0b493ed 100644 --- a/PublicKeyDecryption/KeyGen_Top.v +++ b/PublicKeyDecryption/KeyGen_Top.v @@ -20,10 +20,11 @@ ////////////////////////////////////////////////////////////////////////////////// -module KeyGen_Top(input clk,input [1:0] en, output [11:0] q, p, output [23:0] etemp, n,totient,d, output complete); +module KeyGen_Top(input clk,input en, output [11:0] q, p, output [23:0] etemp, n,totient,d, output complete); wire rst; wire [23:0]etempyo; - RNG rng_0(.clk(clk),.q(q), .p(p),.e(etempyo),.n(n),.totient(totient),.en(en), .flag(rst)); +wire privKeyEN; + RNG rng_0(.clk(clk),.q(q), .p(p),.e(etempyo),.n(n),.totient(totient),.en(en), .flag(privKeyEN)); privatekeyGen pvg_0(.clk(clk),.e(etempyo), .totient(totient), .d(d), .rst(rst),.complete(complete)); assign etemp = etempyo; endmodule \ No newline at end of file diff --git a/PublicKeyDecryption/PublicKeyDecryption.gise b/PublicKeyDecryption/PublicKeyDecryption.gise index 2d8ffd0..b646c81 100644 --- a/PublicKeyDecryption/PublicKeyDecryption.gise +++ b/PublicKeyDecryption/PublicKeyDecryption.gise @@ -58,6 +58,10 @@ + + + + @@ -88,6 +92,11 @@ + + + + + @@ -106,7 +115,11 @@ + + + + @@ -118,6 +131,8 @@ + + @@ -156,7 +171,9 @@ + + diff --git a/PublicKeyDecryption/PublicKeyDecryption.xise b/PublicKeyDecryption/PublicKeyDecryption.xise index a27efc0..0cf889f 100644 --- a/PublicKeyDecryption/PublicKeyDecryption.xise +++ b/PublicKeyDecryption/PublicKeyDecryption.xise @@ -319,8 +319,8 @@ - - + + @@ -338,7 +338,7 @@ - + diff --git a/PublicKeyDecryption/RNG.v b/PublicKeyDecryption/RNG.v index 4fcf492..cffc586 100644 --- a/PublicKeyDecryption/RNG.v +++ b/PublicKeyDecryption/RNG.v @@ -19,8 +19,15 @@ // Additional Comments: //works ////////////////////////////////////////////////////////////////////////////////// -module RNG(input clk, input [1:0] en, input none, - output reg[11:0]q, p,output reg[23:0] e, output reg [23:0] totient, output reg [23:0] n, output reg flag); +module RNG( + input clk, + input en, + input none, + output reg[11:0]q, p, + output reg[23:0] e, + output reg [23:0] totient, + output reg [23:0] n, + output reg flag); reg [11:0] prime [6:0]; reg [11:0] prime1 [6:0]; reg [11:0] prime2 [6:0]; @@ -69,6 +76,6 @@ always @(posedge clk) begin e <= e_temp; totient <= (p-1'b1)*(q-1'b1); n <= (p*q); - flag <= 0; + flag <= 1; end endmodule \ No newline at end of file diff --git a/PublicKeyDecryption/_xmsgs/pn_parser.xmsgs b/PublicKeyDecryption/_xmsgs/pn_parser.xmsgs index 13c4dc8..c8eb5d2 100644 --- a/PublicKeyDecryption/_xmsgs/pn_parser.xmsgs +++ b/PublicKeyDecryption/_xmsgs/pn_parser.xmsgs @@ -8,7 +8,13 @@ -Analyzing Verilog file "/home/ise/VMShare/Public-Key-Decryption/PublicKeyDecryption/trueTop_tb.v" into library work +Analyzing Verilog file "/home/ise/VMShare/Public-Key-Decryption/PublicKeyDecryption/privatekeyGen.v" into library work + + +"/home/ise/VMShare/Public-Key-Decryption/PublicKeyDecryption/privatekeyGen.v" Line 79. Syntax error near "if". + + +"/home/ise/VMShare/Public-Key-Decryption/PublicKeyDecryption/privatekeyGen.v" Line 132. Syntax error near "end". diff --git a/PublicKeyDecryption/iseconfig/PublicKeyDecryption.projectmgr b/PublicKeyDecryption/iseconfig/PublicKeyDecryption.projectmgr index 4a85fbe..d2aabce 100644 --- a/PublicKeyDecryption/iseconfig/PublicKeyDecryption.projectmgr +++ b/PublicKeyDecryption/iseconfig/PublicKeyDecryption.projectmgr @@ -11,13 +11,13 @@ /RNG_tb |home|ise|XIlinxShare|Public-Key Decryption|PublicKeyDecryption|RNG_tb.v - trueTop (/home/ise/VMShare/Public-Key-Decryption/PublicKeyDecryption/trueTop.v) + pvg_0 - privatekeyGen (/home/ise/VMShare/Public-Key-Decryption/PublicKeyDecryption/privatekeyGen.v) 0 0 000000ff0000000000000001000000010000000000000000000000000000000002020000000100000001000000640000017a000000020000000000000000000000000200000064ffffffff0000008100000003000000020000017a0000000100000003000000000000000100000003 true - trueTop (/home/ise/VMShare/Public-Key-Decryption/PublicKeyDecryption/trueTop.v) + pvg_0 - privatekeyGen (/home/ise/VMShare/Public-Key-Decryption/PublicKeyDecryption/privatekeyGen.v) @@ -66,13 +66,13 @@ User Constraints - Synthesize - XST + 0 0 - 000000ff000000000000000100000001000000000000000000000000000000000000000000000000e5000000010000000100000000000000000000000064ffffffff000000810000000000000001000000e50000000100000000 + 000000ff000000000000000100000001000000000000000000000000000000000000000000000000f4000000010000000100000000000000000000000064ffffffff000000810000000000000001000000f40000000100000000 false - Synthesize - XST + @@ -88,13 +88,13 @@ /privateKeyGen_tb |home|ise|XIlinxShare|Public-Key Decryption|PublicKeyDecryption|privateKeyGen_tb.v - trueTop_tb (/home/ise/VMShare/Public-Key-Decryption/PublicKeyDecryption/trueTop_tb.v) + kG1 - KeyGen_Top (/home/ise/VMShare/Public-Key-Decryption/PublicKeyDecryption/KeyGen_Top.v) 3 0 000000ff0000000000000001000000010000000000000000000000000000000002020000000100000001000000640000018e000000020000000000000000000000000200000064ffffffff0000008100000003000000020000018e0000000100000003000000000000000100000003 true - trueTop_tb (/home/ise/VMShare/Public-Key-Decryption/PublicKeyDecryption/trueTop_tb.v) + kG1 - KeyGen_Top (/home/ise/VMShare/Public-Key-Decryption/PublicKeyDecryption/KeyGen_Top.v) @@ -115,12 +115,12 @@ 1 - Simulate Behavioral Model + 0 0 000000ff000000000000000100000001000000000000000000000000000000000000000000000000f4000000010000000100000000000000000000000064ffffffff000000810000000000000001000000f40000000100000000 false - Simulate Behavioral Model + diff --git a/PublicKeyDecryption/iseconfig/trueTop.xreport b/PublicKeyDecryption/iseconfig/trueTop.xreport index f04f0aa..03885c7 100644 --- a/PublicKeyDecryption/iseconfig/trueTop.xreport +++ b/PublicKeyDecryption/iseconfig/trueTop.xreport @@ -1,7 +1,7 @@
- 2018-12-12T05:39:59 + 2018-12-12T07:01:06 trueTop 2018-12-12T05:38:35 /home/ise/VMShare/Public-Key-Decryption/PublicKeyDecryption/iseconfig/trueTop.xreport diff --git a/PublicKeyDecryption/privateKeyGen.v b/PublicKeyDecryption/privateKeyGen.v index fde81cc..4da4f9d 100644 --- a/PublicKeyDecryption/privateKeyGen.v +++ b/PublicKeyDecryption/privateKeyGen.v @@ -42,7 +42,7 @@ module privatekeyGen#(parameter INPUTSIZE = 24)( input clk, input rst, - + input pkEnable, input [INPUTSIZE-1:0]e, input [INPUTSIZE-1:0]totient, @@ -76,7 +76,7 @@ reg [1:0]state = loopCheck; always@(posedge clk) begin case(state) - +if(pkEnable == 1) begin loopCheck: begin if(mod == 1)begin @@ -128,6 +128,6 @@ reg [1:0]state = loopCheck; default: begin d = 0; complete = 0; end endcase - +end end endmodule \ No newline at end of file diff --git a/PublicKeyDecryption/trueTop.v b/PublicKeyDecryption/trueTop.v index d72afc6..bdc3d7d 100644 --- a/PublicKeyDecryption/trueTop.v +++ b/PublicKeyDecryption/trueTop.v @@ -20,11 +20,11 @@ ////////////////////////////////////////////////////////////////////////////////// -module trueTop(input btnC, input [15:0] sw, input btnU, input btnD, input clk, output [15:0] led); +module trueTop(input btnC, input [11:0] sw, input btnU, input btnD, input clk, output [11:0] led); wire [11:0] p,q; reg [1:0] en; wire [23:0] e, n, totient, d; -reg [1:0] state; +//reg [1:0] state; reg [1:0] rst; reg [1:0] finished; reg [11:0] message; diff --git a/PublicKeyDecryption/trueTop_summary.html b/PublicKeyDecryption/trueTop_summary.html index a028b62..b4b6300 100644 --- a/PublicKeyDecryption/trueTop_summary.html +++ b/PublicKeyDecryption/trueTop_summary.html @@ -2,12 +2,12 @@ - + - + @@ -105,9 +105,9 @@  
trueTop Project Status (12/12/2018 - 06:05:54)
trueTop Project Status (12/12/2018 - 05:38:35)
Project File: PublicKeyDecryption.xise Parser Errors: No Errors X 2 Errors
Module Name:
- +
Secondary Reports [-]
Report NameStatusGenerated
ISIM Simulator LogOut of DateWed Dec 12 06:03:27 2018
ISIM Simulator LogOut of DateWed Dec 12 06:14:19 2018
-
Date Generated: 12/12/2018 - 06:05:54
+
Date Generated: 12/12/2018 - 07:49:37
\ No newline at end of file