nus-yam/ex-repair huggingface dataset:
Program: 79836
Project: 79836
Buggy source:
@Override public BearerToken verify(BearerToken token) throws OAuthProblemException {
  Reference reference=new Reference(validationServerRef);
  reference.addQueryParameter(OAuth2Constants.Params.ACCESS_TOKEN,token.getTokenID());
  Client client=new Client(new Context(),Protocol.HTTP);
  ClientResource clientResource=new ClientResource(reference.toUri());
  clientResource.setNext(client);
  clientResource.get();
  try {
    Response response=clientResource.getResponse();
    Map remoteToken=BearerTokenExtractor.extractToken(response);
    Object o=remoteToken.get(OAuth2Constants.Token.OAUTH_ACCESS_TOKEN);
    if (o != null) {
      return (BearerToken)tokenStore.readAccessToken(o.toString());
    }
    return null;
  }
 catch (  OAuthProblemException e) {
    OAuth2Utils.DEBUG.error("String_Node_Str",e);
    throw e;
  }
catch (  ResourceException e) {
    OAuth2Utils.DEBUG.error("String_Node_Str",e);
    throw OAuthProblemException.OAuthError.ACCESS_DENIED.handle(null,e.getMessage());
  }
}

Fixed version (ground truth):
@Override public BearerToken verify(BearerToken token) throws OAuthProblemException {
  Reference reference=new Reference(validationServerRef);
  reference.addQueryParameter(OAuth2Constants.Params.ACCESS_TOKEN,token.getTokenID());
  Client client=new Client(new Context(),Protocol.HTTP);
  ClientResource clientResource=new ClientResource(reference.toUri());
  clientResource.setNext(client);
  clientResource.get();
  try {
    Response response=clientResource.getResponse();
    Map remoteToken=BearerTokenExtractor.extractToken(response);
    Object o=remoteToken.get(OAuth2Constants.Token.OAUTH_ACCESS_TOKEN);
    if (o != null) {
      return (BearerToken)tokenStore.readAccessToken(o.toString());
    }
    return null;
  }
 catch (  OAuthProblemException e) {
    OAuth2Utils.DEBUG.error("String_Node_Str",e);
    throw e;
  }
catch (  ResourceException e) {
    OAuth2Utils.DEBUG.error("String_Node_Str",e);
    throw OAuthProblemException.OAuthError.ACCESS_DENIED.handle(null,e.getMessage());
  }
 finally {
    if (client != null) {
      try {
        client.stop();
      }
 catch (      Exception e) {
        OAuth2Utils.DEBUG.error("String_Node_Str" + "String_Node_Str",e);
      }
    }
  }
}
Program: 79838
Project: 79838
Buggy source:
public OpenSSOPrivilege(){
  super();
  policyMonitor=InjectorHolder.getInstance(PolicyMonitor.class);
}

Fixed version (ground truth):
public OpenSSOPrivilege(){
  super();
  if (isServerMode()) {
    policyMonitor=InjectorHolder.getInstance(PolicyMonitor.class);
  }
 else {
    policyMonitor=null;
  }
}
Program: 79839
Project: 79839
Buggy source:
/** 
 * Constructor to create an evaluator the default service type.
 * @param subject Subject who credential is used for performing the evaluation.
 * @throws EntitlementException if any other abnormal condition occured.
 */
public Evaluator(Subject subject) throws EntitlementException {
  adminSubject=subject;
  policyMonitor=InjectorHolder.getInstance(PolicyMonitor.class);
  configWrapper=new EntitlementConfigurationWrapper();
}

Fixed version (ground truth):
/** 
 * Constructor to create an evaluator the default service type.
 * @param subject Subject who credential is used for performing the evaluation.
 * @throws EntitlementException if any other abnormal condition occured.
 */
public Evaluator(Subject subject) throws EntitlementException {
  adminSubject=subject;
  policyMonitor=getPolicyMonitor();
  configWrapper=new EntitlementConfigurationWrapper();
}
Program: 79840
Project: 79840
Buggy source:
/** 
 * eliminates the null path (consecutive delimiters) from the resource 
 */
private String purgeNullPath(String res){
  if ((res == null) || (res.length() == 0)) {
    return "String_Node_Str";
  }
  boolean preceedingDelimiter=false;
  int len=res.length();
  char[] oldchars=res.toCharArray();
  char[] newchars=new char[len];
  int i=0;
  int j=0;
  while (i < len) {
    if (oldchars[i] == delimiter.charAt(0)) {
      if (!preceedingDelimiter) {
        newchars[j++]=oldchars[i++];
        preceedingDelimiter=true;
      }
 else {
        i++;
      }
    }
 else {
      newchars[j++]=oldchars[i++];
      preceedingDelimiter=false;
    }
  }
  if (preceedingDelimiter) {
    j--;
  }
  return String.valueOf(newchars,0,j);
}

Fixed version (ground truth):
/** 
 * eliminates the null path (consecutive delimiters) from the resource 
 */
private String purgeNullPath(String res){
  if ((res == null) || (res.length() == 0)) {
    return "String_Node_Str";
  }
  boolean preceedingDelimiter=false;
  int len=res.length();
  char[] oldchars=res.toCharArray();
  char[] newchars=new char[len];
  int i=0;
  int j=0;
  while (i < len) {
    if (oldchars[i] == delimiter.charAt(0)) {
      if (!preceedingDelimiter) {
        newchars[j++]=oldchars[i++];
        preceedingDelimiter=true;
      }
 else {
        i++;
      }
    }
 else {
      newchars[j++]=oldchars[i++];
      preceedingDelimiter=false;
    }
  }
  return String.valueOf(newchars,0,j);
}
Program: 79841
Project: 79841
Buggy source:
/** 
 * eliminates the null path (consecutive delimiters) from the resource 
 */
private String purgeNullPath(String res){
  if ((res == null) || (res.length() == 0)) {
    return "String_Node_Str";
  }
  boolean preceedingDelimiter=false;
  int len=res.length();
  char[] oldchars=res.toCharArray();
  char[] newchars=new char[len];
  int i=0;
  int j=0;
  while (i < len) {
    if (oldchars[i] == delimiter.charAt(0)) {
      if (!preceedingDelimiter) {
        newchars[j++]=oldchars[i++];
        preceedingDelimiter=true;
      }
 else {
        i++;
      }
    }
 else {
      newchars[j++]=oldchars[i++];
      preceedingDelimiter=false;
    }
  }
  if (preceedingDelimiter) {
    j--;
  }
  return String.valueOf(newchars,0,j);
}

