Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .gcp.env
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
SENTRIUS_VERSION=1.0.23
SENTRIUS_SSH_VERSION=1.0.2
SENTRIUS_VERSION=1.0.33
SENTRIUS_SSH_VERSION=1.0.3
SENTRIUS_KEYCLOAK_VERSION=1.0.4
SENTRIUS_AGENT_VERSION=1.0.14
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,8 @@ public String editEnclave(HttpServletRequest request, HttpServletResponse respon
String maxConcurrentSessions = request.getParameter("maxConcurrentSessions");
String allowSudoStr = request.getParameter("allowSudo");
String approveViaTicketStr = request.getParameter("approveViaTicket");

String autoApproveChangingHostKey = request.getParameter("autoApproveChangingHostKey");
log.info("allowSudoStr: {}", allowSudoStr);

var hostGroup = hg.get();
Expand All @@ -176,6 +178,15 @@ public String editEnclave(HttpServletRequest request, HttpServletResponse respon
configuration.setApproveViaTicket(false);
}

if (null != autoApproveChangingHostKey && !autoApproveChangingHostKey.isEmpty()) {
log.info("Setting autoApproveChangingHostKey to true {}", autoApproveChangingHostKey);
configuration.setAutoApproveChangingHostKey(true);
}
else {
log.info("Setting autoApproveChangingHostKey to false {}", autoApproveChangingHostKey);
configuration.setAutoApproveChangingHostKey(false);
}

hostGroup.setName(displayName);
hostGroup.setDescription(description);
hostGroup.setConfiguration(configuration);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
import io.sentrius.sso.core.model.users.UserSettings;
import io.sentrius.sso.core.security.service.CryptoService;
import io.sentrius.sso.core.services.ErrorOutputService;
import io.sentrius.sso.core.services.SessionService;
import io.sentrius.sso.core.services.UserCustomizationService;
import io.sentrius.sso.core.services.UserService;
import io.sentrius.sso.core.services.HostGroupService;
Expand Down Expand Up @@ -58,17 +59,21 @@ public class UserApiController extends BaseController {
}
}

private final SessionService sessionService;

protected UserApiController(UserService userService, SystemOptions systemOptions,
ErrorOutputService errorOutputService,
HostGroupService hostGroupService, CryptoService cryptoService,
MessagingUtil messagingUtil,
UserCustomizationService userThemeService
UserCustomizationService userThemeService,
SessionService sessionService
) {
super(userService, systemOptions, errorOutputService);
this.hostGroupService = hostGroupService;
this.cryptoService = cryptoService;
this.messagingUtil = messagingUtil;
this.userThemeService = userThemeService;
this.sessionService = sessionService;
}

@GetMapping("list")
Expand Down Expand Up @@ -208,5 +213,14 @@ public String deleteType(@RequestParam("id") String dtoId) throws GeneralSecurit
return "redirect:/sso/v1/users/list?message=" + MessagingUtil.getMessageId(MessagingUtil.USER_DELETE_SUCCESS);
}

@GetMapping("/sessions/graph")
public ResponseEntity<Map<String, Integer>> getGraphData(HttpServletRequest request,
HttpServletResponse response) {
var username = userService.getOperatingUser(request,response, null).getUsername();
var ret= sessionService.getGraphData(username);

return ResponseEntity.ok(ret);
}

}

Loading
Loading