Skip to content

Commit 1a10760

Browse files
authored
Merge pull request #1044 from solid/case/acls-with-dot-acls
Test that fails when accessTo is set wrong
2 parents e1b6dfb + 672d89e commit 1a10760

File tree

2 files changed

+17
-0
lines changed

2 files changed

+17
-0
lines changed

test/integration/acl-oidc-test.js

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -879,4 +879,15 @@ describe('ACL with WebID+OIDC over HTTP', function () {
879879
rm('/accounts-acl/tim.localhost/write-acl/default-for-new/test-file.ttl')
880880
})
881881
})
882+
883+
describe('Wrongly set accessTo', function () {
884+
it('user1 should be able to access test directory', function (done) {
885+
var options = createOptions('/dot-acl/', 'user1')
886+
request.head(options, function (error, response, body) {
887+
assert.equal(error, null)
888+
assert.equal(response.statusCode, 403)
889+
done()
890+
})
891+
})
892+
})
882893
})
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
@prefix acl: <http://www.w3.org/ns/auth/acl#>.
2+
3+
<#DotAcl> a acl:Authorization ;
4+
acl:accessTo <./.acl> ;
5+
acl:agent <https://tim.localhost:7777/profile/card#me> ;
6+
acl:mode acl:Read .

0 commit comments

Comments
 (0)