incubator-couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Martin Minka <martin.mi...@gmail.com>
Subject Re: CouchDB returning data filtered by userCtx.name
Date Fri, 20 Jun 2014 09:16:51 GMT
yes, but this will not enforce security, because anybody could pass any
username without to authenticate first.

this would be an acceptable way if it is possible to write some validation
function which will compare the parameter with ctxUser.name before running
the view query.
is it possible to write such validation function ?


2014-06-20 11:04 GMT+02:00 Gowtham Tamizharasan <
gowtham.tamizharasan@inmobi.com>:

> Hi Martin,
>
> You could query a view function based on "key". so you can query like
> _view/myaccount?key="<user
> name>"
>
> In your View emit key as the user name.
>
>
>
> On Fri, Jun 20, 2014 at 12:02 PM, Martin Minka <martin.minka@gmail.com>
> wrote:
>
> > I am using CouchDB v1.4.0.
> >
> > Is followin doable in CouchDB ?
> > Client application will access CouchDB directly, client will authenticate
> > against CouchDB and request data from _view/myaccount, the data should be
> > filtered for userCtx.name.
> >
> > If user name has to be parameter for _view/myaccount is it possible to
> > validate it against userCtx.name ?
> >
> > Or do I have to use some other server level software to proxy requests
> > against CouchDB ?
> >
> > Thank you,
> > Martin
> >
>
> --
> _____________________________________________________________
> The information contained in this communication is intended solely for the
> use of the individual or entity to whom it is addressed and others
> authorized to receive it. It may contain confidential or legally privileged
> information. If you are not the intended recipient you are hereby notified
> that any disclosure, copying, distribution or taking any action in reliance
> on the contents of this information is strictly prohibited and may be
> unlawful. If you have received this communication in error, please notify
> us immediately by responding to this email and then delete it from your
> system. The firm is neither liable for the proper and complete transmission
> of the information contained in this communication nor for any delay in its
> receipt.
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message