feat: import upstream ZITADEL Login V2 v4.20.4 source workspace
This commit is contained in:
1 parent
eadd0e558b
commit
4404849fc4
644 files changed
+153201
-10
No files matched your search
@@ -0,0 +1,82 @@
|
||||
syntax = "proto3";
|
||||
|
||||
package zitadel.session.v2beta;
|
||||
|
||||
import "google/api/field_behavior.proto";
|
||||
import "google/protobuf/struct.proto";
|
||||
import "protoc-gen-openapiv2/options/annotations.proto";
|
||||
import "validate/validate.proto";
|
||||
|
||||
option go_package = "github.com/zitadel/zitadel/pkg/grpc/session/v2beta;session";
|
||||
|
||||
enum UserVerificationRequirement {
|
||||
USER_VERIFICATION_REQUIREMENT_UNSPECIFIED = 0;
|
||||
USER_VERIFICATION_REQUIREMENT_REQUIRED = 1;
|
||||
USER_VERIFICATION_REQUIREMENT_PREFERRED = 2;
|
||||
USER_VERIFICATION_REQUIREMENT_DISCOURAGED = 3;
|
||||
}
|
||||
|
||||
message RequestChallenges {
|
||||
message WebAuthN {
|
||||
string domain = 1 [
|
||||
(validate.rules).string = {min_len: 1, max_len: 200},
|
||||
(google.api.field_behavior) = REQUIRED,
|
||||
(grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field) = {
|
||||
description: "\"Domain on which the session was created. Will be used in the WebAuthN challenge.\"";
|
||||
}
|
||||
];
|
||||
UserVerificationRequirement user_verification_requirement = 2 [
|
||||
(validate.rules).enum = {
|
||||
defined_only: true,
|
||||
not_in: [0]
|
||||
},
|
||||
(google.api.field_behavior) = REQUIRED,
|
||||
(grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field) = {
|
||||
description: "\"User verification that is required during validation. When set to `USER_VERIFICATION_REQUIREMENT_REQUIRED` the behaviour is for passkey authentication. Other values will mean U2F\"";
|
||||
ref: "https://www.w3.org/TR/webauthn/#enum-userVerificationRequirement";
|
||||
}
|
||||
];
|
||||
}
|
||||
message OTPSMS {
|
||||
bool return_code = 1;
|
||||
}
|
||||
message OTPEmail {
|
||||
message SendCode {
|
||||
optional string url_template = 1 [
|
||||
(validate.rules).string = {min_len: 1, max_len: 200},
|
||||
(grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field) = {
|
||||
min_length: 1;
|
||||
max_length: 200;
|
||||
example: "\"https://example.com/otp/verify?userID={{.UserID}}&code={{.Code}}\"";
|
||||
description: "\"Optionally set a url_template, which will be used in the mail sent by Zitadel to guide the user to your verification page. If no template is set, the default Zitadel url will be used.\""
|
||||
}
|
||||
];
|
||||
}
|
||||
message ReturnCode {}
|
||||
|
||||
// if no delivery_type is specified, an email is sent with the default url
|
||||
oneof delivery_type {
|
||||
SendCode send_code = 2;
|
||||
ReturnCode return_code = 3;
|
||||
}
|
||||
}
|
||||
|
||||
optional WebAuthN web_auth_n = 1;
|
||||
optional OTPSMS otp_sms = 2;
|
||||
optional OTPEmail otp_email = 3;
|
||||
}
|
||||
|
||||
message Challenges {
|
||||
message WebAuthN {
|
||||
google.protobuf.Struct public_key_credential_request_options = 1 [
|
||||
(grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field) = {
|
||||
description: "Options for Assertion Generaration (dictionary PublicKeyCredentialRequestOptions). Generated helper methods transform the field to JSON, for use in a WebauthN client. See also: https://www.w3.org/TR/webauthn/#dictdef-publickeycredentialrequestoptions"
|
||||
example: "{\"publicKey\":{\"allowCredentials\":[{\"id\":\"ATmqBg-99qyOZk2zloPdJQyS2R7IkFT7v9Hoos_B_nM\",\"type\":\"public-key\"}],\"challenge\":\"GAOHYz2jE69kJMYo6Laij8yWw9-dKKgbViNhfuy0StA\",\"rpId\":\"localhost\",\"timeout\":300000,\"userVerification\":\"required\"}}"
|
||||
}
|
||||
];
|
||||
}
|
||||
|
||||
optional WebAuthN web_auth_n = 1;
|
||||
optional string otp_sms = 2;
|
||||
optional string otp_email = 3;
|
||||
}
|
||||
Reference in new issue
Block a user