jira的破解:
 1 import java.io.*;
import java.io.*;
 2 import java.security.KeyFactory;
import java.security.KeyFactory;
 3 import java.security.Signature;
import java.security.Signature;
 4 import java.security.spec.PKCS8EncodedKeySpec;
import java.security.spec.PKCS8EncodedKeySpec;
 5
 6 import com.atlassian.license.LicensePair;
import com.atlassian.license.LicensePair;
 7
 8
 public class keygen
public class keygen  {
{
 9
10
 public keygen()
    public keygen()  {
{
11 }
    }
12
13
 public static void main(String args[]) throws IOException
    public static void main(String args[]) throws IOException  {
{
14
 try
        try  {
{
15 long l = 267L;
            long l = 267L;
16 long l1 = System.currentTimeMillis();
            long l1 = System.currentTimeMillis();
17 long l2 = System.currentTimeMillis();
            long l2 = System.currentTimeMillis();
18 String s = "";
            String s = "";
19 System.out.println("Keygen for JIRA Enterprise Edition.");
            System.out.println("Keygen for JIRA Enterprise Edition.");
20 System.out.print("created by mydaj[ROR].");
            System.out.print("created by mydaj[ROR].");
21
 do
            do  {
{
22 System.out.print("\nEnter your organization name: ");
                System.out.print("\nEnter your organization name: ");
23 for (int i = System.in.read(); i != 10 && i != 13; i = System.in
                for (int i = System.in.read(); i != 10 && i != 13; i = System.in
24 .read())
                        .read())
25 s = s + (char) i;
                    s = s + (char) i;
26
27 } while (s == "");
            } while (s == "");
28
 try
            try  {
{
29 PKCS8EncodedKeySpec pkcs8encodedkeyspec = new PKCS8EncodedKeySpec(
                PKCS8EncodedKeySpec pkcs8encodedkeyspec = new PKCS8EncodedKeySpec(
30 EncodedPrvKey);
                        EncodedPrvKey);
31 KeyFactory keyfactory = KeyFactory.getInstance("DSA", "SUN");
                KeyFactory keyfactory = KeyFactory.getInstance("DSA", "SUN");
32 java.security.PrivateKey privatekey = keyfactory
                java.security.PrivateKey privatekey = keyfactory
33 .generatePrivate(pkcs8encodedkeyspec);
                        .generatePrivate(pkcs8encodedkeyspec);
34 String s1 = Long.toString(l, 10);
                String s1 = Long.toString(l, 10);
35 s1 = s1 + "^^";
                s1 = s1 + "^^";
36 s1 = s1 + Long.toString(l1, 10);
                s1 = s1 + Long.toString(l1, 10);
37 s1 = s1 + "^^";
                s1 = s1 + "^^";
38 s1 = s1 + Long.toString(l2, 10);
                s1 = s1 + Long.toString(l2, 10);
39 s1 = s1 + "^^";
                s1 = s1 + "^^";
40 s1 = s1 + s;
                s1 = s1 + s;
41 byte abyte0[] = s1.getBytes();
                byte abyte0[] = s1.getBytes();
42 Signature signature = Signature.getInstance("SHA1withDSA");
                Signature signature = Signature.getInstance("SHA1withDSA");
43 signature.initSign(privatekey);
                signature.initSign(privatekey);
44 signature.update(abyte0);
                signature.update(abyte0);
45 byte abyte1[] = signature.sign();
                byte abyte1[] = signature.sign();
46 LicensePair licensepair = null;
                LicensePair licensepair = null;
47
 try
                try  {
{
48 licensepair = new LicensePair(abyte0, abyte1);
                    licensepair = new LicensePair(abyte0, abyte1);
49
 } catch (Exception exception1)
                } catch (Exception exception1)  {
{
50 exception1.printStackTrace();
                    exception1.printStackTrace();
51 }
                }
52 System.out.println(s1);
                System.out.println(s1);
53 System.out.println("Your license key is: ");
                System.out.println("Your license key is: ");
54 System.out.println(licensepair.toString());
                System.out.println(licensepair.toString());
55
 } catch (Exception exception)
            } catch (Exception exception)  {
{
56 exception.printStackTrace();
                exception.printStackTrace();
57 }
            }
58
 } catch (IOException ioexception)
        } catch (IOException ioexception)  {
{
59 }
        }
60 }
    }
61
62
 static byte EncodedPrvKey[] =
    static byte EncodedPrvKey[] =  { 48, -126, 1, 75, 2, 1, 0, 48, -126, 1, 44,
{ 48, -126, 1, 75, 2, 1, 0, 48, -126, 1, 44,
63 6, 7, 42, -122, 72, -50, 56, 4, 1, 48, -126, 1, 31, 2, -127, -127,
            6, 7, 42, -122, 72, -50, 56, 4, 1, 48, -126, 1, 31, 2, -127, -127,
64 0, -3, 127, 83, -127, 29, 117, 18, 41, 82, -33, 74, -100, 46, -20,
            0, -3, 127, 83, -127, 29, 117, 18, 41, 82, -33, 74, -100, 46, -20,
65 -28, -25, -10, 17, -73, 82, 60, -17, 68, 0, -61, 30, 63, -128, -74,
            -28, -25, -10, 17, -73, 82, 60, -17, 68, 0, -61, 30, 63, -128, -74,
66 81, 38, 105, 69, 93, 64, 34, 81, -5, 89, 61, -115, 88, -6, -65,
            81, 38, 105, 69, 93, 64, 34, 81, -5, 89, 61, -115, 88, -6, -65,
67 -59, -11, -70, 48, -10, -53, -101, 85, 108, -41, -127, 59, -128,
            -59, -11, -70, 48, -10, -53, -101, 85, 108, -41, -127, 59, -128,
68 29, 52, 111, -14, 102, 96, -73, 107, -103, 80, -91, -92, -97, -97,
            29, 52, 111, -14, 102, 96, -73, 107, -103, 80, -91, -92, -97, -97,
69 -24, 4, 123, 16, 34, -62, 79, -69, -87, -41, -2, -73, -58, 27, -8,
            -24, 4, 123, 16, 34, -62, 79, -69, -87, -41, -2, -73, -58, 27, -8,
70 59, 87, -25, -58, -88, -90, 21, 15, 4, -5, -125, -10, -45, -59, 30,
            59, 87, -25, -58, -88, -90, 21, 15, 4, -5, -125, -10, -45, -59, 30,
71 -61, 2, 53, 84, 19, 90, 22, -111, 50, -10, 117, -13, -82, 43, 97,
            -61, 2, 53, 84, 19, 90, 22, -111, 50, -10, 117, -13, -82, 43, 97,
72 -41, 42, -17, -14, 34, 3, 25, -99, -47, 72, 1, -57, 2, 21, 0, -105,
            -41, 42, -17, -14, 34, 3, 25, -99, -47, 72, 1, -57, 2, 21, 0, -105,
73 96, 80, -113, 21, 35, 11, -52, -78, -110, -71, -126, -94, -21,
            96, 80, -113, 21, 35, 11, -52, -78, -110, -71, -126, -94, -21,
74 -124, 11, -16, 88, 28, -11, 2, -127, -127, 0, -9, -31, -96, -123,
            -124, 11, -16, 88, 28, -11, 2, -127, -127, 0, -9, -31, -96, -123,
75 -42, -101, 61, -34, -53, -68, -85, 92, 54, -72, 87, -71, 121, -108,
            -42, -101, 61, -34, -53, -68, -85, 92, 54, -72, 87, -71, 121, -108,
76 -81, -69, -6, 58, -22, -126, -7, 87, 76, 11, 61, 7, -126, 103, 81,
            -81, -69, -6, 58, -22, -126, -7, 87, 76, 11, 61, 7, -126, 103, 81,
77 89, 87, -114, -70, -44, 89, 79, -26, 113, 7, 16, -127, -128, -76,
            89, 87, -114, -70, -44, 89, 79, -26, 113, 7, 16, -127, -128, -76,
78 73, 22, 113, 35, -24, 76, 40, 22, 19, -73, -49, 9, 50, -116, -56,
            73, 22, 113, 35, -24, 76, 40, 22, 19, -73, -49, 9, 50, -116, -56,
79 -90, -31, 60, 22, 122, -117, 84, 124, -115, 40, -32, -93, -82, 30,
            -90, -31, 60, 22, 122, -117, 84, 124, -115, 40, -32, -93, -82, 30,
80 43, -77, -90, 117, -111, 110, -93, 127, 11, -6, 33, 53, 98, -15,
            43, -77, -90, 117, -111, 110, -93, 127, 11, -6, 33, 53, 98, -15,
81 -5, 98, 122, 1, 36, 59, -52, -92, -15, -66, -88, 81, -112, -119,
            -5, 98, 122, 1, 36, 59, -52, -92, -15, -66, -88, 81, -112, -119,
82 -88, -125, -33, -31, 90, -27, -97, 6, -110, -117, 102, 94, -128,
            -88, -125, -33, -31, 90, -27, -97, 6, -110, -117, 102, 94, -128,
83 123, 85, 37, 100, 1, 76, 59, -2, -49, 73, 42, 4, 22, 2, 20, 42, 50,
            123, 85, 37, 100, 1, 76, 59, -2, -49, 73, 42, 4, 22, 2, 20, 42, 50,
84 -88, 30, 125, -37, 118, -50, 20, -82, -63, 0, 8, -36, 106, -9,
            -88, 30, 125, -37, 118, -50, 20, -82, -63, 0, 8, -36, 106, -9,
85 -110, 124, 107, 68 };
            -110, 124, 107, 68 };
86
87 }
}
88
 
	posted on 2007-07-11 15:07 
张氏兄弟 阅读(199) 
评论(0)  编辑  收藏