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

Test with Alfresco 5.0c doesn't work #1

Closed
tatatanja opened this issue Mar 19, 2015 · 6 comments
Closed

Test with Alfresco 5.0c doesn't work #1

tatatanja opened this issue Mar 19, 2015 · 6 comments
Assignees

Comments

@tatatanja
Copy link

Hi!

Thanks for this AddOn, I searched exactly for this functionality in Alfresco.

I tried it with Alfresco 5.0c and unfortunately it doesn't work.
The create-site links are not displayed, even I have created the Group GROUP_SITE_CREATORS and added individuals and the ALFRESCO_ADMINISTRATORS group.

Immediately after login, there is an Exception in the LogFile:

13:19:38,708 ERROR [org.springframework.extensions.webscripts.AbstractRuntime] [http-apr-8080-exec-12] Exception from executeScript - redirecting to status template error: 02190009 Wrapped Exception (with status template): 02190051 Failed to execute script 'classpath_:alfresco/templates/webscripts/org/alfresco/repository/site/sites.query.post.json.js': 02190050 Zugriff verweigert. Sie verfügen nicht über die Berechtigungen, um diesen Vorgang durchzuführen.
org.springframework.extensions.webscripts.WebScriptException: 02190009 Wrapped Exception (with status template): 02190051 Failed to execute script 'classpath_:alfresco/templates/webscripts/org/alfresco/repository/site/sites.query.post.json.js': 02190050 Zugriff verweigert. Sie verfügen nicht über die Berechtigungen, um diesen Vorgang durchzuführen.

Caused by: org.alfresco.repo.security.permissions.AccessDeniedException: 02190050 Zugriff verweigert. Sie verfügen nicht über die Berechtigungen, um diesen Vorgang durchzuführen.
Caused by: net.sf.acegisecurity.AccessDeniedException: Access is denied.

at org.mozilla.javascript.gen.classpath__alfresco_templates_webscripts_org_alfresco_repository_site_sites_query_post_json_js_4.c_main_1(classpath:alfresco/templates/webscripts/org/alfresco/repository/site/sites.query.post.json.js:32)
at org.mozilla.javascript.gen.classpath__alfresco_templates_webscripts_org_alfresco_repository_site_sites_query_post_json_js_4.call(classpath_:alfresco/templates/webscripts/org/alfresco/repository/site/sites.query.post.json.js)
at org.mozilla.javascript.optimizer.OptRuntime.callName0(OptRuntime.java:74)
at org.mozilla.javascript.gen.classpath__alfresco_templates_webscripts_org_alfresco_repository_site_sites_query_post_json_js_4.c_script_0(classpath:alfresco/templates/webscripts/org/alfresco/repository/site/sites.query.post.json.js:52)
at org.mozilla.javascript.gen.classpath__alfresco_templates_webscripts_org_alfresco_repository_site_sites_query_post_json_js_4.call(classpath_:alfresco/templates/webscripts/org/alfresco/repository/site/sites.query.post.json.js)
at org.mozilla.javascript.ContextFactory.doTopCall(ContextFactory.java:394)
at org.mozilla.javascript.ScriptRuntime.doTopCall(ScriptRuntime.java:3091)
at org.mozilla.javascript.gen.classpath__alfresco_templates_webscripts_org_alfresco_repository_site_sites_query_post_json_js_4.call(classpath_:alfresco/templates/webscripts/org/alfresco/repository/site/sites.query.post.json.js)
at org.mozilla.javascript.gen.classpath__alfresco_templates_webscripts_org_alfresco_repository_site_sites_query_post_json_js_4.exec(classpath_:alfresco/templates/webscripts/org/alfresco/repository/site/sites.query.post.json.js)

Did you tried the AddOn with Alfresco 5.0c?

Regards,
Tanja

@qingl97
Copy link

qingl97 commented Mar 25, 2015

I am using Alfresco one 5.0.0.3 and 5.0.c.

I had the similar issue like you about the permissions on executing the js files. I only applied the changes in repo AMP to minimize the problem. That's to say to override the SiteService_security bean by coping the bean configuration directly from jeff's code.

Then I found the problem. There is on value missing for the property objectDefinitionSource in the configuration:

org.alfresco.service.cmr.site.SiteService.isSiteAdmin=ACL_ALLOW

which is not presented in Alfresco 4.

Then I replaced the configuration for that bean with the one I copied from the file public-services-security-context.xml in alfresco-repository-5.0.[c|0.3].jar. Things just worked quite well afterwards.

This should work for you too and maybe jeff could add a warning in this file.

I haven't tested the share AMP on Alfresco 5.

@jpotts
Copy link
Owner

jpotts commented Mar 26, 2015

No I have not tested against that version. I hear there will soon be 5.0.d which should be more stable. I will likely test it against that version.

Jeff

On Mar 19, 2015, at 8:07 AM, tatatanja notifications@github.com wrote:

Hi!

Thanks for this AddOn, I searched exactly for this functionality in Alfresco.

I tried it with Alfresco 5.0c and unfortunately it doesn't work.
The create-site links are not displayed, even I have created the Group GROUP_SITE_CREATORS and added individuals and the ALFRESCO_ADMINISTRATORS group.

Immediately after login, there is an Exception in the LogFile:

13:19:38,708 ERROR [org.springframework.extensions.webscripts.AbstractRuntime] [http-apr-8080-exec-12] Exception from executeScript - redirecting to status template error: 02190009 Wrapped Exception (with status template): 02190051 Failed to execute script 'classpath:alfresco/templates/webscripts/org/alfresco/repository/site/sites.query.post.json.js': 02190050 Zugriff verweigert. Sie verfügen nicht über die Berechtigungen, um diesen Vorgang durchzuführen.
org.springframework.extensions.webscripts.WebScriptException: 02190009 Wrapped Exception (with status template): 02190051 Failed to execute script 'classpath:alfresco/templates/webscripts/org/alfresco/repository/site/sites.query.post.json.js': 02190050 Zugriff verweigert. Sie verfügen nicht über die Berechtigungen, um diesen Vorgang durchzuführen.

Caused by: org.alfresco.repo.security.permissions.AccessDeniedException: 02190050 Zugriff verweigert. Sie verfügen nicht über die Berechtigungen, um diesen Vorgang durchzuführen.
Caused by: net.sf.acegisecurity.AccessDeniedException: Access is denied.

at org.mozilla.javascript.gen.classpath__alfresco_templates_webscripts_org_alfresco_repository_site_sites_query_post_json_js_4._c_main_1(classpath:alfresco/templates/webscripts/org/alfresco/repository/site/sites.query.post.json.js:32)
at org.mozilla.javascript.gen.classpath__alfresco_templates_webscripts_org_alfresco_repository_site_sites_query_post_json_js_4.call(classpath:alfresco/templates/webscripts/org/alfresco/repository/site/sites.query.post.json.js)
at org.mozilla.javascript.optimizer.OptRuntime.callName0(OptRuntime.java:74)
at org.mozilla.javascript.gen.classpath__alfresco_templates_webscripts_org_alfresco_repository_site_sites_query_post_json_js_4._c_script_0(classpath:alfresco/templates/webscripts/org/alfresco/repository/site/sites.query.post.json.js:52)
at org.mozilla.javascript.gen.classpath__alfresco_templates_webscripts_org_alfresco_repository_site_sites_query_post_json_js_4.call(classpath:alfresco/templates/webscripts/org/alfresco/repository/site/sites.query.post.json.js)
at org.mozilla.javascript.ContextFactory.doTopCall(ContextFactory.java:394)
at org.mozilla.javascript.ScriptRuntime.doTopCall(ScriptRuntime.java:3091)
at org.mozilla.javascript.gen.classpath__alfresco_templates_webscripts_org_alfresco_repository_site_sites_query_post_json_js_4.call(classpath:alfresco/templates/webscripts/org/alfresco/repository/site/sites.query.post.json.js)
at org.mozilla.javascript.gen.classpath__alfresco_templates_webscripts_org_alfresco_repository_site_sites_query_post_json_js_4.exec(classpath:alfresco/templates/webscripts/org/alfresco/repository/site/sites.query.post.json.js)

Did you tried the AddOn with Alfresco 5.0c?

Regards,
Tanja


Reply to this email directly or view it on GitHub.

@douglascrp
Copy link
Contributor

@jpotts I won't be soon... it's already there https://wiki.alfresco.com/wiki/Community_file_list_5.0.d

@tatatanja
Copy link
Author

@qingl97 Thanks! I added the missing property and now the Exception ist gone, but nevertheless its not really working.
I added the Goup GROUP_SITE_CREATORS and put the admin into it, but I don't see the "create site" links anymore. I restarted Alfresco and tried it with some other users and installed the Addon a couple times but the links are not shown!
Did you do something else?

@marciofoz
Copy link

I have the same issue that tatatanja. Im using 5.0.c.

@jpotts jpotts self-assigned this Mar 29, 2015
@jpotts
Copy link
Owner

jpotts commented Mar 29, 2015

Thanks for reporting the issue and for the fix. Note that there are other changes in that file in addition to the one you pointed out, so you might want to do a diff between your version and the one I've checked in to the 5.0.d branch.

@jpotts jpotts closed this as completed Mar 29, 2015
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

5 participants