-
Notifications
You must be signed in to change notification settings - Fork 37
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Login/Password issues TiddlyServer v2.2.0-beta-2 #107
Comments
Go to login attempted with unknown public key
<base64 encoded string>
username: test
timestamp: 2020-12-30T19:59:16.580Z Run the command Now add a new key to the authAccounts object. "authAccounts": {
"group name": { // << this is the "group" name such as "admin" or whatever you want
"clientKeys": {
"test": { // << this is the username you typed into the login form
"cookieSalt": "timestamp from command",
"publicKey": "<base64 encoded string>"
}
},
"permissions": {
"loginlink": true,
"mkdir": true,
"putsaver": true,
"registerNotice": true,
"upload": true,
"websockets": true,
"writeErrors": true,
"transfer": true,
"datafolder": true
}
}
}, After this, modify your tree option to look like this "tree": {
"$element": "group",
"$options": [
// the auth list array specifies which authAccounts groups are allowed to access this resource.
{ "$element": "auth", "authList": ["group name"]},
],
"$children": // << your original tree value goes here
} And then login again. Sorry it looks so messy. The tree is so much nicer in XML. <!-- the authList property is a JSON array -->
<tree>
<!-- this protects the entire tree -->
<auth authList='["group name"]' />
<folder path="/user/hello">
<!-- Allows an additional group. Both groups must be included here. -->
<auth authList='["group name", "other group]' />
</folder>
<group>
<!-- obviously unnecessary, only here for demonstration -->
<auth authList='["group name"]' />
<folder path="/user/hello">
<!-- this allows anyone to access this resource -->
<auth authList='null' />
</folder>
</group>
</tree> And then you just set the path to the XML as your tree option. |
I was looking over this code and I just realized instead of a JSON attribute, you can also do this. <auth>
<authList>group name</authList>
<authList>other group</authlist>
</auth> |
thank you. now I have a better understanding. |
I am having trouble getting into the tiddlywiki. I followed "Getting Started". Everything looks good, but I am having trouble finding out, where to set login and password. settings.json looks like this:
The text was updated successfully, but these errors were encountered: