jackrabbit-oak-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tommaso Teofili (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (OAK-2473) ACL checks on suggestions
Date Fri, 06 Feb 2015 14:51:34 GMT

    [ https://issues.apache.org/jira/browse/OAK-2473?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14309240#comment-14309240
] 

Tommaso Teofili commented on OAK-2473:
--------------------------------------

and the same applies for Solr:
{code}
       for (SimpleOrderedMap<Object> suggestion : retrievedSuggestions) {
                                    SolrQuery solrQuery = new SolrQuery();
                                    solrQuery.setParam("q", String.valueOf(suggestion.get("term")));
                                    solrQuery.setParam("df", configuration.getCatchAllField());
                                    // ...
                                    QueryResponse suggestQueryResponse = solrServer.query(solrQuery);
                                    SolrDocumentList results = suggestQueryResponse.getResults();
                                    if (results != null && results.getNumFound() >
0) {
                                        for (SolrDocument doc : results) {
                                            if (exists(String.valueOf(doc.getFieldValue(configuration.getPathField())),
root)) {
                                                fakeDoc.addField(QueryImpl.REP_SUGGEST, "{term="
+ suggestion.get("term") + ",weight=" + suggestion.get("weight") + "}");
                                                break;
                                            }
                                        }
                                    }
                                }
{code}

> ACL checks on suggestions
> -------------------------
>
>                 Key: OAK-2473
>                 URL: https://issues.apache.org/jira/browse/OAK-2473
>             Project: Jackrabbit Oak
>          Issue Type: Sub-task
>          Components: oak-lucene, oak-solr, query
>            Reporter: Tommaso Teofili
>             Fix For: 1.1.7
>
>         Attachments: OAK-2473.0.patch
>
>
> Support for ACL check suggestions needs to be added to avoid providing suggestions coming
from index data whose source nodes / properties were not meant to be readable from the calling
user.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message