<docbook><section><title>VirtTipsAndTricksInsDelSPARQLSSL</title><title> How Can I execute INSERT/DELETE (SPARUL) statements against a WebID protected SPARQL endpoint?</title> How Can I execute INSERT/DELETE (SPARUL) statements against a <ulink url="WebID">WebID</ulink> protected SPARQL endpoint?
<para>The following sample scenario demonstrates how to perform INSERT/DELETE (SPARUL) statements against a protected SPARQL Endpoint by setting <ulink url="WebID">WebID</ulink> Protocol ACLs using the Virtuoso Authentication Server UI:</para>
<orderedlist spacing="compact"><listitem>Obtain a <ulink url="WebID">WebID</ulink>: <orderedlist spacing="compact"><listitem>Download and install the <ulink url="https://virtuoso.openlinksw.com/download/">ods_framework_dav.vad</ulink>.
<itemizedlist mark="bullet" spacing="compact"><listitem>Note: an existing ODS <ulink url="DataSpace">DataSpace</ulink> user instance can also be used, for example at <ulink url="http://id.myopenlink.net/ods/">http://id.myopenlink.net/ods/</ulink> </listitem>
</itemizedlist></listitem>
<listitem>Register an ODS Data Space user, for example with name &quot;demo&quot;.
</listitem>
<listitem>The generated <ulink url="WebID">WebID</ulink> will be for example: <programlisting>http://id.myopenlink.net/dataspace/person/demo#this 
</programlisting></listitem>
<listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/ODSGenerateX509Certificate">Generate a Personal HTTP based Identifier</ulink> for the &quot;demo&quot; user and then bind the personal Identifier to an X.509 Certificate, thereby giving assigning the user a <ulink url="WebID">WebID</ulink>.
</listitem>
</orderedlist></listitem>
<listitem>Download and install the <emphasis><ulink url="https://virtuoso.openlinksw.com/download/"> conductor_dav.vad</ulink></emphasis> package, if not already installed.
</listitem>
<listitem>Go to <emphasis>http://&lt;cname&gt;:&lt;port&gt;/conductor</emphasis>, where &lt;cname&gt;:&lt;port&gt; are replaced by your local server values.
</listitem>
<listitem>Go to System Admin -&gt; Linked Data -&gt; Access Control -&gt; SPARQL-<ulink url="WebID">WebID</ulink> <figure><graphic fileref="VirtTipsAndTricksInsDelSPARQLSSL/si1.png" /></figure> </listitem>
<listitem>In the displayed form: <orderedlist spacing="compact"><listitem>Enter the Web ID for the user registered above, for example: <programlisting>http://id.myopenlink.net/dataspace/person/demo#this
</programlisting></listitem>
<listitem>Select &quot;<emphasis>SPARQL Role</emphasis>&quot;: &quot;<emphasis>UPDATE</emphasis>&quot;.
<figure><graphic fileref="VirtTipsAndTricksInsDelSPARQLSSL/si2.png" /></figure> </listitem>
</orderedlist></listitem>
<listitem>Click the &quot;<emphasis>Register</emphasis>&quot; button.
</listitem>
<listitem>The <ulink url="WebID">WebID</ulink> Protocol ACL will be created: <figure><graphic fileref="VirtTipsAndTricksInsDelSPARQLSSL/si3.png" /></figure> </listitem>
<listitem>Go to the SPARQL+<ulink url="WebID">WebID</ulink> endpoint, https://&lt;cname&gt;:&lt;port&gt;/sparql-webid, where &lt;cname&gt;:&lt;port&gt; are replaced by your local server values.
</listitem>
<listitem>Select the user&#39;s certificate: <figure><graphic fileref="VirtTipsAndTricksInsDelSPARQLSSL/si4.png" /></figure> </listitem>
<listitem>The SPARQL Query UI will be displayed: <figure><graphic fileref="VirtTipsAndTricksInsDelSPARQLSSL/si5.png" /></figure> </listitem>
<listitem>Execute the query: <programlisting>INSERT INTO GRAPH &lt;http://mytest.com&gt; {
  &lt;s1&gt; &lt;p1&gt; &lt;o1&gt; .
  &lt;s2&gt; &lt;p2&gt; &lt;o2&gt; .
  &lt;s3&gt; &lt;p3&gt; &lt;o3&gt; 
}
</programlisting><figure><graphic fileref="VirtTipsAndTricksInsDelSPARQLSSL/si6.png" /></figure> <figure><graphic fileref="VirtTipsAndTricksInsDelSPARQLSSL/si7.png" /></figure></listitem>
</orderedlist><para> Note: If the SPARQL Role &quot;Sponge&quot; is set instead, in order to be able to execute DELETE/INSERT statements over the protected SPARQL Endpoint,  the following grants need to be performed for the user, associated with the <ulink url="WebID">WebID</ulink> ACL Role:</para>
<programlisting>grant execute on DB.DBA.SPARQL_INSERT_DICT_CONTENT to &quot;demo&quot;;
grant execute on DB.DBA.SPARQL_DELETE_DICT_CONTENT to &quot;demo&quot;;
</programlisting><bridgehead class="http://www.w3.org/1999/xhtml:h3">References</bridgehead>
 <itemizedlist mark="bullet" spacing="compact"><listitem><ulink url="VirtSPARQLEndpointProtection">Safeguarding your Virtuoso-hosted SPARQL Endpoint</ulink> </listitem>
<listitem><ulink url="VirtTipsAndTricksGuideSPARQLEndpointProtection">SPARQL Endpoint Protection Methods Collection</ulink> </listitem>
<listitem><ulink url="http://docs.openlinksw.com/virtuoso/">Virtuoso documentation</ulink> <itemizedlist mark="bullet" spacing="compact"><listitem><ulink url="http://docs.openlinksw.com/virtuoso/rdfsparql.html#rdfsupportedprotocolendpoint">SPARQL Service Endpoint</ulink> </listitem>
<listitem><ulink url="http://docs.openlinksw.com/virtuoso/rdfsparql.html#rdfsupportedprotocolendpointuri">Service Endpoint Security</ulink> </listitem>
<listitem><ulink url="http://docs.openlinksw.com/virtuoso/rdfsparql.html#sparqwebservicetbl">Managing a SPARQL Web Service Endpoint</ulink> </listitem>
<listitem><ulink url="http://docs.openlinksw.com/virtuoso/rdfsparql.html">SPARQL</ulink> </listitem>
</itemizedlist></listitem>
<listitem><ulink url="VirtTipsAndTricksGuide">Virtuoso Tips and Tricks Collection</ulink> <itemizedlist mark="bullet" spacing="compact"><listitem><ulink url="VirtSPARQLDET">SPARQL Endpoint DET Configuration Guide</ulink> </listitem>
<listitem><ulink url="VirtSPARQLSecurityWebID">WebID Protocol &amp; SPARQL Endpoint ACLs Tutorial</ulink> </listitem>
<listitem><ulink url="VirtOAuthSPARQL">SPARQL OAuth Tutorial</ulink> </listitem>
<listitem><ulink url="VirtTipsAndTricksGuideSPARQLEndpoints">Securing SPARQL endpoints</ulink> </listitem>
</itemizedlist></listitem>
<listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/OdsSPARQLAuth">SPARUL over SPARQL using the http://cname:port/sparql-auth endpoint</ulink> </listitem>
<listitem><ulink url="VirtAuthServerUI">Virtuoso Authentication Server UI</ulink> </listitem>
<listitem><ulink url="VirtSPARQLSSL">Manage a SPARQL-WebID based Endpoint</ulink> </listitem>
<listitem><ulink url="VirtSetupSSL">Configure Virtuoso instance as an X.509 Certificate Authority and HTTPS listener</ulink> </listitem>
<listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/ODSSetupSSL">Configure Virtuoso+ODS instance as an X.509 Certificate Authority and HTTPS listener</ulink> </listitem>
<listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/VirtODSSecurityWebID">WebID Protocol Support in OpenLink Data Spaces</ulink>.
</listitem>
<listitem>Manage ODS Datadspaces Objects <ulink url="WebID">WebID</ulink> Access Control Lists (ACLs): <itemizedlist mark="bullet" spacing="compact"><listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/ODSBriefcaseWebID">ODS Briefcase WebID based ACL Guide</ulink> <itemizedlist mark="bullet" spacing="compact"><listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/ODSBriefcaseWebIDPerson">Person Entity WebID based ACL Guide</ulink> </listitem>
<listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/ODSBriefcaseWebIDGroup">Group Entity WebID based ACL Guide</ulink> </listitem>
<listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/ODSBriefcaseWebIDPublic">Public WebID based ACL Guide</ulink> </listitem>
</itemizedlist></listitem>
<listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/ODSFeedManagerWebIDACL">ODS Feed Manager WebID based ACL Guide</ulink> <itemizedlist mark="bullet" spacing="compact"><listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/ODSFeedManagerWebIDACLPerson">Person Entity Specific ACL</ulink> </listitem>
<listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/ODSFeedManagerWebIDACLGroup">Group Entity Specific ACL</ulink> </listitem>
<listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/ODSFeedManagerWebIDACLPublic">Public Specific ACL for anyone with a WebID</ulink> </listitem>
</itemizedlist></listitem>
<listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/ODSCalendarWebIDACL">ODS Calendar WebID based ACL Guide</ulink> <itemizedlist mark="bullet" spacing="compact"><listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/ODSCalendarWebIDACLPerson">Person Entity Specific ACL</ulink> </listitem>
<listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/ODSCalendarWebIDACLGroup">Group Entity Specific ACL</ulink> </listitem>
<listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/ODSCalendarWebIDACLPublic">Public Specific ACL for anyone with a WebID</ulink> </listitem>
</itemizedlist></listitem>
<listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/ODSBookmarksWebIDACL">ODS Bookmark Manager WebID based ACL Guide</ulink> <itemizedlist mark="bullet" spacing="compact"><listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/ODSBookmarksWebIDACLPerson">Person Entity Specific ACL</ulink> </listitem>
<listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/ODSBookmarksWebIDACLGroup">Group Entity Specific ACL</ulink> </listitem>
<listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/ODSBookmarksWebIDACLPublic">Public Specific ACL for anyone with a WebID</ulink> </listitem>
</itemizedlist></listitem>
<listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/ODSAddressBookWebIDACL">ODS Addressbook  WebID based ACL Guide</ulink> <itemizedlist mark="bullet" spacing="compact"><listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/ODSAddressBookWebIDACLPerson">Person Entity Specific ACL</ulink> </listitem>
<listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/ODSAddressBookWebIDACLGroup">Group Entity Specific ACL</ulink> </listitem>
<listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/ODSAddressBookWebIDACLPublic">Public Specific ACL for anyone with a WebID</ulink> </listitem>
</itemizedlist></listitem>
</itemizedlist></listitem>
<listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/ODSPkiSetup">Guide for Set up a X.509 certificate issuer and HTTPS listener and generate ODS user certificates.</ulink> </listitem>
<listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/VirtODSPubSubHub">Setting up PubSubHub in ODS</ulink> </listitem>
<listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/VirtPubSubHub">PubSubHubBub Demo Client Example</ulink> </listitem>
<listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/VirtFeedPubSubHub">Feed subscription via PubSubHub protocol Example</ulink> </listitem>
<listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/VirtPubSubHubACL">Setting Up PubSubHub to use WebID Protocol or IP based control lists</ulink> </listitem>
<listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/OdsKeyImport">CA Keys Import using Conductor</ulink> </listitem>
<listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/ODSGenerateX509Certificate">Generate an X.509 Certificate hosted WebID Guide</ulink> </listitem>
<listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/ODSGenerateWebIDX509CertOSKeystore">Generate an X.509 Certificate (with a WebID watermark) to be managed by host operating system keystore</ulink> </listitem>
<listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/ODSGenerateWebIDX509CertBrsKeystore">Generate an X.509 Certificate (with a WebID watermark) to be managed by a browser-based keystore</ulink> </listitem>
<listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/ODSWebIDIdP">Using Virtuoso&#39;s WebID Verification Proxy Service with a WebID-bearing X.509 certificate</ulink> </listitem>
<listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/ODSWebIDIdpProxy">Using Virtuoso&#39;s WebID Identity Provider (IdP) Proxy Service with an X.509 certificate</ulink> </listitem>
<listitem><ulink url="http://ods.openlinksw.com/wiki/ODS/ODSBriefcaseWebIDShareFile">ODS Briefcase WebID Protocol Share File Guide</ulink> </listitem>
<listitem><ulink url="http://esw.w3.org/topic/foaf+ssl">WebID Protocol Specification</ulink> </listitem>
<listitem><ulink url="https://foaf.me/simpleLogin.php">Test WebID Protocol Certificate page</ulink> </listitem>
<listitem><ulink url="http://test.foafssl.org/cert/">WebID Protocol Certificate Generation page</ulink></listitem>
</itemizedlist></section></docbook>