security fix
This commit is contained in:
parent
5f72cc4323
commit
05274985da
|
@ -36,12 +36,13 @@ public interface SyncEngine {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Checked Access Method
|
* Checked Access Method
|
||||||
* @throws InternalException
|
|
||||||
* @throws WorkspaceInteractionException
|
|
||||||
*/
|
*/
|
||||||
public void stopSynch(String folderId) throws ProcessNotFoundException, WorkspaceInteractionException, InternalException;
|
public void stopSynch(String folderId) throws ProcessNotFoundException, WorkspaceInteractionException, InternalException;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Checked Access Method
|
||||||
|
*/
|
||||||
public void setSynchronizedFolder(SynchFolderConfiguration config,String folderId) throws WorkspaceInteractionException, InternalException;
|
public void setSynchronizedFolder(SynchFolderConfiguration config,String folderId) throws WorkspaceInteractionException, InternalException;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -148,7 +148,7 @@ public class WorkspaceFolderManager {
|
||||||
if(isSynched()) throw new WorkspaceInteractionException("Folder "+folderId+" is already configured for synchronization.");
|
if(isSynched()) throw new WorkspaceInteractionException("Folder "+folderId+" is already configured for synchronization.");
|
||||||
log.info("Configuring folder {} as {} ",folderId,toSet);
|
log.info("Configuring folder {} as {} ",folderId,toSet);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// Checking AND initializing remote folder
|
// Checking AND initializing remote folder
|
||||||
log.debug("Checking remote folder existence .. ");
|
log.debug("Checking remote folder existence .. ");
|
||||||
|
|
|
@ -24,7 +24,7 @@ public class Security {
|
||||||
ClientInfo client = null;
|
ClientInfo client = null;
|
||||||
try{
|
try{
|
||||||
AuthorizationProvider.instance.get().getClient();
|
AuthorizationProvider.instance.get().getClient();
|
||||||
}catch(Exception e) {
|
}catch(Throwable e) {
|
||||||
log.warn("Unable to get client info ",e);
|
log.warn("Unable to get client info ",e);
|
||||||
}
|
}
|
||||||
User toReturn = new User(client,UmaJWTProvider.instance.get(),SecurityTokenProvider.instance.get(),context);
|
User toReturn = new User(client,UmaJWTProvider.instance.get(),SecurityTokenProvider.instance.get(),context);
|
||||||
|
@ -37,7 +37,7 @@ public class Security {
|
||||||
public static void set(User toSet) {
|
public static void set(User toSet) {
|
||||||
log.debug("Setting User {} ",toSet);
|
log.debug("Setting User {} ",toSet);
|
||||||
if(toSet.getUma_token()!=null)UmaJWTProvider.instance.set(toSet.getUma_token());
|
if(toSet.getUma_token()!=null)UmaJWTProvider.instance.set(toSet.getUma_token());
|
||||||
if(toSet.getGcube_token()!=null)UmaJWTProvider.instance.set(toSet.getUma_token());
|
if(toSet.getGcube_token()!=null)SecurityTokenProvider.instance.set(toSet.getGcube_token());
|
||||||
if(ScopeProvider.instance.get()==null)ScopeProvider.instance.set(toSet.getContext());
|
if(ScopeProvider.instance.get()==null)ScopeProvider.instance.set(toSet.getContext());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -23,4 +23,5 @@ public class SyncFolderDescriptor {
|
||||||
private ProcessDescriptor localProcessDescriptor=null;
|
private ProcessDescriptor localProcessDescriptor=null;
|
||||||
|
|
||||||
|
|
||||||
|
private SynchronizedElementInfo info=null;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue