hsarjcli/src/de/hsadmin/jscli/CASTicket.java | ●●●●● patch | view | raw | blame | history | |
hsarjcli/src/de/hsadmin/jscli/Config.java | ●●●●● patch | view | raw | blame | history |
hsarjcli/src/de/hsadmin/jscli/CASTicket.java
@@ -117,6 +117,7 @@ } private String readFiledGrantingTicket() throws JSCliException { String filedTicket = null; String userHome = System.getProperty("user.home"); String ticketFileName = userHome + "/.hsadmin.tgt"; File file = new File(ticketFileName); @@ -124,12 +125,15 @@ Properties properties = new Properties(); try { properties.load(new FileReader(file)); return properties.getProperty(user); filedTicket = properties.getProperty(user); } catch (IOException e) { throw new JSCliException(e); } } return null; if (filedTicket == null) { filedTicket = getGrantingTicket(); } return filedTicket; } private void writeFiledGrantingTicket(String ticket) throws JSCliException { hsarjcli/src/de/hsadmin/jscli/Config.java
@@ -43,7 +43,11 @@ } public String getProperty(String propertyName) { return props.getProperty(propertyName).trim(); String property = props.getProperty(propertyName); if (property == null) { return null; } return property.trim(); } public String getProperty(String propertyName, String defaultValue) {