Fixed version (ground truth):
/** 
 * eliminates the null path (consecutive delimiters) from the resource 
 */
private String purgeNullPath(String res){
  if ((res == null) || (res.length() == 0)) {
    return "String_Node_Str";
  }
  boolean preceedingDelimiter=false;
  int len=res.length();
  char[] oldchars=res.toCharArray();
  char[] newchars=new char[len];
  int i=0;
  int j=0;
  while (i < len) {
    if (oldchars[i] == delimiter.charAt(0)) {
      if (!preceedingDelimiter) {
        newchars[j++]=oldchars[i++];
        preceedingDelimiter=true;
      }
 else {
        i++;
      }
    }
 else {
      newchars[j++]=oldchars[i++];
      preceedingDelimiter=false;
    }
  }
  return String.valueOf(newchars,0,j);
}
Program: 79842
Project: 79842
Buggy source:
/** 
 * eliminates the null path (consecutive delimiters) from the resource 
 */
private String purgeNullPath(String res){
  if ((res == null) || (res.length() == 0)) {
    return "String_Node_Str";
  }
  boolean preceedingDelimiter=false;
  int len=res.length();
  char[] oldchars=res.toCharArray();
  char[] newchars=new char[len];
  int i=0;
  int j=0;
  while (i < len) {
    if (oldchars[i] == delimiter.charAt(0)) {
      if (!preceedingDelimiter) {
        newchars[j++]=oldchars[i++];
        preceedingDelimiter=true;
      }
 else {
        i++;
      }
    }
 else {
      newchars[j++]=oldchars[i++];
      preceedingDelimiter=false;
    }
  }
  if (preceedingDelimiter) {
    j--;
  }
  return String.valueOf(newchars,0,j);
}

Fixed version (ground truth):
/** 
 * eliminates the null path (consecutive delimiters) from the resource 
 */
private String purgeNullPath(String res){
  if ((res == null) || (res.length() == 0)) {
    return "String_Node_Str";
  }
  boolean preceedingDelimiter=false;
  int len=res.length();
  char[] oldchars=res.toCharArray();
  char[] newchars=new char[len];
  int i=0;
  int j=0;
  while (i < len) {
    if (oldchars[i] == delimiter.charAt(0)) {
      if (!preceedingDelimiter) {
        newchars[j++]=oldchars[i++];
        preceedingDelimiter=true;
      }
 else {
        i++;
      }
    }
 else {
      newchars[j++]=oldchars[i++];
      preceedingDelimiter=false;
    }
  }
  return String.valueOf(newchars,0,j);
}
Program: 79843
Project: 79843
Buggy source:
/** 
 * eliminates the null path (consecutive delimiters) from the resource 
 */
private String purgeNullPath(String res){
  if ((res == null) || (res.length() == 0)) {
    return "String_Node_Str";
  }
  boolean preceedingDelimiter=false;
  int len=res.length();
  char[] oldchars=res.toCharArray();
  char[] newchars=new char[len];
  int i=0;
  int j=0;
  while (i < len) {
    if (oldchars[i] == delimiter.charAt(0)) {
      if (!preceedingDelimiter) {
        newchars[j++]=oldchars[i++];
        preceedingDelimiter=true;
      }
 else {
        i++;
      }
    }
 else {
      newchars[j++]=oldchars[i++];
      preceedingDelimiter=false;
    }
  }
  if (preceedingDelimiter) {
    j--;
  }
  return String.valueOf(newchars,0,j);
}

Fixed version (ground truth):
/** 
 * eliminates the null path (consecutive delimiters) from the resource 
 */
private String purgeNullPath(String res){
  if ((res == null) || (res.length() == 0)) {
    return "String_Node_Str";
  }
  boolean preceedingDelimiter=false;
  int len=res.length();
  char[] oldchars=res.toCharArray();
  char[] newchars=new char[len];
  int i=0;
  int j=0;
  while (i < len) {
    if (oldchars[i] == delimiter.charAt(0)) {
      if (!preceedingDelimiter) {
        newchars[j++]=oldchars[i++];
        preceedingDelimiter=true;
      }
 else {
        i++;
      }
    }
 else {
      newchars[j++]=oldchars[i++];
      preceedingDelimiter=false;
    }
  }
  return String.valueOf(newchars,0,j);
}
Program: 79844
Project: 79844
Buggy source:
/** 
 * Returns an asynchronous connection from the underlying connection factory.
 * @param resultHandler the result handler
 * @return the FutureResult from the underlying factory.
 */
public FutureResult<Connection> getConnectionAsync(ResultHandler<? super Connection> resultHandler){
  return getConnectionAsync(resultHandler);
}

Fixed version (ground truth):
/** 
 * Returns an asynchronous connection from the underlying connection factory.
 * @param resultHandler the result handler
 * @return the FutureResult from the underlying factory.
 */
public FutureResult<Connection> getConnectionAsync(ResultHandler<? super Connection> resultHandler){
  return factory.getConnectionAsync(resultHandler);
}
Program: 79845
Project: 79845
Buggy source:
protected Map<String,Object> getDataModel(Set<String> scopes){
  Map<String,Object> data=new HashMap<String,Object>(getRequest().getAttributes());
  data.put("String_Node_Str",getRequest().getResourceRef().toString());
  Set<String> displayNames=client.getClient().getDisplayName();
  Set<String> displayDescriptions=client.getClient().getDisplayDescription();
  Set<String> allScopes=client.getClient().getAllowedGrantScopes();
  String locale=OAuth2Utils.getLocale(getRequest());
  String displayName="String_Node_Str";
  String displayDescription="String_Node_Str";
  List<String> displayScope=new ArrayList<String>();
  displayName=getDisplayParameter(locale,displayNames);
  displayDescription=getDisplayParameter(locale,displayDescriptions);
  displayScope=getScopeDescriptionsForLocale(scopes,allScopes,locale);
  data.put("String_Node_Str",displayName);
  data.put("String_Node_Str",displayDescription);
  data.put("String_Node_Str",displayScope);
  return data;
}

Fixed version (ground truth):
protected Map<String,Object> getDataModel(Set<String> scopes){
  Map<String,Object> data=new HashMap<String,Object>(getRequest().getAttributes());
  data.put("String_Node_Str",getRequest().getResourceRef().toString());
  Set<String> displayNames=client.getClient().getDisplayName();
  Set<String> displayDescriptions=client.getClient().getDisplayDescription();
  Set<String> allScopes=client.getClient().getAllowedGrantScopes();
  String locale=OAuth2Utils.getLocale(getRequest());
  String displayName="String_Node_Str";
  String displayDescription="String_Node_Str";
  List<String> displayScope=null;
  displayName=getDisplayParameter(locale,displayNames);
  displayDescription=getDisplayParameter(locale,displayDescriptions);
  displayScope=getScopeDescriptionsForLocale(scopes,allScopes,locale);
  data.put("String_Node_Str",ESAPI.encoder().encodeForHTML(displayName));
  data.put("String_Node_Str",ESAPI.encoder().encodeForHTML(displayDescription));
  data.put("String_Node_Str",encodeListForHTML(displayScope));
  return data;
}
Program: 79846
Project: 79846
Buggy source:
protected Map<String,Object> getDataModel(Set<String> scopes){
  Map<String,Object> data=new HashMap<String,Object>(getRequest().getAttributes());
  data.put("String_Node_Str",getRequest().getResourceRef().toString());
  Set<String> displayNames=client.getClient().getDisplayName();
  Set<String> displayDescriptions=client.getClient().getDisplayDescription();
  Set<String> allScopes=client.getClient().getAllowedGrantScopes();
  String locale=OAuth2Utils.getLocale(getRequest());
  String displayName="String_Node_Str";
  String displayDescription="String_Node_Str";
  List<String> displayScope=new ArrayList<String>();
  displayName=getDisplayParameter(locale,displayNames);
  displayDescription=getDisplayParameter(locale,displayDescriptions);
  displayScope=getScopeDescriptionsForLocale(scopes,allScopes,locale);
  data.put("String_Node_Str",displayName);
  data.put("String_Node_Str",displayDescription);
  data.put("String_Node_Str",displayScope);
  return data;
}

Fixed version (ground truth):
protected Map<String,Object> getDataModel(Set<String> scopes){
  Map<String,Object> data=new HashMap<String,Object>(getRequest().getAttributes());
  data.put("String_Node_Str",getRequest().getResourceRef().toString());
  Set<String> displayNames=client.getClient().getDisplayName();
  Set<String> displayDescriptions=client.getClient().getDisplayDescription();
  Set<String> allScopes=client.getClient().getAllowedGrantScopes();
  String locale=OAuth2Utils.getLocale(getRequest());
  String displayName="String_Node_Str";
  String displayDescription="String_Node_Str";
  List<String> displayScope=null;
  displayName=getDisplayParameter(locale,displayNames);
  displayDescription=getDisplayParameter(locale,displayDescriptions);
  displayScope=getScopeDescriptionsForLocale(scopes,allScopes,locale);
  data.put("String_Node_Str",ESAPI.encoder().encodeForHTML(displayName));
  data.put("String_Node_Str",ESAPI.encoder().encodeForHTML(displayDescription));
  data.put("String_Node_Str",encodeListForHTML(displayScope));
  return data;
}
Program: 79847
Project: 79847
Buggy source:
private String getPasswordFromHeader(ServerContext context){
  return RestUtils.getCookieFromServerContext(context);
}

Fixed version (ground truth):
private String getPasswordFromHeader(ServerContext context){
  List<String> headerList=null;
  String oldUserPasswordHeaderName="String_Node_Str";
  HttpContext header=null;
  try {
    header=context.asContext(HttpContext.class);
    if (header == null) {
      RestDispatcher.debug.error("String_Node_Str" + "String_Node_Str");
      return null;
    }
    headerList=header.getHeaders().get(oldUserPasswordHeaderName.toLowerCase());
    if (headerList != null && !headerList.isEmpty()) {
      for (      String s : headerList) {
        return (s != null && !s.isEmpty()) ? s : null;
      }
    }
  }
 catch (  Exception e) {
    RestDispatcher.debug.error("String_Node_Str" + "String_Node_Str" + e);
  }
  return null;
}
Program: 79849
Project: 79849
Buggy source:
/** 
 * The function to run when timeout.
 */
public void run(){
  if (!isTimedOut()) {
    if (sessionState == Session.INVALID) {
      setState(Session.DESTROYED);
      ss.removeInternalSession(sessionID);
      ss.sendEvent(this,SessionEvent.DESTROY);
    }
 else {
      long timeLeft=getTimeLeft();
      if (timeLeft == 0) {
        changeStateAndNotify(SessionEvent.MAX_TIMEOUT);
        if (timerPool != null) {
          if (purgeDelay > 0) {
            timerPool.schedule(this,new Date((timedOutAt + (purgeDelay * 60)) * 1000));
          }
        }
      }
 else {
        long idleTimeLeft=(maxIdleTime * 60) - getIdleTime();
        if (idleTimeLeft <= 0 && sessionState != Session.INACTIVE) {
          changeStateAndNotify(SessionEvent.IDLE_TIMEOUT);
          if (timerPool != null) {
            if (purgeDelay > 0) {
              timerPool.schedule(this,new Date((timedOutAt + (purgeDelay * 60)) * 1000));
            }
          }
        }
 else {
          long timeToWait=Math.min(timeLeft,idleTimeLeft);
          if (timerPool != null) {
            timerPool.schedule(this,new Date(((System.currentTimeMillis() / 1000) + timeToWait) * 1000));
          }
        }
      }
    }
  }
 else {
    ss.logEvent(this,SessionEvent.DESTROY);
    setState(Session.DESTROYED);
    ss.removeInternalSession(sessionID);
    ss.sendEvent(this,SessionEvent.DESTROY);
  }
}

Fixed version (ground truth):
/** 
 * The function to run when timeout.
 */
public void run(){
  if (!isTimedOut()) {
    if (isInvalid()) {
      removeSession();
    }
 else {
      long timeLeft=getTimeLeft();
      if (timeLeft == 0) {
        changeStateAndNotify(SessionEvent.MAX_TIMEOUT);
        if (timerPool != null) {
          if (purgeDelay > 0) {
            timerPool.schedule(this,new Date((timedOutAt + (purgeDelay * 60)) * 1000));
          }
        }
      }
 else {
        long idleTimeLeft=(maxIdleTime * 60) - getIdleTime();
        if (idleTimeLeft <= 0 && sessionState != Session.INACTIVE) {
          changeStateAndNotify(SessionEvent.IDLE_TIMEOUT);
          if (timerPool != null) {
            if (purgeDelay > 0) {
              timerPool.schedule(this,new Date((timedOutAt + (purgeDelay * 60)) * 1000));
            }
          }
        }
 else {
          long timeToWait=Math.min(timeLeft,idleTimeLeft);
          if (timerPool != null) {
            timerPool.schedule(this,new Date(((System.currentTimeMillis() / 1000) + timeToWait) * 1000));
          }
        }
      }
    }
  }
 else {
    removeSession();
  }
}
Program: 79850
Project: 79850
Buggy source:
/** 
 * Returns true if cookies are supported.
 * @return true if cookie supported;
 */
