[jitsi-dev] 'Access-Control-Allow-Origin' error


#1

Hi guy.

I have this problem:

XMLHttpRequest cannot load https://my_private_ip_address/http-bind?room=test.
Response to preflight request doesn't pass access control check: No
'Access-Control-Allow-Origin' header is present on the requested resource.
Origin 'https://my_public_ip_address' is therefore not allowed access.

I think I have 3 solutions here:

1. Enable CORS
2. Use my public IP address/hostname for virtual host configuration inside
the Jitsi Meet. How can I do that?
3. Fresh install with my public IP address/hostname

Could you please give me some advice?

Thanks


#2

Hi,

Hi guy.

I have this problem:

XMLHttpRequest cannot load
https://my_private_ip_address/http-bind?room=test. Response to preflight
request doesn't pass access control check: No 'Access-Control-Allow-Origin'
header is present on the requested resource. Origin
'https://my_public_ip_address' is therefore not allowed access.

I think I have 3 solutions here:

1. Enable CORS
2. Use my public IP address/hostname for virtual host configuration inside
the Jitsi Meet. How can I do that?
3. Fresh install with my public IP address/hostname

Could you please give me some advice?

The problem is that for example, you are accessing the server through
the ip address (https://ip-addres/....) but in your config.js you have
configured the bosh url(.../http-bind) to use a hostname or other
ipaddress and for security reasons, the webpages in the browser deny
such requests when addresses differ, this is allowed if configured
through CORS.
Normally when you install jitsi-meet it asks you for hostname, where
you enter the publicly accessible domain name of the server, like
entering meet.jit.si when you do a deployment for meet.jit.si and this
is enough for running it.

Regards
damencho

···

On Wed, Apr 26, 2017 at 4:23 AM, Nam Vu <zuzoovn@gmail.com> wrote:

Thanks

_______________________________________________
dev mailing list
dev@jitsi.org
Unsubscribe instructions and other list options:
http://lists.jitsi.org/mailman/listinfo/dev


#3

Hi damencho,

When I install jitsi-meet, I input my private IP dress, thus everything is
OK with my private internet connection.
Now I want to use jitsi-meet from public internet, thus I use my public IP
address to link with my localhost, thus I have
'Access-Control-Allow-Origin' error.

Normally when you install jitsi-meet it asks you for hostname, where

you enter the publicly accessible domain name of the server, like
entering meet.jit.si when you do a deployment for meet.jit.si and this
is enough for running it.

How can I change to new hostname from old hostname that has been entered in
installation process before?

Thanks
Nam

···

On Wed, Apr 26, 2017 at 10:12 PM, Damian Minkov <damencho@jitsi.org> wrote:

Hi,

On Wed, Apr 26, 2017 at 4:23 AM, Nam Vu <zuzoovn@gmail.com> wrote:
> Hi guy.
>
> I have this problem:
>
> XMLHttpRequest cannot load
> https://my_private_ip_address/http-bind?room=test. Response to preflight
> request doesn't pass access control check: No
'Access-Control-Allow-Origin'
> header is present on the requested resource. Origin
> 'https://my_public_ip_address' is therefore not allowed access.
>
> I think I have 3 solutions here:
>
> 1. Enable CORS
> 2. Use my public IP address/hostname for virtual host configuration
inside
> the Jitsi Meet. How can I do that?
> 3. Fresh install with my public IP address/hostname
>
> Could you please give me some advice?

The problem is that for example, you are accessing the server through
the ip address (https://ip-addres/....) but in your config.js you have
configured the bosh url(.../http-bind) to use a hostname or other
ipaddress and for security reasons, the webpages in the browser deny
such requests when addresses differ, this is allowed if configured
through CORS.
Normally when you install jitsi-meet it asks you for hostname, where
you enter the publicly accessible domain name of the server, like
entering meet.jit.si when you do a deployment for meet.jit.si and this
is enough for running it.

Regards
damencho

>
> Thanks
>
> _______________________________________________
> dev mailing list
> dev@jitsi.org
> Unsubscribe instructions and other list options:
> http://lists.jitsi.org/mailman/listinfo/dev

_______________________________________________
dev mailing list
dev@jitsi.org
Unsubscribe instructions and other list options:
http://lists.jitsi.org/mailman/listinfo/dev


#4

Hi,

You need to run dpkg-reconfigure on all of the packages:
dpkg-reconfigure jitsi-videobridge jicofo jitsi-meet-prosody
jitsi-meet-web-config, this should be enough.
Mind that procedure is not well tested and you can hit some problem/bug.
The other option is just purging all packages (apt-get --purge remove
jitsi-videobridge jicofo jitsi-meet-prosody jitsi-meet-web-config
jitsi-meet-web jitsi-meet) and start again on clean.

Regards
damencho

···

On Wed, Apr 26, 2017 at 9:17 PM, Nam Vu <zuzoovn@gmail.com> wrote:

Hi damencho,

When I install jitsi-meet, I input my private IP dress, thus everything is
OK with my private internet connection.
Now I want to use jitsi-meet from public internet, thus I use my public IP
address to link with my localhost, thus I have
'Access-Control-Allow-Origin' error.

Normally when you install jitsi-meet it asks you for hostname, where
you enter the publicly accessible domain name of the server, like
entering meet.jit.si when you do a deployment for meet.jit.si and this
is enough for running it.

How can I change to new hostname from old hostname that has been entered in
installation process before?

Thanks
Nam

On Wed, Apr 26, 2017 at 10:12 PM, Damian Minkov <damencho@jitsi.org> wrote:

Hi,

On Wed, Apr 26, 2017 at 4:23 AM, Nam Vu <zuzoovn@gmail.com> wrote:
> Hi guy.
>
> I have this problem:
>
> XMLHttpRequest cannot load
> https://my_private_ip_address/http-bind?room=test. Response to preflight
> request doesn't pass access control check: No
> 'Access-Control-Allow-Origin'
> header is present on the requested resource. Origin
> 'https://my_public_ip_address' is therefore not allowed access.
>
> I think I have 3 solutions here:
>
> 1. Enable CORS
> 2. Use my public IP address/hostname for virtual host configuration
> inside
> the Jitsi Meet. How can I do that?
> 3. Fresh install with my public IP address/hostname
>
> Could you please give me some advice?

The problem is that for example, you are accessing the server through
the ip address (https://ip-addres/....) but in your config.js you have
configured the bosh url(.../http-bind) to use a hostname or other
ipaddress and for security reasons, the webpages in the browser deny
such requests when addresses differ, this is allowed if configured
through CORS.
Normally when you install jitsi-meet it asks you for hostname, where
you enter the publicly accessible domain name of the server, like
entering meet.jit.si when you do a deployment for meet.jit.si and this
is enough for running it.

Regards
damencho

>
> Thanks
>
> _______________________________________________
> dev mailing list
> dev@jitsi.org
> Unsubscribe instructions and other list options:
> http://lists.jitsi.org/mailman/listinfo/dev

_______________________________________________
dev mailing list
dev@jitsi.org
Unsubscribe instructions and other list options:
http://lists.jitsi.org/mailman/listinfo/dev

_______________________________________________
dev mailing list
dev@jitsi.org
Unsubscribe instructions and other list options:
http://lists.jitsi.org/mailman/listinfo/dev


#5

You may need just to enable CORS in Prosody.
This way, you may have different multiple domains using the same XMPP
components in Prosody.

http://prosody.im/doc/setting_up_bosh

···

On Thu, Apr 27, 2017 at 10:08 AM, Damian Minkov <damencho@jitsi.org> wrote:

Hi,

You need to run dpkg-reconfigure on all of the packages:
dpkg-reconfigure jitsi-videobridge jicofo jitsi-meet-prosody
jitsi-meet-web-config, this should be enough.
Mind that procedure is not well tested and you can hit some problem/bug.
The other option is just purging all packages (apt-get --purge remove
jitsi-videobridge jicofo jitsi-meet-prosody jitsi-meet-web-config
jitsi-meet-web jitsi-meet) and start again on clean.

Regards
damencho

On Wed, Apr 26, 2017 at 9:17 PM, Nam Vu <zuzoovn@gmail.com> wrote:

Hi damencho,

When I install jitsi-meet, I input my private IP dress, thus everything is
OK with my private internet connection.
Now I want to use jitsi-meet from public internet, thus I use my public IP
address to link with my localhost, thus I have
'Access-Control-Allow-Origin' error.

Normally when you install jitsi-meet it asks you for hostname, where
you enter the publicly accessible domain name of the server, like
entering meet.jit.si when you do a deployment for meet.jit.si and this
is enough for running it.

How can I change to new hostname from old hostname that has been entered in
installation process before?

Thanks
Nam

On Wed, Apr 26, 2017 at 10:12 PM, Damian Minkov <damencho@jitsi.org> wrote:

Hi,

On Wed, Apr 26, 2017 at 4:23 AM, Nam Vu <zuzoovn@gmail.com> wrote:
> Hi guy.
>
> I have this problem:
>
> XMLHttpRequest cannot load
> https://my_private_ip_address/http-bind?room=test. Response to preflight
> request doesn't pass access control check: No
> 'Access-Control-Allow-Origin'
> header is present on the requested resource. Origin
> 'https://my_public_ip_address' is therefore not allowed access.
>
> I think I have 3 solutions here:
>
> 1. Enable CORS
> 2. Use my public IP address/hostname for virtual host configuration
> inside
> the Jitsi Meet. How can I do that?
> 3. Fresh install with my public IP address/hostname
>
> Could you please give me some advice?

The problem is that for example, you are accessing the server through
the ip address (https://ip-addres/....) but in your config.js you have
configured the bosh url(.../http-bind) to use a hostname or other
ipaddress and for security reasons, the webpages in the browser deny
such requests when addresses differ, this is allowed if configured
through CORS.
Normally when you install jitsi-meet it asks you for hostname, where
you enter the publicly accessible domain name of the server, like
entering meet.jit.si when you do a deployment for meet.jit.si and this
is enough for running it.

Regards
damencho

>
> Thanks
>
> _______________________________________________
> dev mailing list
> dev@jitsi.org
> Unsubscribe instructions and other list options:
> http://lists.jitsi.org/mailman/listinfo/dev

_______________________________________________
dev mailing list
dev@jitsi.org
Unsubscribe instructions and other list options:
http://lists.jitsi.org/mailman/listinfo/dev

_______________________________________________
dev mailing list
dev@jitsi.org
Unsubscribe instructions and other list options:
http://lists.jitsi.org/mailman/listinfo/dev

_______________________________________________
dev mailing list
dev@jitsi.org
Unsubscribe instructions and other list options:
http://lists.jitsi.org/mailman/listinfo/dev