src/java.security.jgss/share/classes/sun/security/jgss/krb5/AcceptSecContextToken.java
changeset 51398 3c389a284345
parent 47216 71c04702a3d5
equal deleted inserted replaced
51397:c9150700bbd0 51398:3c389a284345
     1 /*
     1 /*
     2  * Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved.
     2  * Copyright (c) 2000, 2018, Oracle and/or its affiliates. All rights reserved.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     4  *
     4  *
     5  * This code is free software; you can redistribute it and/or modify it
     5  * This code is free software; you can redistribute it and/or modify it
     6  * under the terms of the GNU General Public License version 2 only, as
     6  * under the terms of the GNU General Public License version 2 only, as
     7  * published by the Free Software Foundation.  Oracle designates this
     7  * published by the Free Software Foundation.  Oracle designates this
    26 package sun.security.jgss.krb5;
    26 package sun.security.jgss.krb5;
    27 
    27 
    28 import org.ietf.jgss.*;
    28 import org.ietf.jgss.*;
    29 import java.io.InputStream;
    29 import java.io.InputStream;
    30 import java.io.IOException;
    30 import java.io.IOException;
    31 import java.security.AccessController;
       
    32 
    31 
    33 import sun.security.action.GetBooleanAction;
    32 import sun.security.action.GetBooleanAction;
    34 import sun.security.krb5.*;
    33 import sun.security.krb5.*;
    35 
    34 
    36 class AcceptSecContextToken extends InitialToken {
    35 class AcceptSecContextToken extends InitialToken {
    43      */
    42      */
    44     public AcceptSecContextToken(Krb5Context context,
    43     public AcceptSecContextToken(Krb5Context context,
    45                                  KrbApReq apReq)
    44                                  KrbApReq apReq)
    46         throws KrbException, IOException, GSSException {
    45         throws KrbException, IOException, GSSException {
    47 
    46 
    48         boolean useSubkey = AccessController.doPrivileged(
    47         boolean useSubkey = GetBooleanAction
    49                 new GetBooleanAction("sun.security.krb5.acceptor.subkey"));
    48                 .privilegedGetProperty("sun.security.krb5.acceptor.subkey");
    50 
    49 
    51         boolean useSequenceNumber = true;
    50         boolean useSequenceNumber = true;
    52 
    51 
    53         EncryptionKey subKey = null;
    52         EncryptionKey subKey = null;
    54         if (useSubkey) {
    53         if (useSubkey) {