private boolean getCookieSupport(){
  boolean cookieSupport=false;
  try {
    if (sessionID.getCookieMode() != null) {
      cookieSupport=sessionID.getCookieMode().booleanValue();
    }
 else     if (this.cookieMode != null) {
      cookieSupport=this.cookieMode.booleanValue();
    }
  }
 catch (  Exception ex) {
    DEBUG.error("String_Node_Str",ex);
    cookieSupport=true;
  }
  if (DEBUG.messageEnabled()) {
    DEBUG.message("String_Node_Str" + cookieSupport);
  }
  return cookieSupport;
}

Fixed version (ground truth):
/** 
 * Returns true if cookies are supported.
 * @return true if cookie supported;
 */
private boolean getCookieSupport(){
  boolean cookieSupport=false;
  try {
    if (sessionID.getCookieMode() != null) {
      cookieSupport=sessionID.getCookieMode().booleanValue();
    }
 else     if (this.cookieMode != null) {
      cookieSupport=this.cookieMode.booleanValue();
    }
  }
 catch (  Exception ex) {
    debug.error("String_Node_Str",ex);
    cookieSupport=true;
  }
  if (debug.messageEnabled()) {
    debug.message("String_Node_Str" + cookieSupport);
  }
  return cookieSupport;
}
Program: 79851
Project: 79851
Buggy source:
/** 
 * Transfers the info about the Internal Session to Session Info.
 * @return SessionInfo
 */
public SessionInfo toSessionInfo(){
  SessionInfo info=new SessionInfo();
  info.sid=sessionID.toString();
  if (sessionType == Session.USER_SESSION) {
    info.stype="String_Node_Str";
  }
 else   if (sessionType == Session.APPLICATION_SESSION) {
    info.stype="String_Node_Str";
  }
  info.cid=clientID;
  info.cdomain=clientDomain;
  info.maxtime=Long.toString(getMaxSessionTime());
  info.maxidle=Long.toString(getMaxIdleTime());
  info.maxcaching=Long.toString(getMaxCachingTime());
  if (willExpireFlag == true) {
    info.timeidle=Long.toString(getIdleTime());
    info.timeleft=Long.toString(getTimeLeft());
  }
 else {
    info.timeidle=Long.toString(0);
    info.timeleft=Long.toString(Long.MAX_VALUE / 60);
  }
  if (sessionState == Session.INVALID) {
    info.state="String_Node_Str";
  }
 else   if (sessionState == Session.VALID) {
    info.state="String_Node_Str";
  }
 else   if (sessionState == Session.INACTIVE) {
    info.state="String_Node_Str";
  }
 else   if (sessionState == Session.DESTROYED) {
    info.state="String_Node_Str";
  }
  info.properties=(Properties)sessionProperties.clone();
  return info;
}

Fixed version (ground truth):
/** 
 * Transfers the info about the Internal Session to Session Info.
 * @return SessionInfo
 */
public SessionInfo toSessionInfo(){
  SessionInfo info=new SessionInfo();
  info.sid=sessionID.toString();
  if (sessionType == Session.USER_SESSION) {
    info.stype="String_Node_Str";
  }
 else   if (sessionType == Session.APPLICATION_SESSION) {
    info.stype="String_Node_Str";
  }
  info.cid=clientID;
  info.cdomain=clientDomain;
  info.maxtime=Long.toString(getMaxSessionTime());
  info.maxidle=Long.toString(getMaxIdleTime());
  info.maxcaching=Long.toString(getMaxCachingTime());
  if (willExpireFlag == true) {
    info.timeidle=Long.toString(getIdleTime());
    info.timeleft=Long.toString(getTimeLeft());
  }
 else {
    info.timeidle=Long.toString(0);
    info.timeleft=Long.toString(Long.MAX_VALUE / 60);
  }
  if (isInvalid()) {
    info.state="String_Node_Str";
  }
 else   if (sessionState == Session.VALID) {
    info.state="String_Node_Str";
  }
 else   if (sessionState == Session.INACTIVE) {
    info.state="String_Node_Str";
  }
 else   if (sessionState == Session.DESTROYED) {
    info.state="String_Node_Str";
  }
  info.properties=(Properties)sessionProperties.clone();
  return info;
}
Program: 79852
Project: 79852
Buggy source:
/** 
 * set the cookieMode based on whether the request has cookies or not. This method is called from createSSOToken(request) method in SSOTokenManager.
 * @param cookieMode ,Boolean value whether request has cookies or not.
 */
public void setCookieMode(Boolean cookieMode){
  DEBUG.message("String_Node_Str" + cookieMode);
  if (cookieMode != null) {
    this.cookieMode=cookieMode;
  }
}

Fixed version (ground truth):
/** 
 * set the cookieMode based on whether the request has cookies or not. This method is called from createSSOToken(request) method in SSOTokenManager.
 * @param cookieMode ,Boolean value whether request has cookies or not.
 */
public void setCookieMode(Boolean cookieMode){
  debug.message("String_Node_Str" + cookieMode);
  if (cookieMode != null) {
    this.cookieMode=cookieMode;
  }
}
Program: 79854
Project: 79854
Buggy source:
/** 
 * Sets the key-value pair in the InternalSession property table if it is not protected. If it is protected client should have permission to set it. This method is to be used in conjuction with SessionRequestHandler/SessionService invocation path If the property is protected, an attempt to remotely set a protected property is logged and the method throws an Exception. Otherwise invocation is delegated to internalPutProperty() Note that package default access is being used
 * @param clientToken Token of the client setting external property.
 * @param key Property key
 * @param value Property value for the key
 * @exception SessionException is thrown if the key is protected property.
 */
void putExternalProperty(SSOToken clientToken,String key,String value) throws SessionException {
  try {
    SessionUtils.checkPermissionToSetProperty(clientToken,key,value);
  }
 catch (  SessionException se) {
    SessionService.getSessionService().logIt(this,"String_Node_Str");
    throw se;
  }
  internalPutProperty(key,value);
  if (DEBUG.messageEnabled()) {
    DEBUG.message("String_Node_Str" + "String_Node_Str");
  }
}

Fixed version (ground truth):
/** 
 * Sets the key-value pair in the InternalSession property table if it is not protected. If it is protected client should have permission to set it. This method is to be used in conjuction with SessionRequestHandler/SessionService invocation path If the property is protected, an attempt to remotely set a protected property is logged and the method throws an Exception. Otherwise invocation is delegated to internalPutProperty() Note that package default access is being used
 * @param clientToken Token of the client setting external property.
 * @param key Property key
 * @param value Property value for the key
 * @exception SessionException is thrown if the key is protected property.
 */
void putExternalProperty(SSOToken clientToken,String key,String value) throws SessionException {
  try {
    SessionUtils.checkPermissionToSetProperty(clientToken,key,value);
  }
 catch (  SessionException se) {
    SessionService.getSessionService().logIt(this,"String_Node_Str");
    throw se;
  }
  internalPutProperty(key,value);
  if (debug.messageEnabled()) {
    debug.message("String_Node_Str" + "String_Node_Str");
  }
}
Program: 79855
Project: 79855
Buggy source:
/** 
 * Changes the state of the session to ACTIVE after creation.
 * @param userDN 
 * @return <code> true </code> if the session is successfully activated after creation , <code>false</code> otherwise
 */
public boolean activate(String userDN){
  if (userDN == null) {
    return false;
  }
  if ((SessionService.getActiveSessions() >= SessionService.maxSessions) && (!userDN.equalsIgnoreCase(superUserDN))) {
    SessionService.getSessionService().logSystemMessage(LOG_MSG_SESSION_MAX_LIMIT_REACHED,java.util.logging.Level.INFO);
    return false;
  }
  if ((SessionService.isSessionConstraintEnabled()) && !shouldIgnoreSessionQuotaChecking(userDN)) {
    if (SessionConstraint.checkQuotaAndPerformAction(this)) {
      if (DEBUG.messageEnabled()) {
        DEBUG.message("String_Node_Str" + "String_Node_Str");
      }
      SessionService.getSessionService().logEvent(this,SessionEvent.QUOTA_EXHAUSTED);
      return false;
    }
  }
  setLatestAccessTime();
  setState(Session.VALID);
  if (reschedulePossible) {
    reschedule();
  }
  SessionService.getSessionService().logEvent(this,SessionEvent.SESSION_CREATION);
  SessionService.getSessionService().sendEvent(this,SessionEvent.SESSION_CREATION);
  if (!isAppSession() || SessionService.returnAppSession) {
    SessionService.incrementActiveSessions();
  }
  return true;
}

Fixed version (ground truth):
/** 
 * Changes the state of the session to ACTIVE after creation.
 * @param userDN 
 * @return <code> true </code> if the session is successfully activated after creation , <code>false</code> otherwise
 */
public boolean activate(String userDN){
  if (userDN == null) {
    return false;
  }
  if ((SessionService.getActiveSessions() >= SessionService.maxSessions) && (!userDN.equalsIgnoreCase(superUserDN))) {
    SessionService.getSessionService().logSystemMessage(LOG_MSG_SESSION_MAX_LIMIT_REACHED,java.util.logging.Level.INFO);
    return false;
  }
  if ((SessionService.isSessionConstraintEnabled()) && !shouldIgnoreSessionQuotaChecking(userDN)) {
    if (SessionConstraint.checkQuotaAndPerformAction(this)) {
      if (debug.messageEnabled()) {
        debug.message("String_Node_Str" + "String_Node_Str");
      }
      SessionService.getSessionService().logEvent(this,SessionEvent.QUOTA_EXHAUSTED);
      return false;
    }
  }
  setLatestAccessTime();
  setState(Session.VALID);
  if (reschedulePossible) {
    reschedule();
  }
  SessionService.getSessionService().logEvent(this,SessionEvent.SESSION_CREATION);
  SessionService.getSessionService().sendEvent(this,SessionEvent.SESSION_CREATION);
  if (!isAppSession() || SessionService.returnAppSession) {
    SessionService.incrementActiveSessions();
  }
  return true;
}
Program: 79856
Project: 79856
Buggy source:
/** 
 * Default constructor required for deserialisation.
 */
public InternalSession(){
  this(null,SessionService.getSessionService(),SessionService.sessionDebug);
}

Fixed version (ground truth):
/** 
 * Default constructor required for deserialisation.
 */
public InternalSession(){
}
Program: 79857
Project: 79857
Buggy source:
/** 
 * Sets the key-value pair in the Internal Session property table.
 * @param key Property key
 * @param value Property value for the key
 */
protected void internalPutProperty(String key,String value){
  if (key.equals(HOST_NAME) || key.equals(HOST)) {
    if (value == null || value.length() == 0) {
      return;
    }
    if (isEnableHostLookUp) {
      try {
        InetAddress address=java.net.InetAddress.getByName(value);
        String hostName=address.getHostName();
        sessionProperties.put(HOST_NAME,hostName);
        sessionProperties.put(HOST,value);
      }
 catch (      UnknownHostException uhe) {
        DEBUG.error("String_Node_Str" + "String_Node_Str" + value + "String_Node_Str",uhe);
      }
    }
 else {
      sessionProperties.put(HOST_NAME,value);
      sessionProperties.put(HOST,value);
    }
  }
 else   if (key.equals(AM_MAX_IDLE_TIME)) {
    setMaxIdleTime(Long.parseLong(value));
  }
 else {
    sessionProperties.put(key,value);
  }
  if (sessionState == Session.VALID && SessionService.isSendPropertyNotification(key)) {
    SessionService.getSessionService().sendEvent(this,SessionEvent.PROPERTY_CHANGED);
    SessionService.getSessionService().logEvent(this,SessionEvent.PROPERTY_CHANGED);
  }
  updateForFailover();
}

Fixed version (ground truth):
/** 
 * Sets the key-value pair in the Internal Session property table.
 * @param key Property key
 * @param value Property value for the key
 */
