@ldf/feature-webid
v3.2.1
Published
Linked Data Fragments Server - WebID
Downloads
13
Readme
Linked Data Fragments Server - WebID
This module adds a controller extension that only allows authenticated client with WebID's to perform requests. This extension will only be active when the server is running in https-mode.
This package is not included by default in @ldf/server
and @ldf/preset-qpf
.
This package is a Linked Data Fragments Server module.
Usage in other packages
When this module is used in a package,
then the JSON-LD context
https://linkedsoftwaredependencies.org/contexts/@ldf/feature-webid.jsonld` must be imported.
This package exposes the following config entries:
WebIdControllerExtension
: Extends Quad Pattern Fragments responses with WebID authentication. Should be used as@type
value.
Next to adding the WebID controller extension, you must enable HTTPS-mode, as shown in the example below.
For example:
{
"@context": [
"https://linkedsoftwaredependencies.org/bundles/npm/@ldf/core/^3.0.0/components/context.jsonld",
"https://linkedsoftwaredependencies.org/bundles/npm/@ldf/preset-qpf/^3.0.0/components/context.jsonld",
"https://linkedsoftwaredependencies.org/bundles/npm/@ldf/feature-webid/^3.0.0/components/context.jsonld",
],
"@id": "urn:ldf-server:my",
"import": "preset-qpf:config-defaults.json",
"controllers": [
{
"@id": "urn:ldf-server:myQuadPatternFragmentsController", // This should refer to your existing QuadPatternFragmentsController
"@type": "QuadPatternFragmentsController",
"qpfControllerExtension": {
"@id": "urn:ldf-server:myWebIdControllerExtension",
"@type": "WebIdControllerExtension"
}
}
],
"protocol": "https"
}
License
The Linked Data Fragments server is written by Ruben Verborgh, Miel Vander Sande, Ruben Taelman and colleagues.
This code is copyrighted by Ghent University – imec and released under the MIT license.