-
Notifications
You must be signed in to change notification settings - Fork 74
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
Improve service discovery, implement SD for CalDav #42
base: master
Are you sure you want to change the base?
Conversation
Test failure seems unrelated. |
serviceUrl := u.String() | ||
|
||
// Check if the resulting URL hosts a service | ||
req, err := http.NewRequest(http.MethodOptions, serviceUrl, nil) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
RFC 6764 section 6 mandates that a PROPFIND request should be made with the username/password set.
Alps has a different requirement: it needs to sanity check the URLs on startup (without any username/password).
To follow the RFC, we could:
- Take an
webdav.HTTPClient
to handle auth - Change OPTIONS to a PROPFIND request with a
DAV:current-user-principal
prop - Return the
DAV:current-user-principal
prop
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To accomodate for Alps, we could have an intermediate DiscoverContextURL
function that follows the RFC up to and not including the PROPFIND request.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for working on this! I left a few comments.
Sorry about the delay on this, I'll try to get the remaining change sorted this weekend. |
7e07625 adds discovery for CalDAV. What's still missing is the TXT DNS record stuff. |
See #30
This is my first time writing Go code, so I apologise in advance for any beginner mistakes I made in this 😃.