protected void internalPutProperty(String key,String value){
  if (key.equals(HOST_NAME) || key.equals(HOST)) {
    if (value == null || value.length() == 0) {
      return;
    }
    if (isEnableHostLookUp) {
      try {
        InetAddress address=java.net.InetAddress.getByName(value);
        String hostName=address.getHostName();
        sessionProperties.put(HOST_NAME,hostName);
        sessionProperties.put(HOST,value);
      }
 catch (      UnknownHostException uhe) {
        debug.error("String_Node_Str" + "String_Node_Str" + value + "String_Node_Str",uhe);
      }
    }
 else {
      sessionProperties.put(HOST_NAME,value);
      sessionProperties.put(HOST,value);
    }
  }
 else   if (key.equals(AM_MAX_IDLE_TIME)) {
    setMaxIdleTime(Long.parseLong(value));
  }
 else {
    sessionProperties.put(key,value);
  }
  if (sessionState == Session.VALID && SessionService.isSendPropertyNotification(key)) {
    SessionService.getSessionService().sendEvent(this,SessionEvent.PROPERTY_CHANGED);
    SessionService.getSessionService().logEvent(this,SessionEvent.PROPERTY_CHANGED);
  }
  updateForFailover();
}
Program: 79858
Project: 79858
Buggy source:
/** 
 * Checks whether the sesion should be destroyed or not.
 */
boolean shouldDestroy(){
  if (willExpireFlag == false) {
    return false;
  }
  if (!isTimedOut()) {
    if (sessionState == Session.INVALID) {
      if (checkInvalidSessionDefaultIdleTime()) {
        setState(Session.DESTROYED);
        ss.sendEvent(this,SessionEvent.DESTROY);
        return true;
      }
 else {
        return false;
      }
    }
    if (getTimeLeft() == 0) {
      changeStateAndNotify(SessionEvent.MAX_TIMEOUT);
      return false;
    }
    if (getIdleTime() >= maxIdleTime * 60 && sessionState != Session.INACTIVE) {
      changeStateAndNotify(SessionEvent.IDLE_TIMEOUT);
      return false;
    }
    return false;
  }
 else {
    if (getTimeLeftBeforePurge() <= 0) {
      SessionService.getSessionService().logEvent(this,SessionEvent.DESTROY);
      setState(Session.DESTROYED);
      SessionService.getSessionService().sendEvent(this,SessionEvent.DESTROY);
      return true;
    }
 else {
      return false;
    }
  }
}

Fixed version (ground truth):
/** 
 * Checks whether the sesion should be destroyed or not.
 */
boolean shouldDestroy(){
  if (willExpireFlag == false) {
    return false;
  }
  if (!isTimedOut()) {
    if (isInvalid()) {
      if (checkInvalidSessionDefaultIdleTime()) {
        setState(Session.DESTROYED);
        ss.sendEvent(this,SessionEvent.DESTROY);
        return true;
      }
 else {
        return false;
      }
    }
    if (getTimeLeft() == 0) {
      changeStateAndNotify(SessionEvent.MAX_TIMEOUT);
      return false;
    }
    if (getIdleTime() >= maxIdleTime * 60 && sessionState != Session.INACTIVE) {
      changeStateAndNotify(SessionEvent.IDLE_TIMEOUT);
      return false;
    }
    return false;
  }
 else {
    if (getTimeLeftBeforePurge() <= 0) {
      SessionService.getSessionService().logEvent(this,SessionEvent.DESTROY);
      setState(Session.DESTROYED);
      SessionService.getSessionService().sendEvent(this,SessionEvent.DESTROY);
      return true;
    }
 else {
      return false;
    }
  }
}
Program: 79860
Project: 79860
Buggy source:
/** 
 * Removes the Internal Session from the Internal Session table.
 * @param sid Session ID
 */
InternalSession removeInternalSession(SessionID sid){
  boolean isSessionStored=true;
  if (sid == null)   return null;
  InternalSession session=(InternalSession)sessionTable.remove(sid);
  if (session != null) {
    remoteSessionSet.remove(sid);
    session.cancel();
    removeSessionHandle(session);
    removeRestrictedTokens(session);
    isSessionStored=session.getIsISstored();
    if (session.getState() == Session.VALID) {
      decrementActiveSessions();
      SessionCount.decrementSessionCount(session);
    }
  }
  if (isSessionFailoverEnabled && isSessionStored) {
    if (getUseInternalRequestRouting()) {
      try {
        String tokenId=tokenIdFactory.toSessionTokenId(session);
        getRepository().delete(tokenId);
      }
 catch (      Exception e) {
        sessionDebug.error("String_Node_Str",e);
      }
    }
 else {
      invalidateHttpSession(sid);
    }
  }
  return session;
}

Fixed version (ground truth):
/** 
 * Removes the Internal Session from the Internal Session table.
 * @param sid Session ID
 */
InternalSession removeInternalSession(SessionID sid){
  boolean isSessionStored=false;
  if (sid == null)   return null;
  InternalSession session=(InternalSession)sessionTable.remove(sid);
  if (session != null) {
    remoteSessionSet.remove(sid);
    session.cancel();
    removeSessionHandle(session);
    removeRestrictedTokens(session);
    isSessionStored=session.getIsISstored();
    if (session.getState() == Session.VALID) {
      decrementActiveSessions();
      SessionCount.decrementSessionCount(session);
    }
  }
  if (isSessionFailoverEnabled && isSessionStored) {
    if (getUseInternalRequestRouting()) {
      try {
        String tokenId=tokenIdFactory.toSessionTokenId(session);
        getRepository().delete(tokenId);
      }
 catch (      Exception e) {
        sessionDebug.error("String_Node_Str",e);
      }
    }
 else {
      invalidateHttpSession(sid);
    }
  }
  return session;
}
Program: 79864
Project: 79864
Buggy source:
/** 
 * Creates a default instance with dependencies defined.
 * @param tokenIdFactory Non null.
 * @param config Non null.
 * @param serialisation Non null.
 * @param blobUtils
 */
@Inject public SessionAdapter(TokenIdFactory tokenIdFactory,CoreTokenConfig config,JSONSerialisation serialisation,LDAPDataConversion dataConversion,TokenBlobUtils blobUtils){
  this.tokenIdFactory=tokenIdFactory;
  this.config=config;
  this.serialisation=serialisation;
  this.dataConversion=dataConversion;
  this.blobUtils=blobUtils;
}

Fixed version (ground truth):
/** 
 * Creates a default instance with dependencies defined.
 * @param tokenIdFactory Non null.
 * @param config Non null.
 * @param serialisation Non null.
 * @param blobUtils A collection of Binary Object utilities.
 */
@Inject public SessionAdapter(TokenIdFactory tokenIdFactory,CoreTokenConfig config,JSONSerialisation serialisation,LDAPDataConversion dataConversion,TokenBlobUtils blobUtils){
  this.tokenIdFactory=tokenIdFactory;
  this.config=config;
  this.serialisation=serialisation;
  this.dataConversion=dataConversion;
  this.blobUtils=blobUtils;
}
Program: 79865
Project: 79865
Buggy source:
@Post("String_Node_Str") public Representation represent(Representation entity){
  Representation rep=null;
  client=getAuthenticatedClient();
  if (client.getClient().getClientType().equals(ClientApplication.ClientType.PUBLIC)) {
    OAuth2Utils.DEBUG.warning("String_Node_Str");
    throw OAuthProblemException.OAuthError.INVALID_CLIENT.handle(getRequest(),"String_Node_Str");
  }
  String scope_before=OAuth2Utils.getRequestParameter(getRequest(),OAuth2Constants.Params.SCOPE,String.class);
  Set<String> checkedScope=executeAccessTokenScopePlugin(scope_before);
  CoreToken token=createAccessToken(checkedScope);
  Map<String,Object> response=token.convertToMap();
  Map<String,String> data=new HashMap<String,String>();
  response.putAll(executeExtraDataScopePlugin(data,token));
  if (checkedScope != null && !checkedScope.isEmpty()) {
    response.put(OAuth2Constants.Params.SCOPE,OAuth2Utils.join(checkedScope,OAuth2Utils.getScopeDelimiter(getContext())));
  }
  return new JacksonRepresentation<Map>(response);
}

Fixed version (ground truth):
@Post("String_Node_Str") public Representation represent(Representation entity){
  Representation rep=null;
  client=getAuthenticatedClient();
  if (client.getClient().getClientType().equals(ClientApplication.ClientType.PUBLIC)) {
    OAuth2Utils.DEBUG.warning("String_Node_Str");
    throw OAuthProblemException.OAuthError.UNAUTHORIZED_CLIENT.handle(getRequest(),"String_Node_Str");
  }
  String scope_before=OAuth2Utils.getRequestParameter(getRequest(),OAuth2Constants.Params.SCOPE,String.class);
  Set<String> checkedScope=executeAccessTokenScopePlugin(scope_before);
  CoreToken token=createAccessToken(checkedScope);
  Map<String,Object> response=token.convertToMap();
  Map<String,String> data=new HashMap<String,String>();
  response.putAll(executeExtraDataScopePlugin(data,token));
  if (checkedScope != null && !checkedScope.isEmpty()) {
    response.put(OAuth2Constants.Params.SCOPE,OAuth2Utils.join(checkedScope,OAuth2Utils.getScopeDelimiter(getContext())));
  }
  return new JacksonRepresentation<Map>(response);
}
Program: 79866
Project: 79866
Buggy source:
/** 
 * The function to run when timeout.
 */
public void run(){
  if (!isTimedOut()) {
    if (sessionState == Session.INVALID) {
      setState(Session.DESTROYED);
      ss.removeInternalSession(sessionID);
      ss.sendEvent(this,SessionEvent.DESTROY);
    }
 else {
      long timeLeft=getTimeLeft();
      if (timeLeft == 0) {
        changeStateAndNotify(SessionEvent.MAX_TIMEOUT);
        if (timerPool != null) {
          if (purgeDelay > 0) {
            timerPool.schedule(this,new Date((timedOutAt + (purgeDelay * 60)) * 1000));
          }
        }
      }
 else {
        long idleTimeLeft=(maxIdleTime * 60) - getIdleTime();
        if (idleTimeLeft <= 0 && sessionState != Session.INACTIVE) {
          changeStateAndNotify(SessionEvent.IDLE_TIMEOUT);
          if (timerPool != null) {
            if (purgeDelay > 0) {
              timerPool.schedule(this,new Date((timedOutAt + (purgeDelay * 60)) * 1000));
            }
          }
        }
 else {
          long timeToWait=Math.min(timeLeft,idleTimeLeft);
          if (timerPool != null) {
            timerPool.schedule(this,new Date(((System.currentTimeMillis() / 1000) + timeToWait) * 1000));
          }
        }
      }
    }
  }
 else {
    ss.logEvent(this,SessionEvent.DESTROY);
    setState(Session.DESTROYED);
    ss.removeInternalSession(sessionID);
    ss.sendEvent(this,SessionEvent.DESTROY);
  }
}

Fixed version (ground truth):
/** 
 * The function to run when timeout.
 */
public void run(){
  if (!isTimedOut()) {
    if (isInvalid()) {
      removeSession();
    }
 else {
      long timeLeft=getTimeLeft();
      if (timeLeft == 0) {
        changeStateAndNotify(SessionEvent.MAX_TIMEOUT);
        if (timerPool != null) {
          if (purgeDelay > 0) {
            timerPool.schedule(this,new Date((timedOutAt + (purgeDelay * 60)) * 1000));
          }
        }
      }
 else {
        long idleTimeLeft=(maxIdleTime * 60) - getIdleTime();
        if (idleTimeLeft <= 0 && sessionState != Session.INACTIVE) {
          changeStateAndNotify(SessionEvent.IDLE_TIMEOUT);
          if (timerPool != null) {
            if (purgeDelay > 0) {
              timerPool.schedule(this,new Date((timedOutAt + (purgeDelay * 60)) * 1000));
            }
          }
        }
 else {
          long timeToWait=Math.min(timeLeft,idleTimeLeft);
          if (timerPool != null) {
            timerPool.schedule(this,new Date(((System.currentTimeMillis() / 1000) + timeToWait) * 1000));
          }
        }
      }
    }
  }
 else {
    removeSession();
  }
}
Program: 79867
Project: 79867
Buggy source:
/** 
 * Returns true if cookies are supported.
 * @return true if cookie supported;
 */
private boolean getCookieSupport(){
  boolean cookieSupport=false;
  try {
    if (sessionID.getCookieMode() != null) {
      cookieSupport=sessionID.getCookieMode().booleanValue();
    }
 else     if (this.cookieMode != null) {
      cookieSupport=this.cookieMode.booleanValue();
    }
  }
 catch (  Exception ex) {
    DEBUG.error("String_Node_Str",ex);
    cookieSupport=true;
  }
  if (DEBUG.messageEnabled()) {
    DEBUG.message("String_Node_Str" + cookieSupport);
  }
  return cookieSupport;
}

Fixed version (ground truth):
/** 
 * Returns true if cookies are supported.
 * @return true if cookie supported;
 */
private boolean getCookieSupport(){
  boolean cookieSupport=false;
  try {
    if (sessionID.getCookieMode() != null) {
      cookieSupport=sessionID.getCookieMode().booleanValue();
    }
 else     if (this.cookieMode != null) {
      cookieSupport=this.cookieMode.booleanValue();
    }
  }
 catch (  Exception ex) {
    debug.error("String_Node_Str",ex);
    cookieSupport=true;
  }
  if (debug.messageEnabled()) {
    debug.message("String_Node_Str" + cookieSupport);
  }
  return cookieSupport;
}
Program: 79868
Project: 79868
Buggy source:
/** 
 * Transfers the info about the Internal Session to Session Info.
 * @return SessionInfo
 */
public SessionInfo toSessionInfo(){
  SessionInfo info=new SessionInfo();
  info.sid=sessionID.toString();
  if (sessionType == Session.USER_SESSION) {
    info.stype="String_Node_Str";
  }
 else   if (sessionType == Session.APPLICATION_SESSION) {
    info.stype="String_Node_Str";
  }
  info.cid=clientID;
  info.cdomain=clientDomain;
  info.maxtime=Long.toString(getMaxSessionTime());
  info.maxidle=Long.toString(getMaxIdleTime());
  info.maxcaching=Long.toString(getMaxCachingTime());
  if (willExpireFlag == true) {
    info.timeidle=Long.toString(getIdleTime());
    info.timeleft=Long.toString(getTimeLeft());
  }
 else {
    info.timeidle=Long.toString(0);
    info.timeleft=Long.toString(Long.MAX_VALUE / 60);
  }
  if (sessionState == Session.INVALID) {
    info.state="String_Node_Str";
  }
 else   if (sessionState == Session.VALID) {
    info.state="String_Node_Str";
  }
 else   if (sessionState == Session.INACTIVE) {
    info.state="String_Node_Str";
  }
 else   if (sessionState == Session.DESTROYED) {
    info.state="String_Node_Str";
  }
  info.properties=(Properties)sessionProperties.clone();
  return info;
}

Fixed version (ground truth):
/** 
 * Transfers the info about the Internal Session to Session Info.
 * @return SessionInfo
 */
public SessionInfo toSessionInfo(){
  SessionInfo info=new SessionInfo();
  info.sid=sessionID.toString();
  if (sessionType == Session.USER_SESSION) {
    info.stype="String_Node_Str";
  }
 else   if (sessionType == Session.APPLICATION_SESSION) {
    info.stype="String_Node_Str";
  }
  info.cid=clientID;
  info.cdomain=clientDomain;
  info.maxtime=Long.toString(getMaxSessionTime());
  info.maxidle=Long.toString(getMaxIdleTime());
  info.maxcaching=Long.toString(getMaxCachingTime());
  if (willExpireFlag == true) {
    info.timeidle=Long.toString(getIdleTime());
    info.timeleft=Long.toString(getTimeLeft());
  }
 else {
    info.timeidle=Long.toString(0);
    info.timeleft=Long.toString(Long.MAX_VALUE / 60);
  }
  if (isInvalid()) {
    info.state="String_Node_Str";
  }
 else   if (sessionState == Session.VALID) {
    info.state="String_Node_Str";
  }
 else   if (sessionState == Session.INACTIVE) {
    info.state="String_Node_Str";
  }
 else   if (sessionState == Session.DESTROYED) {
    info.state="String_Node_Str";
  }
  info.properties=(Properties)sessionProperties.clone();
  return info;
}
Program: 79869
Project: 79869
Buggy source:
/** 
 * set the cookieMode based on whether the request has cookies or not. This method is called from createSSOToken(request) method in SSOTokenManager.
 * @param cookieMode ,Boolean value whether request has cookies or not.
 */
public void setCookieMode(Boolean cookieMode){
  DEBUG.message("String_Node_Str" + cookieMode);
  if (cookieMode != null) {
    this.cookieMode=cookieMode;
  }
}

Fixed version (ground truth):
/** 
 * set the cookieMode based on whether the request has cookies or not. This method is called from createSSOToken(request) method in SSOTokenManager.
 * @param cookieMode ,Boolean value whether request has cookies or not.
 */
public void setCookieMode(Boolean cookieMode){
  debug.message("String_Node_Str" + cookieMode);
  if (cookieMode != null) {
    this.cookieMode=cookieMode;
  }
}
Program: 79871
Project: 79871
Buggy source:
/** 
 * Sets the key-value pair in the InternalSession property table if it is not protected. If it is protected client should have permission to set it. This method is to be used in conjuction with SessionRequestHandler/SessionService invocation path If the property is protected, an attempt to remotely set a protected property is logged and the method throws an Exception. Otherwise invocation is delegated to internalPutProperty() Note that package default access is being used
 * @param clientToken Token of the client setting external property.
 * @param key Property key
 * @param value Property value for the key
 * @exception SessionException is thrown if the key is protected property.
 */
void putExternalProperty(SSOToken clientToken,String key,String value) throws SessionException {
  try {
    SessionUtils.checkPermissionToSetProperty(clientToken,key,value);
  }
 catch (  SessionException se) {
    SessionService.getSessionService().logIt(this,"String_Node_Str");
    throw se;
  }
  internalPutProperty(key,value);
  if (DEBUG.messageEnabled()) {
    DEBUG.message("String_Node_Str" + "String_Node_Str");
  }
}

Fixed version (ground truth):
/** 
 * Sets the key-value pair in the InternalSession property table if it is not protected. If it is protected client should have permission to set it. This method is to be used in conjuction with SessionRequestHandler/SessionService invocation path If the property is protected, an attempt to remotely set a protected property is logged and the method throws an Exception. Otherwise invocation is delegated to internalPutProperty() Note that package default access is being used
 * @param clientToken Token of the client setting external property.
 * @param key Property key
 * @param value Property value for the key
 * @exception SessionException is thrown if the key is protected property.
 */
void putExternalProperty(SSOToken clientToken,String key,String value) throws SessionException {
  try {
    SessionUtils.checkPermissionToSetProperty(clientToken,key,value);
  }
 catch (  SessionException se) {
    SessionService.getSessionService().logIt(this,"String_Node_Str");
    throw se;
  }
  internalPutProperty(key,value);
  if (debug.messageEnabled()) {
    debug.message("String_Node_Str" + "String_Node_Str");
  }
}