Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AuthenticationException{message=Unauthorized, status=401} #510

Closed
lelea2 opened this issue Nov 22, 2015 · 2 comments
Closed

AuthenticationException{message=Unauthorized, status=401} #510

lelea2 opened this issue Nov 22, 2015 · 2 comments

Comments

@lelea2
Copy link

lelea2 commented Nov 22, 2015

Hi I'm new to openstack and try to follow some example to authenticate

import org.openstack4j.api.Builders;
import org.openstack4j.api.OSClient;
import org.openstack4j.model.compute.Action;
import org.openstack4j.model.compute.Flavor;
import org.openstack4j.model.compute.FloatingIP;
import org.openstack4j.model.compute.Image;
import org.openstack4j.model.compute.Server;
import org.openstack4j.model.compute.ServerCreate;
import org.openstack4j.model.network.Network;
import org.openstack4j.openstack.OSFactory;
import org.openstack4j.model.identity.Tenant;

.....

OSClient os = OSFactory.builder()
                       .endpoint("http://127.0.0.1:5000/v2.0")
                       .credentials("admin","sample")
                       .tenantName("admin")
                       .authenticate();

....

I have my pom.xml

org.pacesys
openstack4j
2.0.9

However i get the message as above, any idea what i could do wrong here?

Thank you
Kareen

@symcssn
Copy link
Contributor

symcssn commented Nov 22, 2015

Are you able to authenticate with the same credentials for tenant "admin" using curl?

@vinodborole
Copy link
Contributor

@lelea2 please reopen if this issue still exists

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants