Advertisement
dev017

pass print (java)

Jul 30th, 2023 (edited)
102
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.51 KB | None | 0 0
  1. import com.sun.security.auth.module.NTSystem;
  2.  
  3. public class NetworkPasswordPrinter {
  4.     public static void main(String[] args) {
  5.         try {
  6.             NTSystem ntSystem = new NTSystem();
  7.             String domain = ntSystem.getDomain();
  8.             String username = ntSystem.getName();
  9.             char[] password = ntSystem.getPassword();
  10.  
  11.             System.out.println("Network Password: " + new String(password));
  12.         } catch (Exception e) {
  13.             e.printStackTrace();
  14.         }
  15.     }
  16. }
  17.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement