private static String embedServerID(String id){
  String serverId=null;
  try {
    serverId=SystemConfigurationUtil.getServerID(serverProtocol,serverHost,intServerPort,serverUri);
    if (serverId != null && serverId.length() == 2) {
      id=id.substring(0,id.length() - 2) + serverId;
    }
 else     if (debug.messageEnabled()) {
      debug.message("SAML2Utils.appendServerID: " + "invalid server id = " + serverId);
    }
  }
 catch (  Exception ex) {
    if (debug.messageEnabled()) {
      debug.message("SAML2Utils.appendServerID:",ex);
    }
  }
  return id;
}

private static String embedServerID ( String id ) { String serverId = null ; try { serverId = SystemConfigurationUtil . getServerID ( serverProtocol , serverHost , intServerPort , serverUri ) ; if ( serverId != null && serverId . length ( ) == 2 ) { id = id . substring ( 0 , id . length ( ) - 2 ) + serverId ; } else if ( debug . messageEnabled ( ) ) { debug . message ( "SAML2Utils.appendServerID: " + "invalid server id = " + serverId ) ; } } catch ( Exception ex ) { if ( debug . messageEnabled ( ) ) { debug . message ( "SAML2Utils.appendServerID:" , ex ) ; } } return id ; }
replaces last 2 chars of specified id with server id .
