Révision 19b58bab
Ajouté par Remy Menard il y a plus de 11 ans
ETa/User/src/main/java/fr/unicaen/iota/eta/user/UserOperationsWebService.java | ||
---|---|---|
/*
|
||
* This program is a part of the IoTa Project.
|
||
* This program is a part of the IoTa project.
|
||
*
|
||
* Copyright © 2011-2012 Université de Caen Basse-Normandie, GREYC
|
||
* Copyright © 2011-2013 Université de Caen Basse-Normandie, GREYC
|
||
* Copyright © 2011 Orange Labs
|
||
*
|
||
* This program is free software: you can redistribute it and/or modify
|
||
... | ... | |
}
|
||
|
||
@Override
|
||
public UserLoginOut userLogin(UserLoginIn parms)
|
||
public UserLoginOut userBasicLogin(UserBasicLoginIn parms)
|
||
throws ImplementationExceptionResponse, SecurityExceptionResponse {
|
||
if (parms.getUserID() == null || parms.getPassword() == null) {
|
||
String msg = "A parameter is missing.";
|
||
... | ... | |
throw ier;
|
||
}
|
||
UserLoginOut out = new UserLoginOut();
|
||
User user = userModule.userLogin(parms.getUserID(), parms.getPassword());
|
||
User user = userModule.userBasicLogin(parms.getUserID(), parms.getPassword());
|
||
out.setSessionLease(Constants.SESSION_TIME_LEASE);
|
||
String sessionId = Session.openSession(user);
|
||
out.setSid(sessionId);
|
||
return out;
|
||
}
|
||
|
||
@Override
|
||
public UserLoginOut userCertLogin(UserCertLoginIn parms)
|
||
throws ImplementationExceptionResponse, SecurityExceptionResponse {
|
||
if (parms.getUserID() == null) {
|
||
String msg = "A parameter is missing.";
|
||
ImplementationException ie = new ImplementationException();
|
||
ie.setReason(msg);
|
||
ie.setQueryName("userLogin");
|
||
ie.setSeverity(ImplementationExceptionSeverity.ERROR);
|
||
ImplementationExceptionResponse ier = new ImplementationExceptionResponse(msg, ie);
|
||
LOG.error(msg, ier);
|
||
throw ier;
|
||
}
|
||
UserLoginOut out = new UserLoginOut();
|
||
User user = userModule.userCertLogin(parms.getUserID());
|
||
out.setSessionLease(Constants.SESSION_TIME_LEASE);
|
||
String sessionId = Session.openSession(user);
|
||
out.setSid(sessionId);
|
Formats disponibles : Unified diff
Version 1.9
- use TLS for secured links
- SigMa is now fully functionnal
- completed documention
- a lot of bugs fixed!
- signature creation from the canonical form of the event
- signature creation using ECDSA algorithm
- signature is correctly verified
- manage the extension identifying the owner of the event
- if no identity is provided, the identity of the certificate is used
- access to the web interface of policy management is made by
certificate
- if no identity is provided, the identity of the certificate is used
- create and use certificates for TLS
- configure Apache Tomcat for TLS
- show SigMa library (SigMa-Commons)