File tree 3 files changed +9
-19
lines changed
3 files changed +9
-19
lines changed Original file line number Diff line number Diff line change 63
63
<span class =" help-block" >Your email will only be used for account recovery</span >
64
64
</div >
65
65
66
- <div class =" checkbox" >
67
- <label >
68
- <input type =" checkbox" name =" connectExternalWebId" value =" true" id =" ConnectExternalWebId" {{ #if connectExternalWebId }} checked{{ /if }} />
69
- Connect to External WebID (<strong >Advanced feature</strong >)
70
- </label >
71
- </div >
72
-
73
- <div class =" form-group hidden" id =" ExternalWebId" >
74
- <label class =" control-label" for =" externalWebId" >External WebID:</label >
75
- <input type =" text" class =" form-control" name =" externalWebId" id =" externalWebId" value =" {{ externalWebId }} " />
76
- <span class =" help-block" >
77
- By connecting this account with an existing WebID, you can use that WebID to authenticate with the new account.
78
- </span >
79
- </div >
80
-
81
66
{{ #if enforceToc }}
82
67
{{ #if tocUri }}
83
68
<div class =" checkbox" >
Original file line number Diff line number Diff line change @@ -144,7 +144,9 @@ class PasswordAuthenticator extends Authenticator {
144
144
error . statusCode = 400
145
145
throw error
146
146
}
147
-
147
+ if ( foundUser . link ) {
148
+ throw new Error ( 'Linked users not currently supported, sorry (external WebID without TLS?)' )
149
+ }
148
150
return this . userStore . matchPassword ( foundUser , this . password )
149
151
} )
150
152
. then ( validUser => {
Original file line number Diff line number Diff line change @@ -120,9 +120,7 @@ class CreateAccountRequest extends AuthRequest {
120
120
username : data . username ,
121
121
name : data . name ,
122
122
email : data . email ,
123
- externalWebId : data . externalWebId ,
124
- acceptToc : data . acceptToc ,
125
- connectExternalWebId : data . connectExternalWebId
123
+ acceptToc : data . acceptToc
126
124
} )
127
125
128
126
if ( error ) {
@@ -144,6 +142,11 @@ class CreateAccountRequest extends AuthRequest {
144
142
const userAccount = this . userAccount
145
143
const accountManager = this . accountManager
146
144
145
+ if ( userAccount . externalWebId ) {
146
+ const error = new Error ( 'Linked users not currently supported, sorry (external WebID without TLS?)' )
147
+ error . statusCode = 400
148
+ throw error
149
+ }
147
150
this . cancelIfUsernameInvalid ( userAccount )
148
151
this . cancelIfBlacklistedUsername ( userAccount )
149
152
await this . cancelIfAccountExists ( userAccount )
You can’t perform that action at this time.
0 commit comments