jdk/test/sun/security/krb5/auto/ReplayCacheExpunge.java
changeset 41832 15db944958a7
parent 31474 7b79555b8073
equal deleted inserted replaced
41831:2dd91b18195b 41832:15db944958a7
    45         System.setProperty("java.security.krb5.conf", "nothing");
    45         System.setProperty("java.security.krb5.conf", "nothing");
    46 
    46 
    47         int count = Integer.parseInt(args[0]);
    47         int count = Integer.parseInt(args[0]);
    48         ReplayCache cache = ReplayCache.getInstance("dfl:./");
    48         ReplayCache cache = ReplayCache.getInstance("dfl:./");
    49         AuthTimeWithHash a1 =
    49         AuthTimeWithHash a1 =
    50                 new AuthTimeWithHash(client, server, time(-400), 0, hash("1"));
    50                 new AuthTimeWithHash(client, server, time(-400), 0, "HASH", hash("1"));
    51         AuthTimeWithHash a2 =
    51         AuthTimeWithHash a2 =
    52                 new AuthTimeWithHash(client, server, time(0), 0, hash("4"));
    52                 new AuthTimeWithHash(client, server, time(0), 0, "HASH", hash("4"));
    53         KerberosTime now = new KerberosTime(time(0)*1000L);
    53         KerberosTime now = new KerberosTime(time(0)*1000L);
    54         KerberosTime then = new KerberosTime(time(-300)*1000L);
    54         KerberosTime then = new KerberosTime(time(-300)*1000L);
    55 
    55 
    56         // Once upon a time, we added a lot of events
    56         // Once upon a time, we added a lot of events
    57         for (int i=0; i<count; i++) {
    57         for (int i=0; i<count; i++) {
    58             a1 = new AuthTimeWithHash(client, server, time(-400), 0, hash(""));
    58             a1 = new AuthTimeWithHash(client, server, time(-400), 0, "HASH", hash(""));
    59             cache.checkAndStore(then, a1);
    59             cache.checkAndStore(then, a1);
    60         }
    60         }
    61 
    61 
    62         // Now, we add a new one. If some conditions hold, the old ones
    62         // Now, we add a new one. If some conditions hold, the old ones
    63         // will be expunged.
    63         // will be expunged.