[PR #155] [MERGED] [WIP] Auth plugins #90

Closed
opened 2025-12-29 07:19:17 +01:00 by adam · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/mountain-loop/yaak/pull/155
Author: @gschier
Created: 1/15/2025
Status: Merged
Merged: 1/17/2025
Merged by: @gschier

Base: masterHead: auth-plugins


📝 Commits (10+)

  • 357d85e Start on form inputs
  • 81e932e Merge branch 'master' into auth-plugins
  • ded12b8 Fixes after master merge
  • 07f1fec Convert auth handlers to plugins
  • 9f37c8e Re-generate types
  • 5db7b23 Starting to wire up frontend
  • 98bca01 Got auth editor working with
  • d98742d Use plugin name for authenticationType
  • afb11ee Use plugin name for authenticationType
  • 9b497d9 Also apply to GRPC

📊 Changes

56 files changed (+5455 additions, -1461 deletions)

View changed files

📝 package-lock.json (+1 -1)
📝 packages/plugin-runtime-types/package.json (+4 -3)
📝 packages/plugin-runtime-types/src/bindings/events.ts (+205 -320)
📝 packages/plugin-runtime-types/src/bindings/models.ts (+4 -4)
packages/plugin-runtime-types/src/plugins/AuthenticationPlugin.ts (+9 -0)
📝 packages/plugin-runtime-types/src/plugins/index.ts (+2 -0)
📝 packages/plugin-runtime/src/index.worker.ts (+28 -1)
📝 src-tauri/Cargo.lock (+97 -397)
📝 src-tauri/Cargo.toml (+2 -3)
📝 src-tauri/src/http_request.rs (+56 -29)
📝 src-tauri/src/lib.rs (+107 -83)
📝 src-tauri/src/render.rs (+9 -9)
📝 src-tauri/src/template_callback.rs (+6 -6)
src-tauri/vendored/plugins/auth-basic/build/index.js (+55 -0)
src-tauri/vendored/plugins/auth-basic/package.json (+9 -0)
src-tauri/vendored/plugins/auth-bearer/build/index.js (+50 -0)
src-tauri/vendored/plugins/auth-bearer/package.json (+9 -0)
src-tauri/vendored/plugins/auth-jwt/build/index.js (+3822 -0)
src-tauri/vendored/plugins/auth-jwt/package.json (+15 -0)
📝 src-tauri/yaak-grpc/Cargo.toml (+8 -7)

...and 36 more files

📄 Description

This PR moves all authentication handlers to plugins (currently in Rust), and updates the plugin APIs accordingly.

  • Use plugin name as HttpRequest.authenticationType
  • Add plugin runtime hooks to get auth and call auth
  • Use the same form layout (json -> jsx) logic to render auth config
  • Apply to HTTP send
  • Apply to GRPC send

Tangential

  • Fallback to gRPC v1 reflection (currently only v1alpha)

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/mountain-loop/yaak/pull/155 **Author:** [@gschier](https://github.com/gschier) **Created:** 1/15/2025 **Status:** ✅ Merged **Merged:** 1/17/2025 **Merged by:** [@gschier](https://github.com/gschier) **Base:** `master` ← **Head:** `auth-plugins` --- ### 📝 Commits (10+) - [`357d85e`](https://github.com/mountain-loop/yaak/commit/357d85e5646baebb901ae2c665b92857a3df49be) Start on form inputs - [`81e932e`](https://github.com/mountain-loop/yaak/commit/81e932ebbf21bf66f4dc8c4d50f303011b9f8f65) Merge branch 'master' into auth-plugins - [`ded12b8`](https://github.com/mountain-loop/yaak/commit/ded12b8f657051d316e64e805d81580dcab30140) Fixes after master merge - [`07f1fec`](https://github.com/mountain-loop/yaak/commit/07f1fecd989c8b7230266eba4f4c530ebfb715e4) Convert auth handlers to plugins - [`9f37c8e`](https://github.com/mountain-loop/yaak/commit/9f37c8e3d94b4a5bcea654f3831ba7745a73a5f6) Re-generate types - [`5db7b23`](https://github.com/mountain-loop/yaak/commit/5db7b238fb60079ac14a17f1394e20292a5677c9) Starting to wire up frontend - [`98bca01`](https://github.com/mountain-loop/yaak/commit/98bca01edfbbaf80fcfdd88d112a70f75a071aa3) Got auth editor working with <DynamicForm/> - [`d98742d`](https://github.com/mountain-loop/yaak/commit/d98742dfefc3dc0d12fe584b10ad67be99172c42) Use plugin name for `authenticationType` - [`afb11ee`](https://github.com/mountain-loop/yaak/commit/afb11ee50ab6d804597bdf9a32c5713f76b93811) Use plugin name for `authenticationType` - [`9b497d9`](https://github.com/mountain-loop/yaak/commit/9b497d9dd6530eac6e0409cd92dc9d98c55cd2a5) Also apply to GRPC ### 📊 Changes **56 files changed** (+5455 additions, -1461 deletions) <details> <summary>View changed files</summary> 📝 `package-lock.json` (+1 -1) 📝 `packages/plugin-runtime-types/package.json` (+4 -3) 📝 `packages/plugin-runtime-types/src/bindings/events.ts` (+205 -320) 📝 `packages/plugin-runtime-types/src/bindings/models.ts` (+4 -4) ➕ `packages/plugin-runtime-types/src/plugins/AuthenticationPlugin.ts` (+9 -0) 📝 `packages/plugin-runtime-types/src/plugins/index.ts` (+2 -0) 📝 `packages/plugin-runtime/src/index.worker.ts` (+28 -1) 📝 `src-tauri/Cargo.lock` (+97 -397) 📝 `src-tauri/Cargo.toml` (+2 -3) 📝 `src-tauri/src/http_request.rs` (+56 -29) 📝 `src-tauri/src/lib.rs` (+107 -83) 📝 `src-tauri/src/render.rs` (+9 -9) 📝 `src-tauri/src/template_callback.rs` (+6 -6) ➕ `src-tauri/vendored/plugins/auth-basic/build/index.js` (+55 -0) ➕ `src-tauri/vendored/plugins/auth-basic/package.json` (+9 -0) ➕ `src-tauri/vendored/plugins/auth-bearer/build/index.js` (+50 -0) ➕ `src-tauri/vendored/plugins/auth-bearer/package.json` (+9 -0) ➕ `src-tauri/vendored/plugins/auth-jwt/build/index.js` (+3822 -0) ➕ `src-tauri/vendored/plugins/auth-jwt/package.json` (+15 -0) 📝 `src-tauri/yaak-grpc/Cargo.toml` (+8 -7) _...and 36 more files_ </details> ### 📄 Description This PR moves all authentication handlers to plugins (currently in Rust), and updates the plugin APIs accordingly. - [x] Use plugin name as `HttpRequest.authenticationType` - [x] Add plugin runtime hooks to get auth and call auth - [x] Use the same form layout (json -> jsx) logic to render auth config - [x] Apply to HTTP send - [x] Apply to GRPC send ## Tangential - [x] Fallback to gRPC `v1` reflection (currently only `v1alpha`) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
adam added the pull-request label 2025-12-29 07:19:17 +01:00
adam closed this issue 2025-12-29 07:19:17 +01:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/yaak#90