Kết quả 1 đến 9 của 9
  1. #1
    Ngày tham gia
    Aug 2015
    Bài viết
    0

    BlackBerry Engineering Screens

    trên tất cả các thiết bị blackberry (os 4.0 hoặc hơn) đều có một màn hình kỹ thuật (escreen ). để kích hoạt màn hình này chung ta phải thông qua một đoạn mã. đoạn mã này được tạo ra từ pin, phiên bản ứng dụng (os), và thời gian hoạt động thực (uptime) trên thiết bị đó.

    các bạn phải kích hoạt màn hình "help me!" (alt+shift+h /...) và gõ nhập trực tiếp đoạn mã được tạo ra từ code bên dưới. các bạn sẽ kích hoạt được màn hình escreen.


    Mã:
    import java.io.bufferedreader;
    import java.io.ioexception;
    import java.io.inputstreamreader;
     
    import java.security.invalidkeyexception;
    import java.security.nosuchalgorithmexception;
    import javax.crypto.mac;
    import javax.crypto.spec.secretkeyspec;
     
     
    public class escreenwizard
    {
            private static final string hmac_key = "up the time stream without a tardis";
         
            private static final string[] duration_key = {
                    "",
                    "hello my baby, hello my honey, hello my rag time gal",
                    "he was a boy, and she was a girl, can i make it any more obvious?",
                    "so am i, still waiting, for this world to stop hating?",
                    "i love myself today, not like yesterday. i'm cool, i'm calm, i'm gonna be okay"};
         
            private static final string[] duration_len = {
                    "1 day",
                    "3 days",
                    "7 days",
                    "15 days",
                    "30 days"};
         
            public static void main(string[] args) throws ioexception, nosuchalgorithmexception, invalidkeyexception
            {
                    bufferedreader console = new bufferedreader(new inputstreamreader(system.in));
                    system.out.println("blackberry engineering screen unlock code generator");
                    system.out.println();
                 
                    // get the data that is used to generate the key
                    system.out.print("app version: ");
                    string appver = console.readline();
                    system.out.print("pin: ");
                    string pin = console.readline();
                    system.out.print("uptime: ");
                    string uptime = console.readline();
                    system.out.println();
                 
                    // generate the hmac-sha1 for all 5 possible codes
                    for (int duration = 0; duration < 5; duration++)
                    {
                            // get an hmac_sha1 key from the raw key bytes
                            secretkeyspec signingkey = new secretkeyspec(hmac_key.getbytes(), "hmacsha1");
                            mac mac = mac.getinstance("hmacsha1");
                            mac.init(signingkey);
         
                            // generate the data
                            stringbuffer buffer = new stringbuffer();
                         
                            buffer.append(pin.tolowercase());
                            buffer.append(appver.tolowercase()); 
                            buffer.append(uptime.tolowercase());
                         
                            buffer.append(duration_key[duration]);
                            string data = buffer.tostring();
                         
                            // compute the hmac on input data bytes
                            byte[] rawhmac = mac.dofinal(data.getbytes());
         
                            system.out.println("unlock code [" + duration_len[duration] + "]: " + makedigeststring(rawhmac).split(" ")[0]);
                    }
            }
         
            private static string makedigeststring(byte[] input)
            {
                    stringbuffer buffer = new stringbuffer();
                    for (int i = 0; i < input.length; i++)
                    {
                            if (i % 4 == 0 && i != 0)
                                    buffer.append(" ");
                            int x = (int)input[i];
                            if (x < 0)
                                    x += 256;
                            if (x < 16)
                                    buffer.append("0");
                            buffer.append(integer.tostring(x, 16));
                    }
                    return buffer.tostring();
            }
    }

  2. #2
    Ngày tham gia
    Aug 2015
    Bài viết
    0
    hix.....vậy làm thế nào code trên c# đây, trong c# hem cóa thấy tụi này:
    import java.security.invalidkeyexception;
    import java.security.nosuchalgorithmexception;
    import javax.crypto.mac;
    import javax.crypto.spec.secretkeyspec;



  3. #3
    Ngày tham gia
    Nov 2015
    Bài viết
    0
    đây là khu vực java mà =)):d

  4. #4
    Ngày tham gia
    Feb 2016
    Bài viết
    0
    gõ trực tíêp trên bb cả 1 đoạn dài thế kia cơ á

  5. #5
    Ngày tham gia
    Apr 2016
    Bài viết
    0
    Trích dẫn Gửi bởi nguyen viet xuan
    gõ trực tíêp trên bb cả 1 đoạn dài thế kia cơ á
    gõ nhiêu đó chết ừ....

  6. #6
    Ngày tham gia
    Aug 2015
    Bài viết
    0
    Trích dẫn Gửi bởi nguyen viet xuan
    gõ trực tíêp trên bb cả 1 đoạn dài thế kia cơ á
    đoạn code trên là để tạo mã vào escreen thui mà, chạy đoạn code đó là ra :d

  7. #7
    Ngày tham gia
    Jan 2016
    Bài viết
    0
    anh nào pro cài cho em cái đó được không? em mới tập tành chơi thôi







    bánmáy nước nóng aristonnè |zipponè và các phụ kiên khác nhưbao da zippo,bật lửa zippo

  8. #8
    Ngày tham gia
    Aug 2015
    Bài viết
    0
    sao mình bấm alt+shift+h trên 9900 phát nó vào thẳng cái màn hình escreen luôn là sao nhờ y_y

  9. #9
    Ngày tham gia
    Aug 2015
    Bài viết
    0
    sao mình làm theo hướng dẫn của các bạn mà lại không được chứ nhỉ

Quyền viết bài

  • Bạn Không thể gửi Chủ đề mới
  • Bạn Không thể Gửi trả lời
  • Bạn Không thể Gửi file đính kèm
  • Bạn Không thể Sửa bài viết của mình
  •