I'm running jar-file as follows:

/usr/bin/java -Dlog4j.configuration=file:log4j.properties -Xmx5600M -jar fuseki-server.jar --update --port 3030 --config=config.ttl

Also tried passwd with file: and without, so

[] rdf:type fuseki:Server ;
   fuseki:passwd "file:///tmp/passwdfile";
   fuseki:auth   "basic" ;
   fuseki:allowedUsers "*";

and

[] rdf:type fuseki:Server ;
   fuseki:passwd "/tmp/passwdfile";
   fuseki:auth   "basic" ;
   fuseki:allowedUsers "*";

and same folder as config.ttl

[] rdf:type fuseki:Server ;
   fuseki:passwd "passwdfile";
   fuseki:auth   "basic" ;
   fuseki:allowedUsers "*";


I'm posting application/sparql-query to default dataset.



On 29/04/2019 20:01, Andy Seaborne wrote:
Are you running the war file, full server jar with UI?  That stiul uses shiro.ini.

The data-access-control.html applies to Fuseki Main.

3.10.0 works for me.

[] rdf:type fuseki:Server ;
   fuseki:passwd "passwdFile";
   fuseki:auth   "basic" ;
   fuseki:allowedUsers "*";
   .

    Andy


On 29/04/2019 16:26, Mikael Pesonen wrote:

Entire config.ttl:

@prefix :<http://localhost/jena_example/#>  .
@prefix rdf:<http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs:<http://www.w3.org/2000/01/rdf-schema#>  .
@prefix tdb:<http://jena.hpl.hp.com/2008/tdb#>  .
@prefix ja:<http://jena.hpl.hp.com/2005/11/Assembler#>  .
@prefix text:<http://jena.apache.org/text#>  .
@prefix skos:<http://www.w3.org/2004/02/skos/core#>
@prefix fuseki:<http://jena.apache.org/fuseki#>  .

## Example of a TDB dataset and text index
## Initialize TDB
[] ja:loadClass "org.apache.jena.tdb.TDB" .
tdb:DatasetTDB  rdfs:subClassOf  ja:RDFDataset .
tdb:GraphTDB    rdfs:subClassOf  ja:Model .

## Initialize text query
[] ja:loadClass       "org.apache.jena.query.text.TextQuery" .
# A TextDataset is a regular dataset with a text index.
text:TextDataset      rdfs:subClassOf   ja:RDFDataset .
# Lucene index
text:TextIndexLucene  rdfs:subClassOf   text:TextIndex .


## ---------------------------------------------------------------


:text_dataset rdf:type     text:TextDataset ;
      text:dataset   :my_dataset ;
      text:index     <#indexLucene> ;
      .

# A TDB dataset used for RDF storage
:my_dataset rdf:type      tdb:DatasetTDB ;
      tdb:location "..." ;
#    tdb:unionDefaultGraph true ; # Optional
      .

# Text index description
<#indexLucene> a text:TextIndexLucene ;
      text:directory <...>  ;
      text:entityMap <#entMap> ;
      text:storeValues true ;
      text:analyzer [ a text:StandardAnalyzer ] ;
      text:queryAnalyzer [ a text:KeywordAnalyzer ] ;
      text:queryParser text:AnalyzingQueryParser ;
      text:multilingualSupport true ;
   .

<#entMap> a text:EntityMap ;
      text:defaultField     "prefLabel" ;
      text:entityField      "uri" ;
      text:uidField         "uid" ;
      text:langField        "lang" ;
      text:graphField       "graph" ;
      text:map (
           [ text:field "prefLabel" ; text:predicate skos:prefLabel ]
           [ text:field "altLabel"  ; text:predicate skos:altLabel ]
           ) .

<#server> rdf:type fuseki:Server ;
      fuseki:passwd  "..." ;
      fuseki:auth    "basic" ;
      fuseki:allowedUsers    "*" ;
      fuseki:services (<#service>) ;
      .

<#service> rdf:type fuseki:Service ;
      fuseki:name                     "/ds" ;   # http://host:port/ds-ro
      fuseki:serviceQuery             "query" ;    # SPARQL query service       fuseki:serviceQuery             "sparql" ;   # SPARQL query service       fuseki:serviceUpdate            "update" ;   # SPARQL update service       fuseki:serviceUpload            "upload" ;   # Non-SPARQL upload service       fuseki:serviceReadWriteGraphStore "data" ;     # SPARQL Graph store protocol (read and write)
      fuseki:dataset           :text_dataset ;
      .

On 29/04/2019 18:09, Andy Seaborne wrote:

On 29/04/2019 15:42, Mikael Pesonen wrote:

I'm using Fuseki 3.10.0 and following this guide: http://jena.staging.apache.org/documentation/fuseki2/data-access-control.html#authentication


http://jena.apache.org/documentation/fuseki2/data-access-control.html#authentication



Fuseki server doesnt recognize --passwd from command line, and adding this

<#server> rdf:type fuseki:Server ;
      fuseki:passwd  "path to passwd file" ;
      fuseki:auth    "basic" .

Try adding

    fuseki:allowedUsers  "*";

to the <#server>

Oddly, I found this quite recently and am looking at it right now.

    Andy


to config.ttl doesn't make Fuseki to require login.

Are there some additional steps to make?

BR





--
Lingsoft - 30 years of Leading Language Management

www.lingsoft.fi

Speech Applications - Language Management - Translation - Reader's and Writer's 
Tools - Text Tools - E-books and M-books

Mikael Pesonen
System Engineer

e-mail: mikael.peso...@lingsoft.fi
Tel. +358 2 279 3300

Time zone: GMT+2

Helsinki Office
Eteläranta 10
FI-00130 Helsinki
FINLAND

Turku Office
Kauppiaskatu 5 A
FI-20100 Turku
FINLAND

Reply via email to