[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[IDV #XAV-464552]: About authentication in IDV



Kin,

First off, thanks for setting up the temporary account. This allowed us to 
debug the problem.

Second, we have a fix for you. Please download and install the IDV nightly 
build:

http://www.unidata.ucar.edu/downloads/idv/nightly/index.jsp

Best regards,

-IDV Support

> Hi IDV Support and Yuan,
> Okay.  I asked my supervisor to create the temporary account for testing.
> Here is the information:
> 
> Username: idv
> Password: idv_password
> OPeNDAP server: http://apdrc.soest.hawaii.edu:80/dods/soest_only/SCUD/current
> 
> I also tried that in HttpClient.  It works fine.
> =========
> HttpClient client = new HttpClient();
> client.getState().setCredentials(new AuthScope("apdrc.soest.hawaii.edu", 80), 
> new UsernamePasswordCredentials("idv", "idv_password"));
> String str = "http://apdrc.soest.hawaii.edu:80/dods/soest_only/SCUD/current";;
> opendap.dap.DConnect2.setHttpClient(client);
> NetcdfDataset.setHttpClient(client);
> localNetcdfDataset = NetcdfDataset.openDataset(str);
> if (localNetcdfDataset == null) {
> System.out.println("Cant open URL");
> return;
> }
> =========
> 
> Thanks,
> Kin
> 
> > -----Original Message-----
> > From: Kin Lik Wang [mailto:address@hidden]
> > Sent: Thursday, June 16, 2011 9:02 AM
> > To: 'address@hidden'
> > Subject: RE: [IDV #XAV-464552]: About authentication in IDV
> >
> > Hi IDV Support and Yuan,
> >
> > >    The IDV used to support some sort of authentication through the
> > CDM
> > > library, but commented it out after CDM library switching to
> > httpclient
> > > 3.0. It would be helpful if you can provide a temporary account, so
> > we
> > > can figure out how much works need to finish to bring back this
> > > support.
> > >
> > > Yuan
> >
> > Okay, I will ask my supervisor to create a temporary account for our
> > OPeNDAP server.
> > Then you can test the basic authentication later.
> > I will let you know the temporary account information later.  Thank you
> > very much for helping.
> >
> > Also I think the httpclient is not too hard to add a basic
> > authentication.  I did something similar before.
> >
> > =============
> > import org.apache.commons.httpclient.HttpClient;
> > import org.apache.commons.httpclient.UsernamePasswordCredentials;
> > import org.apache.commons.httpclient.auth.AuthScope;
> > ...
> > HttpClient client = new HttpClient();
> > client.getState().setCredentials(new AuthScope("localhost", 80), new
> > UsernamePasswordCredentials("username", "password"));
> > String str = "http://localhost/dataset/category";;
> > opendap.dap.DConnect2.setHttpClient(client);
> > NetcdfDataset.setHttpClient(client);
> > localNetcdfDataset = NetcdfDataset.openDataset(str);
> > if (localNetcdfDataset == null) {
> >   System.out.println("Cant open URL");
> >   return;
> > }
> > ....
> > =============
> >
> > Thanks,
> >   Kin
> >
> > > -----Original Message-----
> > > From: Unidata IDV Support [mailto:address@hidden]
> > > Sent: Wednesday, June 15, 2011 5:32 PM
> > > To: address@hidden
> > > Cc: address@hidden
> > > Subject: [IDV #XAV-464552]: About authentication in IDV
> > >
> > > > Hi IDV Support,
> > > > Actually it is not a IDV program bug.
> > > > I just wonder does the IDV supporting basic authentication feature?
> > > > Since it gives CredentialsNotAvailableException error in the code.
> > > > I use other clients tool like Panoply and EDC.
> > > > Panoply: http://www.giss.nasa.gov/tools/panoply/
> > > > EDC: http://www.pfeg.noaa.gov/products/EDC/
> > > > They have a pop-up window to enter my username and password.
> > > >
> > > > Thanks,
> > > > Kin
> > >
> > > Hi Kin,
> > >    The IDV used to support some sort of authentication through the
> > CDM
> > > library, but commented it out after CDM library switching to
> > httpclient
> > > 3.0. It would be helpful if you can provide a temporary account, so
> > we
> > > can figure out how much works need to finish to bring back this
> > > support.
> > >
> > >
> > > Yuan
> > > >
> > > > > -----Original Message-----
> > > > > From: Unidata IDV Support [mailto:address@hidden]
> > > > > Sent: Wednesday, June 15, 2011 11:29 AM
> > > > > To: address@hidden
> > > > > Cc: address@hidden
> > > > > Subject: [IDV #XAV-464552]: About authentication in IDV
> > > > >
> > > > > Kin,
> > > > >
> > > > > It is difficult to diagnose this problem remotely. Would it be
> > > possible
> > > > > to obtain a temporary user name and password on this server so
> > that
> > > we
> > > > > can better address tackle this issue.
> > > > >
> > > > > Best regards,
> > > > >
> > > > > -The IDV Support Team
> > > > >
> > > > > > Full Name: Kin Wang
> > > > > > Email Address: address@hidden
> > > > > > Organization: IPRC, University of Hawaii
> > > > > > Package Version: 2.9u3 build date:2011-01-14 00:05 UTC
> > > > > > Operating System: Windows 7
> > > > > > Hardware: Java: home: C:\Program Files\IDV_2.9u3\jre version:
> > > > > 1.6.0_20 j3d:1.5.2 fcs (build4)
> > > > > > Description of problem: Hi IDV developers,
> > > > > > I have an error to open basic authentication access on OPeNDAP
> > > > > server.
> > > > > > ===================
> > > > > > There was an error loading the data:
> > > > > > Error creating data source:dods.grid with:
> > > > >
> > http://user:address@hidden:80/dods/iprc_only/JRA-
> > > > > 25/daily-clima-pressure
> > > > > > Grid data source failed making data set:
> > > > >
> > dods://user:address@hidden:80/dods/iprc_only/JRA-
> > > > > 25/daily-clima-pressure
> > > > > >
> > > org.apache.commons.httpclient.auth.CredentialsNotAvailableException:
> > > > > HTTP/1.1 401 Authorization Required
> > > > > > ==================
> > > > > > Do you think the future of IDV release allow basic
> > authentication
> > > > > access?
> > > > > >
> > > > > > Thanks,
> > > > > > Kin
> > > > > >
> > > > > > ******************
> > > > > > Stack trace:
> > > > > > java.io.IOException:
> > > > >
> > > org.apache.commons.httpclient.auth.CredentialsNotAvailableException:
> > > > > HTTP/1.1 401 Authorization Required
> > > > > > at ucar.nc2.dods.DODSNetcdfFile.<init>(DODSNetcdfFile.java:259)
> > > > > > at
> > > ucar.nc2.dataset.NetcdfDataset.acquireDODS(NetcdfDataset.java:781)
> > > > > > at
> > > > >
> > >
> > ucar.nc2.dataset.NetcdfDataset.openOrAcquireFile(NetcdfDataset.java:655
> > > > > )
> > > > > > at
> > > ucar.nc2.dataset.NetcdfDataset.openDataset(NetcdfDataset.java:425)
> > > > > > at
> > > > >
> > > ucar.nc2.dataset.NetcdfDataset.acquireDataset(NetcdfDataset.java:521)
> > > > > > at ucar.nc2.dt.grid.GridDataset.open(GridDataset.java:103)
> > > > > > at ucar.nc2.dt.grid.GridDataset.open(GridDataset.java:89)
> > > > > > at
> > > > >
> > >
> > ucar.unidata.data.grid.GeoGridDataSource.doMakeDataSet(GeoGridDataSourc
> > > > > e.java:1107)
> > > > > > at
> > > > >
> > >
> > ucar.unidata.data.grid.GeoGridDataSource.getDataset(GeoGridDataSource.j
> > > > > ava:1129)
> > > > > > at
> > > > >
> > >
> > ucar.unidata.data.grid.GeoGridDataSource.initAfterCreation(GeoGridDataS
> > > > > ource.java:491)
> > > > > > at
> > > > >
> > > ucar.unidata.data.DataManager.createDataSource(DataManager.java:1559)
> > > > > > at
> > > > >
> > >
> > ucar.unidata.idv.IntegratedDataViewer.createDataSource(IntegratedDataVi
> > > > > ewer.java:1998)
> > > > > > at
> > > > >
> > >
> > ucar.unidata.idv.IntegratedDataViewer.makeDataSource(IntegratedDataView
> > > > > er.java:1915)
> > > > > > at
> > > > >
> > >
> > ucar.unidata.idv.IntegratedDataViewer.makeDataSource(IntegratedDataView
> > > > > er.java:1849)
> > > > > > at
> > > > >
> > >
> > ucar.unidata.idv.IntegratedDataViewer.handleAction(IntegratedDataViewer
> > > > > .java:1691)
> > > > > > at
> > ucar.unidata.idv.DefaultIdv.handleAction(DefaultIdv.java:114)
> > > > > > at
> > > > >
> > >
> > ucar.unidata.idv.IntegratedDataViewer.handleAction(IntegratedDataViewer
> > > > > .java:1623)
> > > > > > at
> > > > >
> > > ucar.unidata.idv.chooser.UrlChooser.loadURLInner(UrlChooser.java:267)
> > > > > > at
> > > ucar.unidata.idv.chooser.UrlChooser.loadURL(UrlChooser.java:239)
> > > > > > at
> > > > >
> > >
> > ucar.unidata.idv.chooser.UrlChooser.doLoadInThread(UrlChooser.java:286)
> > > > > > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> > > > > > at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
> > > > > > at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown
> > > Source)
> > > > > > at java.lang.reflect.Method.invoke(Unknown Source)
> > > > > > at ucar.unidata.util.Misc$2.run(Misc.java:1063)
> > > > > > at ucar.unidata.util.Misc$3.run(Misc.java:1091)
> > > > > >
> > > > > >
> > > > > >
> > > > >
> > > > >
> > > > > Ticket Details
> > > > > ===================
> > > > > Ticket ID: XAV-464552
> > > > > Department: Support IDV
> > > > > Priority: Normal
> > > > > Status: Closed
> > > >
> > > >
> > >
> > >
> > > Ticket Details
> > > ===================
> > > Ticket ID: XAV-464552
> > > Department: Support IDV
> > > Priority: Normal
> > > Status: Open
> 
> 


Ticket Details
===================
Ticket ID: XAV-464552
Department: Support IDV
Priority: Normal
Status: Closed