cancel
Showing results for 
Search instead for 
Did you mean: 

Use SSL with Sharepoint protocol

pacco_robin
Champ in-the-making
Champ in-the-making
Hi,

I followed some instructions to run the Sharepoint protcol with SSL on port 7070.

First changed vti-context.xml to use SSL, then added this to vti.properties:
vti.server.port=7070
vti.server.protocol=https
vti.server.ssl.keystore=/opt/alfresco-4.2.f/alf_data/keystore/ssl.keystore
vti.server.ssl.password=kT9X6oe68t
vti.server.url.path.prefix=/alfresco
vti.server.external.host=[hostname]
vti.server.external.port=7070
vti.server.external.protocol=https
vti.server.external.contextPath=/alfresco

Now I do get SSL, but as it is a self signed certificate I always get some warnings before I can open a document.
Also I see these info messages in catalina.out:
2014-04-28 13:36:38,268  INFO  [vti.web.VtiRequestDispatcher] [1880889499@qtp-1454731198-0] Note - no handler was found for OPTIONS to uri='/zandbak/documentLibrary/'
2014-04-28 13:36:41,471  INFO  [vti.web.VtiRequestDispatcher] [1880889499@qtp-1454731198-0] Note - no handler was found for HEAD to uri='/zandbak/documentLibrary/Zandbak.docx'
2014-04-28 13:36:44,200  INFO  [vti.web.VtiRequestDispatcher] [780995441@qtp-1454731198-2] Note - no handler was found for GET to uri='/zandbak/documentLibrary/Zandbak.docx'
2014-04-28 13:36:53,006  INFO  [vti.web.VtiRequestDispatcher] [780995441@qtp-1454731198-2] Note - no handler was found for GET to uri='/zandbak/documentLibrary/Zandbak.docx'

On this server I already installed a 3rd party certificate for Alfresco https traffic using the Apache mod.

Is it possible to use this 3rd party certificate for the Sharepoint protocol and how do I manage that?
Are the INFO messages in catalina.out important?

Thanks for your input.

Regards,

Frank
11 REPLIES 11

eswbitto
Confirmed Champ
Confirmed Champ
Take a look at this thread HERE

pacco_robin
Champ in-the-making
Champ in-the-making
That didn't work.
I get errors from Apache that RequestHeader is misspelled.

I am using Apache and mod_jk.

HTTPS for Alfresco is working fine and certificate looks ok.

