Hi,
It seems to me that it is possible to connect to a remote nuxeo repo
without any credential and have full read / write access to the repo.
Maybe I'm missing a configuration property or something, but I'm
affraid I can execute the following code either on nuxeo 5.2 or 5.3 :
Collection<File> files = null;
String bundles = System.getProperty("nuxeo.bundles");
if (bundles != null) {
files = NuxeoApp.getBundleFiles(new File("."), bundles, ":");
}
NuxeoApp app = new NuxeoApp();
app.start();
if (files != null) {
app.deployBundles(files);
}
NuxeoClient client = NuxeoClient.getInstance();
client.tryConnect("localhost", 62474);
RepositoryInstance repo = client.openRepository() ;
CoreSession documentManager = repo.getSession() ;
DocumentModel doc = documentManager.getDocument( new PathRef(
"/default-domain" ) ) ;
doc.setPropertyValue( "dc:description" , "I could have killed your
repo" ) ;
doc = documentManager.saveDocument( doc ) ;
documentManager.save() ;
System.out.println( documentManager.getDocument( new PathRef(
"/default-domain" ) ).getPropertyValue( "dc:description" ) ) ;
repo.close() ;
_______________________________________________
ECM mailing list
[email protected]
http://lists.nuxeo.com/mailman/listinfo/ecm
To unsubscribe, go to http://lists.nuxeo.com/mailman/options/ecm