cancel
Showing results for 
Search instead for 
Did you mean: 

No puedo acceder mediante localhost

Alfred2
Star Contributor
Star Contributor

Hola instale alfresco mediante:

https://github.com/Alfresco/alfresco-docker-installer

Puedo conectarme a alfresco share mediante la direccion ip de mi maquina y mediante DNS pero no puedo conectarme mediante: localhost:8080/share 

que puedo hacer para poder conectarme tambien por localhost ? 

10 REPLIES 10

Hola Cristina,

Lamentablemente sigo sin tener exito a este problema

 /usr/local/tomcat/shared/classes

alfresco-global.properties:

csrf.filter.enabled=false

alfresco.context=alfresco
alfresco.host=127.0.0.1
alfresco.port=8080
alfresco.protocol=http

share.context=share
share.host=127.0.0.1
share.port=8080
share.protocol=http

system.serverMode=UNKNOWN

alfresco.rmi.services.port=50500


index.subsystem.name=solr6
dir.keystore=${dir.root}/keystore
solr.host=localhost
solr.port.ssl=8443


security.anyDenyDenies=false

### Smart Folders Config Properties ###
smart.folders.enabled=false


alfresco.jmx.connector.enabled=false

Nuevamente el problema

at java.base/java.lang.Thread.run(Thread.java:834)
06-May-2021 19:22:28.412 SEVERE [http-nio-8080-exec-9] org.apache.catalina.core.StandardWrapperValve.invoke Servlet.service() for servlet [Spring Surf Dispatcher Servlet] in context with path [/share] threw exception [Possible CSRF attack noted when asserting referer header 'http://localhost:8089/share/page'. Request: POST /share/page/dologin, FAILED TEST: Assert referer POST /share/page/dologin :: referer: 'http://localhost:8089/share/page' vs server & context: http://localhost:8080/ (string) or (regexp)] with root cause
javax.servlet.ServletException: Possible CSRF attack noted when asserting referer header 'http://localhost:8089/share/page'. Request: POST /share/page/dologin, FAILED TEST: Assert referer POST /share/page/dologin :: referer: 'http://localhost:8089/share/page' vs server & context: http://localhost:8080/ (string) or (regexp)
at org.springframework.extensions.webscripts.servlet.CSRFFilter$AssertRefererAction.run(CSRFFilter.java:1072)
at org.springframework.extensions.webscripts.servlet.CSRFFilter.doFilter(CSRFFilter.java:346)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
at org.alfresco.web.site.servlet.SSOAuthenticationFilter.doFilter(SSOAuthenticationFilter.java:474)
at org.alfresco.web.site.servlet.SSOAuthenticationFilter.doFilter(SSOAuthenticationFilter.java:443)
at org.springframework.extensions.webscripts.servlet.BeanProxyFilter.doFilter(BeanProxyFilter.java:80)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
at org.alfresco.web.site.servlet.MTAuthenticationFilter.doFilter(MTAuthenticationFilter.java:81)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:199)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:493)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:81)

Lo mas interesante es que si mapeo 8080:locahost:8080/share/page/ si me funciona, pero si intento entrar por otro puerto como 8089://localhost:8080/share/page tengo ese problema de: /share/page/dologin :: referer: 'http://localhost:8089/share/page' vs server & context: http://localhost:8080/ .... etc

Los puerto de alfresco y alfresco share son los que vienen por defecto en el docker-compose.yml que es el 8080

imagen de docker 

share:
build:
context: ./share
args:
SHARE_TAG: ${SHARE_TAG}
SERVER_NAME: ${SERVER_NAME}
mem_limit: 1104m
environment:
REPO_HOST: "alfresco"
REPO_PORT: "8080"
CSRF_FILTER_REFERER: "http://localhost/.*"
CSRF_FILTER_ORIGIN: "http://localhost"
JAVA_OPTS: "
-Xms976m -Xmx976m
-Dalfresco.context=alfresco
-Dalfresco.protocol=http
"
volumes:
- ./logs/share:/usr/local/tomcat/logs

Gracias por la ayuda.