Displaying 20 results from an estimated 195 matches for "remote_addr".
2006 Nov 01
8
Nginx, Mongrel, Proxy and REMOTE_ADDR
...been passing the request to pen, which in turn balances the cluster of
mongrels. Now, I''d like to be able to use a different server to send
the static files created by the rails application, so I tried to
replace pen with nginx. Everything seems to work fine except the
environment variable REMOTE_ADDR.
When I do a <%= request.env["REMOTE_ADDR"] %> with pen balancing, it
sends in the proper (and expected) 192.168.1.21.
When nginx is the balancer, the output becomes: 192.168.1.21, 127.0.0.1.
the nginx proxy information I have set is:
proxy_redirect off;
proxy_set_head...
2007 Nov 23
2
Unable to read anything from request.remote_ip
For some users, request.remote_ip always return nil. According to the
RAILS''s help:
REMOTE_ADDR is the standard but will fail if the user is behind a proxy.
HTTP_CLIENT_IP and/or HTTP_X_FORWARDED_FOR are set by proxies so check
for these before falling back to REMOTE_ADDR. HTTP_X_FORWARDED_FOR may
be a comma- delimited list in the case of multiple chained proxies; the
first is the originating...
2019 Oct 23
0
[PATCH net-next 11/14] vsock: add multi-transports support
...ct list_head *list,
@@ -376,6 +380,62 @@ void vsock_enqueue_accept(struct sock *listener, struct sock *connected)
}
EXPORT_SYMBOL_GPL(vsock_enqueue_accept);
+/* Assign a transport to a socket and call the .init transport callback.
+ *
+ * Note: for stream socket this must be called when vsk->remote_addr is set
+ * (e.g. during the connect() or when a connection request on a listener
+ * socket is received).
+ * The vsk->remote_addr is used to decide which transport to use:
+ * - remote CID > VMADDR_CID_HOST will use host->guest transport
+ * - remote CID <= VMADDR_CID_HOST will use g...
2019 Sep 27
0
[RFC PATCH 10/13] vsock: add multi-transports support
...ct list_head *list,
@@ -376,6 +380,55 @@ void vsock_enqueue_accept(struct sock *listener, struct sock *connected)
}
EXPORT_SYMBOL_GPL(vsock_enqueue_accept);
+/* Assign a transport to a socket and call the .init transport callback.
+ *
+ * Note: for stream socket this must be called when vsk->remote_addr is set
+ * (e.g. during the connect() or when a connection request on a listener
+ * socket is received).
+ * The vsk->remote_addr is used to decide which transport to use:
+ * - remote CID > VMADDR_CID_HOST will use host->guest transport
+ * - remote CID <= VMADDR_CID_HOST will use g...
2023 Jul 04
1
Getvar of CHANNEL not working for a couple of items
...: "<sip:222 at mydomain.com;user=phone>" , local_tag: "1734d973-c4da-4ae8-a37d-5f7065f1fe54" , local_addr: "172.31.253.4:5060" , remote_uri: "\\\"TestPhone x111\\\" <sip:111 at mydomain.com>" , remote_tag: "yinue4v5ufa4" , remote_addr: "172.31.253.20:5060"
Channel B: "1688509741.113" , name: "PJSIP/222-00000065" , is originator: N , call-Id: "1f104544-fc1a-4414-ba74-68c526e294de" , local_uri: "\\\"TestPhone\\\" <sip:111 at 172.31.253.4>" , local_tag:...
2023 Jul 04
1
Getvar of CHANNEL not working for a couple of items
...works well for all of the information I want:
action: Getvar
actionid: act1
channel: PJSIP/Twilio-NA-W-3-In-00000028
Variable: CHANNEL(pjsip,XXXX)
Where XXXX can be one of the many available items. However, when I create a call from A to B, all of the items return properly except: local_addr and remote_addr. More specifically, they return correctly for the A leg (that initiated the call), but are blank for the B leg. According to the asterisk.org docs:
* local_addr - On inbound calls, the full IP address and port number that the INVITE request was received on. On outbound calls, the full IP...
2019 Oct 23
2
[PATCH net-next 11/14] vsock: add multi-transports support
...6 +380,62 @@ void vsock_enqueue_accept(struct sock *listener, struct sock *connected)
> }
> EXPORT_SYMBOL_GPL(vsock_enqueue_accept);
>
> +/* Assign a transport to a socket and call the .init transport callback.
> + *
> + * Note: for stream socket this must be called when vsk->remote_addr is set
> + * (e.g. during the connect() or when a connection request on a listener
> + * socket is received).
> + * The vsk->remote_addr is used to decide which transport to use:
> + * - remote CID > VMADDR_CID_HOST will use host->guest transport
> + * - remote CID <= V...
2019 Oct 23
2
[PATCH net-next 11/14] vsock: add multi-transports support
...6 +380,62 @@ void vsock_enqueue_accept(struct sock *listener, struct sock *connected)
> }
> EXPORT_SYMBOL_GPL(vsock_enqueue_accept);
>
> +/* Assign a transport to a socket and call the .init transport callback.
> + *
> + * Note: for stream socket this must be called when vsk->remote_addr is set
> + * (e.g. during the connect() or when a connection request on a listener
> + * socket is received).
> + * The vsk->remote_addr is used to decide which transport to use:
> + * - remote CID > VMADDR_CID_HOST will use host->guest transport
> + * - remote CID <= V...
2019 Sep 27
0
[RFC PATCH 04/13] vsock: add 'transport' member in the struct vsock_sock
...134261d 100644
--- a/include/net/af_vsock.h
+++ b/include/net/af_vsock.h
@@ -27,6 +27,7 @@ extern spinlock_t vsock_table_lock;
struct vsock_sock {
/* sk must be the first member. */
struct sock sk;
+ const struct vsock_transport *transport;
struct sockaddr_vm local_addr;
struct sockaddr_vm remote_addr;
/* Links for the global tables of bound and connected sockets. */
diff --git a/net/vmw_vsock/af_vsock.c b/net/vmw_vsock/af_vsock.c
index f609434b2794..81ee2561c76f 100644
--- a/net/vmw_vsock/af_vsock.c
+++ b/net/vmw_vsock/af_vsock.c
@@ -126,7 +126,7 @@ static struct proto vsock_proto = {
*/
#...
2019 Oct 23
0
[PATCH net-next 04/14] vsock: add 'transport' member in the struct vsock_sock
...134261d 100644
--- a/include/net/af_vsock.h
+++ b/include/net/af_vsock.h
@@ -27,6 +27,7 @@ extern spinlock_t vsock_table_lock;
struct vsock_sock {
/* sk must be the first member. */
struct sock sk;
+ const struct vsock_transport *transport;
struct sockaddr_vm local_addr;
struct sockaddr_vm remote_addr;
/* Links for the global tables of bound and connected sockets. */
diff --git a/net/vmw_vsock/af_vsock.c b/net/vmw_vsock/af_vsock.c
index 2f2582fb7fdd..c3a14f853eb0 100644
--- a/net/vmw_vsock/af_vsock.c
+++ b/net/vmw_vsock/af_vsock.c
@@ -126,7 +126,7 @@ static struct proto vsock_proto = {
*/
#...
2019 Nov 11
2
[PATCH net-next 11/14] vsock: add multi-transports support
...+380,62
> @@ void vsock_enqueue_accept(struct sock *listener, struct sock
> *connected) } EXPORT_SYMBOL_GPL(vsock_enqueue_accept);
>
> +/* Assign a transport to a socket and call the .init transport callback.
> + *
> + * Note: for stream socket this must be called when vsk->remote_addr is
> +set
> + * (e.g. during the connect() or when a connection request on a
> +listener
> + * socket is received).
> + * The vsk->remote_addr is used to decide which transport to use:
> + * - remote CID > VMADDR_CID_HOST will use host->guest transport
> + * - remote...
2019 Nov 11
2
[PATCH net-next 11/14] vsock: add multi-transports support
...+380,62
> @@ void vsock_enqueue_accept(struct sock *listener, struct sock
> *connected) } EXPORT_SYMBOL_GPL(vsock_enqueue_accept);
>
> +/* Assign a transport to a socket and call the .init transport callback.
> + *
> + * Note: for stream socket this must be called when vsk->remote_addr is
> +set
> + * (e.g. during the connect() or when a connection request on a
> +listener
> + * socket is received).
> + * The vsk->remote_addr is used to decide which transport to use:
> + * - remote CID > VMADDR_CID_HOST will use host->guest transport
> + * - remote...
2018 Dec 12
1
[PATCH] VSOCK: Send reset control packet when socket is partially bound
...nsport_send_control_pkt(struct sock *sk,
u16 proto,
struct vmci_handle handle)
{
- struct vmci_transport_packet *pkt;
struct vsock_sock *vsk;
- int err;
vsk = vsock_sk(sk);
@@ -284,17 +307,10 @@ vmci_transport_send_control_pkt(struct sock *sk,
if (!vsock_addr_bound(&vsk->remote_addr))
return -EINVAL;
- pkt = kmalloc(sizeof(*pkt), GFP_KERNEL);
- if (!pkt)
- return -ENOMEM;
-
- err = __vmci_transport_send_control_pkt(pkt, &vsk->local_addr,
- &vsk->remote_addr, type, size,
- mode, wait, proto, handle,
- true);
- kfree(pkt);
-
- return err;
+ ret...
2023 Jul 05
1
Getvar of CHANNEL not working for a couple of items
...ip:222 at mydomain.com;user=phone>" , local_tag:
> "1734d973-c4da-4ae8-a37d-5f7065f1fe54" , local_addr: "172.31.253.4:5060"
> , remote_uri: "\\\"TestPhone x111\\\" <sip:111 at mydomain.com>" ,
> remote_tag: "yinue4v5ufa4" , remote_addr: "172.31.253.20:5060"
>
>
>
>
>
> Channel B: "1688509741.113" , name: "PJSIP/222-00000065" , is
> originator: N , call-Id: "1f104544-fc1a-4414-ba74-68c526e294de" ,
> local_uri: "\\\"TestPhone\\\" <sip:111 at 17...
2018 Dec 18
1
[PATCH v2] VSOCK: Send reset control packet when socket is partially bound
...nsport_send_control_pkt(struct sock *sk,
u16 proto,
struct vmci_handle handle)
{
- struct vmci_transport_packet *pkt;
struct vsock_sock *vsk;
- int err;
vsk = vsock_sk(sk);
@@ -284,17 +307,10 @@ vmci_transport_send_control_pkt(struct sock *sk,
if (!vsock_addr_bound(&vsk->remote_addr))
return -EINVAL;
- pkt = kmalloc(sizeof(*pkt), GFP_KERNEL);
- if (!pkt)
- return -ENOMEM;
-
- err = __vmci_transport_send_control_pkt(pkt, &vsk->local_addr,
- &vsk->remote_addr, type, size,
- mode, wait, proto, handle,
- true);
- kfree(pkt);
-
- return err;
+ ret...
2011 Jun 07
2
[PATCH] examples/nginx.conf: add ipv6only comment
...# listen 80 default accept_filter=httpready; # for FreeBSD
+ # If you have IPv6, you''ll likely want to have two separate listeners.
+ # One on IPv4 only (the default), and another on IPv6 only instead
+ # of a single dual-stack listener. A dual-stack listener will make
+ # $remote_addr will make IPv4 addresses ugly (e.g ":ffff:10.0.0.1"
+ # instead of just "10.0.0.1") and potentially trigger bugs in
+ # some software.
+ # listen [::]:80 ipv6only=on; # deferred or accept_filter recommended
+
client_max_body_size 4G;
server_name _;
--
Eric...
2016 Jul 27
2
Proxy
Hi all,
I want to do a proxy to icecast (:8000) with nginx (:80).
Its working for me, stream is running on port 80, but on the first loading
is "pending" For a long time before its starts play.
Who using the "proxy_pass" on nginx and can help?
Thnx.
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
2023 Jul 05
1
Getvar of CHANNEL not working for a couple of items
...t;1734d973-c4da-4ae8-a37d-5f7065f1fe54" , local_addr: "172.31.253.4:5060 <http://172.31.253.4:5060> " , remote_uri: "\\\"TestPhone x111\\\" <sip:111 at mydomain.com <mailto:sip%3A111 at mydomain.com> >" , remote_tag: "yinue4v5ufa4" , remote_addr: "172.31.253.20:5060 <http://172.31.253.20:5060> "
Channel B: "1688509741.113" , name: "PJSIP/222-00000065" , is originator: N , call-Id: "1f104544-fc1a-4414-ba74-68c526e294de" , local_uri: "\\\"TestPhone\\\" <sip:111 at...
2016 Dec 07
1
[PATCH 09/10] vsock/virtio: fix src/dst cid format
...D;
>
> vchild = vsock_sk(child);
> - vsock_addr_init(&vchild->local_addr, le32_to_cpu(pkt->hdr.dst_cid),
> + vsock_addr_init(&vchild->local_addr, le64_to_cpu(pkt->hdr.dst_cid),
> le32_to_cpu(pkt->hdr.dst_port));
> - vsock_addr_init(&vchild->remote_addr, le32_to_cpu(pkt->hdr.src_cid),
> + vsock_addr_init(&vchild->remote_addr, le64_to_cpu(pkt->hdr.src_cid),
> le32_to_cpu(pkt->hdr.src_port));
>
> vsock_insert_connected(vchild);
> @@ -904,9 +904,9 @@ void virtio_transport_recv_pkt(struct virtio_vsock_pkt *pkt...
2019 Nov 14
15
[PATCH net-next v2 00/15] vsock: add multi-transports support
...ssigned to the guest->host transport
RFC: https://patchwork.ozlabs.org/cover/1168442/
v1: https://patchwork.ozlabs.org/cover/1181986/
v1 -> v2:
- Patch 11:
+ vmci_transport: sent reset when vsock_assign_transport() fails
[Jorgen]
+ fixed loopback in the guests, checking if the remote_addr is the
same of transport_g2h->get_local_cid()
+ virtio_transport_common: updated space available while creating
the new child socket during a connection request
- Patch 12:
+ removed 'features' variable in vmci_transport_init() [Stefan]
+ added a flag to register...