mirror of
https://github.com/yuezk/GlobalProtect-openconnect.git
synced 2026-11-19 06:26:14 -05:00
Support SSO using default browser
This commit is contained in:
1 parent
0b55a80317
commit
c3bd7aeb93
16 files changed
+201
-36
No files matched your search
@@ -21,6 +21,13 @@ pub(crate) async fn active_gui(State(ctx): State<Arc<WsServerContext>>) -> impl
|
||||
ctx.send_event(WsEvent::ActiveGui).await;
|
||||
}
|
||||
|
||||
pub(crate) async fn auth_data(
|
||||
State(ctx): State<Arc<WsServerContext>>,
|
||||
body: String,
|
||||
) -> impl IntoResponse {
|
||||
ctx.send_event(WsEvent::AuthData(body)).await;
|
||||
}
|
||||
|
||||
pub(crate) async fn ws_handler(
|
||||
ws: WebSocketUpgrade,
|
||||
State(ctx): State<Arc<WsServerContext>>,
|
||||
|
||||
@@ -8,6 +8,7 @@ pub(crate) fn routes(ctx: Arc<WsServerContext>) -> Router {
|
||||
Router::new()
|
||||
.route("/health", get(handlers::health))
|
||||
.route("/active-gui", post(handlers::active_gui))
|
||||
.route("/auth-data", post(handlers::auth_data))
|
||||
.route("/ws", get(handlers::ws_handler))
|
||||
.with_state(ctx)
|
||||
}
|
||||
Reference in new issue
Block a user