Package sun.misc

Examples of sun.misc.HexDumpEncoder


    caddrBuf.append("clientAddresses[" + i + "] = " +
         clientAddresses[i].toString());
      }
  }
  return ("Ticket (hex) = " + "\n" +
     (new HexDumpEncoder()).encodeBuffer(asn1Encoding) + "\n" +
    "Client Principal = " + client.toString() + "\n" +
    "Server Principal = " + server.toString() + "\n" +
    "Session Key = " + sessionKey.toString() + "\n" +
    "Forwardable Ticket " + flags[FORWARDABLE_TICKET_FLAG] + "\n" +
    "Forwarded Ticket " + flags[FORWARDED_TICKET_FLAG] + "\n" +
View Full Code Here


     *         <code>PolicyQualifierInfo</code>
     */
    public String toString() {
  if (pqiString != null)
      return pqiString;
        HexDumpEncoder enc = new HexDumpEncoder();
        StringBuffer sb = new StringBuffer();
        sb.append("PolicyQualifierInfo: [\n");
        sb.append("  qualifierID: " + mId + "\n");
        sb.append("  qualifier: " +
      (mData == null ? "null" : enc.encodeBuffer(mData)) + "\n");
        sb.append("]");
  pqiString = sb.toString();
  return pqiString;
    }
View Full Code Here

                sb.append("    type " + list.get(0) +
                          ", name " + list.get(1) + "\n");
            }
        }
        if (subjectKeyID != null) {
            HexDumpEncoder enc = new HexDumpEncoder();
            sb.append("  Subject Key Identifier: " +
                      enc.encodeBuffer(subjectKeyID) + "\n");
        }
        if (authorityKeyID != null) {
            HexDumpEncoder enc = new HexDumpEncoder();
            sb.append("  Authority Key Identifier: " +
                      enc.encodeBuffer(authorityKeyID) + "\n");
        }
        if (certificateValid != null) {
            sb.append("  Certificate Valid: " +
                      certificateValid.toString() + "\n");
        }
View Full Code Here

     *         <code>PolicyQualifierInfo</code>
     */
    public String toString() {
        if (pqiString != null)
            return pqiString;
        HexDumpEncoder enc = new HexDumpEncoder();
        StringBuffer sb = new StringBuffer();
        sb.append("PolicyQualifierInfo: [\n");
        sb.append("  qualifierID: " + mId + "\n");
        sb.append("  qualifier: " +
            (mData == null ? "null" : enc.encodeBuffer(mData)) + "\n");
        sb.append("]");
        pqiString = sb.toString();
        return pqiString;
    }
View Full Code Here

                caddrBuf.append("clientAddresses[" + i + "] = " +
                                 clientAddresses[i].toString());
            }
        }
        return ("Ticket (hex) = " + "\n" +
                 (new HexDumpEncoder()).encodeBuffer(asn1Encoding) + "\n" +
                "Client Principal = " + client.toString() + "\n" +
                "Server Principal = " + server.toString() + "\n" +
                "Session Key = " + sessionKey.toString() + "\n" +
                "Forwardable Ticket " + flags[FORWARDABLE_TICKET_FLAG] + "\n" +
                "Forwarded Ticket " + flags[FORWARDED_TICKET_FLAG] + "\n" +
View Full Code Here

                }
                builder.destroy();

                if (debug) {
                    System.out.println("principal is " + principal);
                    HexDumpEncoder hd = new HexDumpEncoder();
                    if (ktab != null) {
                        System.out.println("Will use keytab");
                    } else if (storeKey) {
                        for (int i = 0; i < encKeys.length; i++) {
                            System.out.println("EncryptionKey: keyType=" +
                                encKeys[i].getEType() +
                                " keyBytes (hex dump)=" +
                                hd.encodeBuffer(encKeys[i].getBytes()));
                        }
                    }
                }

                // we should hava a non-null cred
View Full Code Here

            throw new IOException(ae.getMessage());
        }
    }

    public String toString() {
        HexDumpEncoder hd = new HexDumpEncoder();
        return "EncryptionKey: keyType=" + keyType
                          + " keyBytes (hex dump)="
                          + (keyBytes == null || keyBytes.length == 0 ?
                             " Empty Key" :
                             '\n' + hd.encodeBuffer(keyBytes)
                          + '\n');


    }
View Full Code Here

    * @param baToConvert
    * @return hexdump string
    */
   public static String prettyPrintHex(byte[] baToConvert) {

      HexDumpEncoder hde = new HexDumpEncoder();

      return hde.encodeBuffer(baToConvert);
   }
View Full Code Here

    * @param baToConvert
    * @return hexdump string
    */
   public static String prettyPrintHex(byte[] baToConvert) {

      HexDumpEncoder hde = new HexDumpEncoder();

      return hde.encodeBuffer(baToConvert);
   }
View Full Code Here

     */
    public String toString() {
        String LINE_SEP = System.getProperty("line.separator");

        String ivString = LINE_SEP + "    iv:" + LINE_SEP + "[";
        HexDumpEncoder encoder = new HexDumpEncoder();
        ivString += encoder.encodeBuffer(this.iv);
        ivString += "]" + LINE_SEP;
        return ivString;
    }
View Full Code Here

TOP

Related Classes of sun.misc.HexDumpEncoder

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.