This is my config in 000-default.conf:
<VirtualHost *:443>
          ServerName x.y.com
          SSLEngine On
          SSLCertificateFile /etc/ssl/certs/certificate.crt
          SSLCertificateKeyFile /etc/ssl/private/key.key
          SSLCertificateChainFile /etc/ssl/certs/AddTrustExternalCARoot.crt
          SSLCertificateChainFile /etc/ssl/certs/PositiveSSLCA2.crt
          <Location />
              SSLRequireSSL On
              SSLVerifyClient optional
              SSLRenegBufferSize 104860000
              SSLVerifyDepth 1
              SSLOptions +StdEnvVars +StrictRequire
          </Location>
          # Send everything for the context / to worker named worker1 via ajp13
          JkMount /* ajp13_worker
</VirtualHost>

Regards,

Frank

eswbitto
Confirmed Champ
Confirmed Champ
You should be able to use sharepoint/webdav with the SSL working. What distro are you using? Also, What does your virtual host look like? Did you make sure to add the Listen (port) in your ssl.conf?

pacco_robin
Champ in-the-making
Champ in-the-making
We use Ubuntu 12.04LTS.
I followed these steps: https://forums.alfresco.com/comment/145306#comment-145306
When I add the virtual host VirtualHost *:1111 I get the Apache errors.
You can check my virtual host in my previous reply.

Kind regards,
Frank

eswbitto
Confirmed Champ
Confirmed Champ
The logs that you initially posted won't point to a particular issue for this connection problem. I get the same logs and I have SSL working. I think it is part of a different issue. What does your apache logs say when trying to connect?

Question: Did you actually use the port 1111 as in the example or the default?

pacco_robin
Champ in-the-making
Champ in-the-making
<body>
<p>I retried with a new approach! Let me explain the steps I take.</p>
<p>Previously I installed Apache, mod_jk and mod_ssl to make SSL work with Alfresco.<br>
  This is explained here: http://forums.alfresco.com/forum/installation-upgrades-configuration-integration/configuration/chang...</p>
<p>These setup works perfectly. I can connect to https://alfrescoserver.ourdomain.com and I can see my third party certificate.</p>
<p>Now I wanted to setup this certificate for Sharepoint communication.</p>
<p>1. I opened port 1111 in ufw.<br>
  sudo ufw allow 1111<br>
  I get some warnings:<br>
  WARN: Duplicate profile 'Apache', using last found<br>
  WARN: Duplicate profile 'Apache Secure', using last found<br>
  WARN: Duplicate profile 'Apache Full', using last found<br>
  Rule added<br>
  Rule added (v6)<br>
  But when I check the status, port 1111 is added.</p>
<p>2. I change the vti.properties at this location: /opt/alfresco-4.2.f/tomcat/webapps/alfresco/WEB-INF/classes/alfresco/module/org.alfresco.module.vti/context</p>
<p>Here I have:<br>
  vti.server.port=7070<br>
  vti.server.protocol=https<br>
  vti.server.ssl.keystore=/opt/alfresco-4.2.f/alf_data/keystore/ssl.keystore<br>
  vti.server.ssl.password=kT9X6oe68t<br>
  vti.server.url.path.prefix=/alfresco<br>
  vti.server.external.host=alfrescoserver.ourdomain.com<br>
  vti.server.external.port=7070<br>
  vti.server.external.protocol=https<br>
  vti.server.external.contextPath=/alfresco</p>
<p>I changed this:<br>
  vti.server.external.host=alfrescoserver.ourdomain.com<br>
  vti.server.external.port=1111<br>
  vti.server.external.protocol=https</p>
<p>3. I added virtualhost *:1111 in 000-default.conf at this location: /etc/apache2/sites-available</p>
<p>&lt;VirtualHost *:1111&gt;<br>
  ServerName alfrescoserver.ourdomain.com<br>
  SSLEngine On<br>
  SSLCertificateFile /etc/ssl/certs/alfrescoserver.ourdomain.com.crt<br>
  SSLCertificateKeyFile /etc/ssl/private/alfrescoserver.ourdomain.com.key<br>
  SSLCertificateChainFile /etc/ssl/certs/AddTrustExternalCARoot.crt<br>
  SSLCertificateChainFile /etc/ssl/certs/PositiveSSLCA2.crt<br>
  &lt;Location /&gt;<br>
  SSLRequireSSL On<br>
  SSLVerifyClient optional<br>
  SSLRenegBufferSize 104860000<br>
  SSLVerifyDepth 1<br>
  SSLOptions +StdEnvVars +StrictRequire<br>
  &lt;/Location&gt;<br>
  # Send everything for the context / to worker named worker1 via ajp13<br>
  JkMount /* ajp13_worker<br>
  &lt;/VirtualHost&gt;</p>
<p>VirtualHost *:1111 now looks exactly the same as VirtualHost *:443</p>
<p>4. I changed vti-context.xml at this location: /opt/alfresco-4.2.f/tomcat/webapps/alfresco/WEB-INF/classes/alfresco/module/org.alfresco.module.vti/context</p>
<p> &lt;!– Use this Connector for plain text (non-SSL) communications –&gt;<br>
  &lt;!–<br>
  &lt;bean id=&quot;vtiServerConnector&quot; class=&quot;org.mortbay.jetty.bio.SocketConnector&quot;&gt;<br>
  &lt;property name=&quot;port&quot;&gt;<br>
  &lt;value&gt;${vti.server.port}&lt;/value&gt;<br>
  &lt;/property&gt;<br>
  &lt;property name=&quot;headerBufferSize&quot;&gt;<br>
  &lt;value&gt;32768&lt;/value&gt;<br>
  &lt;/property&gt;<br>
  &lt;/bean&gt;<br>
  –&gt;</p>
<p> &lt;!– Use this Connector instead for SSL communications –&gt;<br>
  &lt;!– You will need to set the location of the KeyStore holding your –&gt;<br>
  &lt;!–  server certificate, along with the KeyStore password –&gt;<br>
  &lt;!– You should also update the vti.server.protocol property to https –&gt;</p>
<p> &lt;bean id=&quot;vtiServerConnector&quot; class=&quot;org.mortbay.jetty.security.SslSocketConnector&quot;&gt;<br>
  &lt;property name=&quot;port&quot;&gt;<br>
  &lt;value&gt;${vti.server.port}&lt;/value&gt;<br>
  &lt;/property&gt;<br>
  &lt;property name=&quot;headerBufferSize&quot;&gt;<br>
  &lt;value&gt;32768&lt;/value&gt;<br>
  &lt;/property&gt;<br>
  &lt;property name=&quot;maxIdleTime&quot;&gt;<br>
  &lt;value&gt;30000&lt;/value&gt;<br>
  &lt;/property&gt;<br>
  &lt;property name=&quot;keystore&quot;&gt;<br>
  &lt;value&gt;${vti.server.ssl.keystore}&lt;/value&gt;<br>
  &lt;/property&gt;<br>
  &lt;property name=&quot;keyPassword&quot;&gt;<br>
  &lt;value&gt;${vti.server.ssl.password}&lt;/value&gt;<br>
  &lt;/property&gt;<br>
  &lt;property name=&quot;password&quot;&gt;<br>
  &lt;value&gt;${vti.server.ssl.password}&lt;/value&gt;<br>
  &lt;/property&gt;<br>
  &lt;property name=&quot;keystoreType&quot;&gt;<br>
  &lt;value&gt;JCEKS&lt;/value&gt;<br>
  &lt;/property&gt;<br>
  &lt;/bean&gt;</p>
<p>I commented out non-SSL communication and uncommented SSL communication.</p>
<p>5. I changed ports.conf at this location: /etc/apache2</p>
<p>&lt;IfModule ssl_module&gt;<br>
  Listen 443<br>
  Listen 1111<br>
  &lt;/IfModule&gt;</p>
<p>&lt;IfModule mod_gnutls.c&gt;<br>
  Listen 443<br>
  Listen 1111<br>
  &lt;/IfModule&gt;</p>
<p>6. I restarted the Alfresco server</p>
<p>When I try to edit a document online Word starts up, but I only see a message about Word contacting the server and then Word opens without any document.</p>
</body>

pacco_robin
Champ in-the-making
Champ in-the-making
<body>
<p>When I put in this virtualhost I get this error trying to restart Apache.<br>
  <br>
  &lt;VirtualHost *:1111&gt;<br>
ServerName alfrescoserver.ourdomain.com<br>
SSLEngine On<br>
SSLCertificateFile /etc/ssl/certs/alfrescoserver.ourdomain.com.crt<br>
SSLCertificateKeyFile /etc/ssl/private/alfrescoserver.ourdomain.com.key<br>
SSLCertificateChainFile /etc/ssl/certs/AddTrustExternalCARoot.crt<br>
SSLCertificateChainFile /etc/ssl/certs/PositiveSSLCA2.crt<br>
RequestHeader set X-Forwarded-Proto &quot;https&quot;<br>
ProxyPass / ajp://127.0.0.1:7070/<br>
ProxyPassReverse / ajp:127.0.0.1:7070/<br>
ProxyTimeout 300<br>
SSLProxyEngine on</p>
<p> &lt;Proxy *&gt;<br>
  Allow from all<br>
  &lt;/Proxy&gt;<br>
&lt;/VirtualHost&gt;</p>
<p>  Error is:<br>
  <br>
  * Starting web server apache2                                                                                                                                    *<br>
  * The apache2 configtest failed.<br>
  Output of config test was:<br>
  AH00526: Syntax error on line 69 of /etc/apache2/sites-enabled/000-default.conf:<br>
  Invalid command 'RequestHeader', perhaps misspelled or defined by a module not i                                                                                 ncluded in the server configuration<br>
  Action 'configtest' failed.<br>
  The Apache error log may have more information.<br>
  <br>
  There is no information in the error log.
<br>
</p>
</body>

eswbitto
Confirmed Champ
Confirmed Champ
DO you have this as a module to load in your apache config?

headers_module modules/mod_headers.so‍‍‍


It sounds like you don't have the module installed.

Also your vti-context.xml file should look like this.

<!–    <bean id="vtiServerConnector" class="org.mortbay.jetty.bio.SocketConnector">        <property name="port">             <value>${vti.server.port}</value>        </property>        <property name="headerBufferSize">             <value>32768</value>        </property>    </bean>–>    <bean id="vtiServerConnector" class="org.mortbay.jetty.ajp.Ajp13SocketConnector">        <property name="port">             <value>${vti.server.port}</value>        </property>        <property name="headerBufferSize">             <value>8192</value>        </property>    </bean>    <!– Use this Connector instead for SSL communications –>    <!– You will need to set the location of the KeyStore holding your –>    <!–  server certificate, along with the KeyStore password –>    <!– You should also update the vti.server.protocol property to https –><!–    <bean id="vtiServerConnector" class="org.mortbay.jetty.security.SslSocketConnector">        <property name="port">             <value>${vti.server.port}</value>        </property>        <property name="headerBufferSize">             <value>32768</value>        </property>        <property name="maxIdleTime">             <value>30000</value>        </property>        <property name="keystore">             <value>${vti.server.ssl.keystore}</value>        </property>        <property name="keyPassword">             <value>${vti.server.ssl.password}</value>        </property>        <property name="password">             <value>${vti.server.ssl.password}</value>        </property>        <property name="keystoreType">             <value>JCEKS</value>        </property>    </bean> –>‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍

Yes the second SSL snippet that comes with Alfresco is commented out.

pacco_robin
Champ in-the-making
Champ in-the-making
I added headers_module modules/mod_headers.so to httpd.conf. Apache told me module was already there.
I changed vti-context.xml to your settings.
Realized that I didn't download jetty-ajp-6.1.14.jar. So I did.
For the Apache errors I enabled mod proxy_http.

Alfresco now starts perfectly without errors.

But when I try to edit a Word or Excel file online Office warns me that the file at port 1111 can be harmful. Then Word or Excel starts and finally I get a message that the file (https://servername.domain.com:1111/path_to_file/file) cannot be opened.

This is driving me nuts!!!

When I look at your explanation in the other post I skipped creating the tomcat connector. I already enabled SSL through mod_jk. I suppose the worker is also defined (if I look at my virtualhost:443).
Added virtualhost:1111 the way you explained.

No errors in catalina.out and this is what I find in the Apache error log:
[Tue May 13 10:34:11.276856 2014] [ssl:error] [pid 2849:tid 139913534048000] [client 10.0.1.111:17642] AH02261: Re-negotiation handshake failed: Not accepted by client!?, referer: https://alfresco.ourdomain.com/share/page/site/zandbak/document-details?nodeRef=workspace://SpacesSt...
[Tue May 13 10:34:11.430631 2014] [ssl:error] [pid 2849:tid 139913458513664] [client 10.0.1.111:17644] AH02261: Re-negotiation handshake failed: Not accepted by client!?, referer: https://alfresco.ourdomain.com/share/page/site/zandbak/document-details?nodeRef=workspace://SpacesSt...
[Tue May 13 10:34:11.434038 2014] [ssl:error] [pid 2849:tid 139913542440704] [client 10.0.1.111:17645] AH02261: Re-negotiation handshake failed: Not accepted by client!?, referer: https://alfresco.ourdomain.com/share/page/site/zandbak/document-details?nodeRef=workspace://SpacesSt...
[Tue May 13 10:34:11.436806 2014] [ssl:error] [pid 2849:tid 139913617975040] [client 10.0.1.111:17647] AH02261: Re-negotiation handshake failed: Not accepted by client!?, referer: https://alfresco.ourdomain.com/share/page/site/zandbak/document-details?nodeRef=workspace://SpacesSt...
[Tue May 13 10:34:11.461485 2014] [ssl:error] [pid 2849:tid 139913626367744] [client 10.0.1.111:17646] AH02261: Re-negotiation handshake failed: Not accepted by client!?, referer: https://alfresco.ourdomain.com/share/page/site/zandbak/document-details?nodeRef=workspace://SpacesSt...
[Tue May 13 10:34:14.559882 2014] [proxy:warn] [pid 2849:tid 139913643153152] [client 10.0.1.111:17654] AH01144: No protocol handler was valid for the URL /alfresco/zandbak/documentLibrary/. If you are using a DSO version of mod_proxy, make sure the proxy submodules are included in the configuration using LoadModule.
[Tue May 13 10:34:16.924618 2014] [proxy:warn] [pid 2849:tid 139913601189632] [client 10.0.1.111:17655] AH01144: No protocol handler was valid for the URL /alfresco/zandbak/documentLibrary/Zandbak.docx. If you are using a DSO version of mod_proxy, make sure the proxy submodules are included in the configuration using LoadModule.
[Tue May 13 10:34:16.952391 2014] [proxy:warn] [pid 2849:tid 139913559226112] [client 10.0.1.111:17656] AH01144: No protocol handler was valid for the URL /alfresco/zandbak/. If you are using a DSO version of mod_proxy, make sure the proxy submodules are included in the configuration using LoadModule.
[Tue May 13 10:34:17.053874 2014] [proxy:warn] [pid 2849:tid 139913576011520] [client 10.0.1.111:17657] AH01144: No protocol handler was valid for the URL /alfresco/zandbak/documentLibrary/Zandbak.docx. If you are using a DSO version of mod_proxy, make sure the proxy submodules are included in the configuration using LoadModule.
Getting started

Tags


Find what you came for

We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.