pdsinterop / test-suites

Test suites for protocols a Personal Data Store may support
https://pdsinterop.org/test-suites/
MIT License
2 stars 11 forks source link

obtaining a cookie for nextcloud-server #22

Closed michielbdejong closed 4 years ago

michielbdejong commented 4 years ago

The code in https://github.com/solid/webid-provider-tests/blob/master/test/surface/authorize-endpoint.test.ts#L8 was only tested on node-solid-server. I should have a version for nextcloud-server, including:

curl -ki https://localhost/login | grep requesttoken
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100  5524  100  5524    0     0  71740      0 --:--:-- --:--:-- --:--:-- 71740
 data-requesttoken="BAw3N1zas5Z8O8Z3dbH2tYhaHbSE963wtep3iLap+EU=:Vz1YZgS+mOxNS60cRdaRxu4tTuP0wMaE34IQsfTLkyI=">

and 'user' instead of 'username' in https://github.com/solid/webid-provider-tests/blob/master/test/surface/authorize-endpoint.test.ts#L13

michielbdejong commented 4 years ago

See https://github.com/solid/webid-provider-tests/issues/3

michielbdejong commented 4 years ago

In the docker image for nextcloud-server we can inject a php file that makes it easy to run https://github.com/nextcloud/server/blob/1762a409f954fd9a66e7572704ea9ba7813601b4/lib/private/Authentication/Login/CompleteLoginCommand.php#L40-L46 for instance https://server/apps/solid/dontDoThisAtHome.php?user=alice&password=alice123

michielbdejong commented 4 years ago

This is a variation on @poef's https://github.com/pdsinterop/solid-nextcloud/blob/master/solid/lib/Controller/ServerController.php#L193-L201 but I think we can keep it outside the Solid app and just inject it into the Docker image at the test-suites level.

I will need this for https://github.com/pdsinterop/test-suites/tree/master/testers/open-cloud-mesh as well, btw! :)