<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta http-equiv="Content-Type" content="text/html;charset=ISO-8859-1">
  <title></title>
</head>
<body text="#000000" bgcolor="#ffffff">
Hi I don't know how to use the setuid command.<br>
<br>
I were trying to find some documentation or tutorial and BTW I red the
manual information for the setuid function.<br>
<br>
I tried to add the following line at the rtpproxy init script but I
only got an error:<br>
setuid ser<br>
<br>
Could anybody give me a hand?<br>
<br>
Regards<br>
<br>
Alberto Cruz<br>
<br>
Greger V. Teigre wrote:<br>
<blockquote type="cite" cite="mid44B3404D.9010609@teigre.com">
  <meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
  <title></title>
Alberto,<br>
Typically, you will run rtpproxy with the same user (or at least group)
as ser or you can change permission on the socket file after starting
rtpproxy in your init script (chmod to be more targeted).<br>
g-)<br>
  <br>
Alberto Cruz wrote:
  <blockquote cite="mid44B2ECFE.7070605@tekbrain.com" type="cite">
    <meta http-equiv="Content-Type" content="text/html;">
    <title></title>
I found the problem. As Samuel have said the problem is with socket
permissions.<br>
    <br>
When the RTPProxy is already running and I modified the permissions or
owner to the rtpproxy.sock file it works but as soon as I restart the
deamon the permissions <br>
go back again to the original permissions.<br>
    <br>
This is something to do with how the rtproxy is creating the .socket
file at the time it starts and it defines the permissions to srwxr-xr-x
for the user and group equal to root.<br>
    <br>
So as I have been running SER with user and group as ser, SER can't
talk to the socket.<br>
    <br>
I need to modify the way like RTPROXY runs in other to start the daemon
with another user or with different permissions for the socket file.<br>
    <br>
In the meantime I applied the "umask 000" command at the
"/etc/init.d/rtproxy" file and it works but it modifies the .pid file
too.<br>
    <br>
Is there a way to tell rtpproxy daemon to run with a different user for
example user ser ?<br>
    <br>
Regards<br>
    <br>
Alberto Cruz<br>
    <br>
Alberto Cruz wrote:<br>
    <blockquote type="cite" cite="mid44B2AEBC.9030905@tekbrain.com">
      <meta http-equiv="Content-Type" content="text/html;">
      <title></title>
RTPROXY is running as it default:<br>
root&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 2332&nbsp;&nbsp;&nbsp;&nbsp; 1&nbsp; 0 Jul09 ?&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 00:00:00 /usr/sbin/rtpproxy<br>
      <br>
And SER is running as follow:<br>
ser&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 4612&nbsp; 4575&nbsp; 0 Jul09 ?&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 00:00:00 /usr/sbin/ser -P
/var/run/ser/ser.pid -u ser -g ser<br>
      <br>
And the socket File is like this:<br>
-rw-r--r--&nbsp;&nbsp; 1 root&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; root&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 5 2006-07-09 02:45
rtpproxy.pid<br>
srwxr-xr-x&nbsp;&nbsp; 1 root&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; root&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 0 2006-07-09 02:45
rtpproxy.sock<br>
      <br>
I already tried changing the owner and group for the rtpproxy.sock but
it didn't work<br>
      <br>
Regards<br>
      <br>
Acruz<br>
samuel wrote:<br>
      <blockquote type="cite"
 cite="midd18bd3a10607100707g2426a47at8b5d0d45f0a44e6b@mail.gmail.com">Maybe
something's wrong with the socket permissions.... which are the
owner/group which SER and rtproxy are running??<br>
        <br>
Check wether SER user has permissions wnough to access the rtproxy
socket.<br>
        <br>
Hope it helps,<br>
Samuel.<br>
        <br>
        <br>
        <div><span class="gmail_quote">2006/7/10, Alberto Cruz &lt;<a
 href="mailto:acruz@tekbrain.com" target="_blank"
 onclick="return top.js.OpenExtLink(window,event,this)">acruz@tekbrain.com</a>&gt;:</span>
        <blockquote class="gmail_quote"
 style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
          <div>
          <div text="#000000" bgcolor="#ffffff"> Hi Jan and Maxim:<br>
Maybe you can help me with this.<br>
I'm using Debian sarge r3.0 and SER apt packages (0.9.6)<br>
          <br>
I was looking at the CVS Repository if there was something related to
this behavior with RTPPROXY and I found the following annotation for
ser/rtpproxy/main.c on July 4: <br>
          <pre>Since we are now opening control socket in non-blocking mode, there is race condition between accepting stream connection on unix domain socket and availability of data on the socket. Patch it by doing read() in a loop until we actually get the data. While I am here, allow V command to take extra argument, which we don't process but put into the log file. This allows to pass some extra information from the client (SER in this case) such as PID number for example.  
    </pre>
Does it have something to do with my problem? BTW I found a bug posted
too at the <a href="http://lists.debian.org" target="_blank"
 onclick="return top.js.OpenExtLink(window,event,this)">lists.debian.org</a>:<br>
          <a
 href="http://url?sa=U&amp;start=3&amp;q=http://lists.debian.org/debian-devel/2006/03/msg00561.html&amp;e=14905&amp;ei=caixRPnxNJbMwQL-jbXTCQ"
 target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">Bug#356721:
ITP: <b>rtpproxy</b> -- RTP proxy for SER</a><br>
          <br>
Am I doing something wrong with my installation/configuration or is it
a bug?</div>
          <div><span><br>
          <br>
Regards<br>
          <br>
Alberto Cruz <br>
          <br>
Andres wrote: <br>
          <blockquote type="cite"
 cite="http://mid44B19E5F.9090604@telesip.net">Alberto Cruz wrote: <br>
            <br>
            <blockquote type="cite">I tried but I'm still receiving the
same
messages: <br>
Jul&nbsp; 9 17:51:58 sermex02 /usr/sbin/ser[3902]: DEBUG: init_mod_child
(-4): nathelper <br>
Jul&nbsp; 9 17:51:58 sermex02 /usr/sbin/ser[3902]: ERROR: send_rtpp_command:
can't connect to RTP proxy <br>
Jul&nbsp; 9 17:51:58 sermex02 /usr/sbin/ser[3902]: WARNING: rtpp_test: can't
get version of the RTP proxy <br>
Jul&nbsp; 9 17:51:58 sermex02 /usr/sbin/ser[3902]: WARNING: rtpp_test:
support for RTP proxy has been disabled temporarily <br>
              <br>
Does anybody else have seen this behavior? <br>
            </blockquote>
            <br>
Yes, that happens when the nathelper module is unable to contact the
rtppoxy either because it is not running or it is an old version and is
incompatible with your nathelper. <br>
            <br>
            <blockquote type="cite"><br>
Regards <br>
              <br>
Alberto Cruz <br>
              <br>
Andres wrote: <br>
              <br>
              <blockquote type="cite">Alberto Cruz wrote: <br>
                <br>
                <blockquote type="cite">I have checked and the RTPProxy
is
running and listening: <br>
                  <br>
Active UNIX domain sockets (servers and established) <br>
Proto RefCnt Flags&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Type&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; State&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; I-Node Path <br>
unix&nbsp; 2&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [ ACC ]&nbsp;&nbsp;&nbsp;&nbsp; STREAM&nbsp;&nbsp;&nbsp;&nbsp; LISTENING&nbsp;&nbsp;&nbsp;&nbsp; 3121&nbsp;&nbsp;&nbsp;&nbsp;
/tmp/.gdm_socket <br>
unix&nbsp; 2&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [ ACC ]&nbsp;&nbsp;&nbsp;&nbsp; STREAM&nbsp;&nbsp;&nbsp;&nbsp; LISTENING&nbsp;&nbsp;&nbsp;&nbsp; 1765&nbsp;&nbsp;&nbsp;&nbsp;
/var/run/dirmngr/socket <br>
unix&nbsp; 2&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [ ACC ]&nbsp;&nbsp;&nbsp;&nbsp; STREAM&nbsp;&nbsp;&nbsp;&nbsp; LISTENING&nbsp;&nbsp;&nbsp;&nbsp; 20376&nbsp;&nbsp;&nbsp;
/var/run/rtpproxy.sock <br>
unix&nbsp; 2&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [ ACC ]&nbsp;&nbsp;&nbsp;&nbsp; STREAM&nbsp;&nbsp;&nbsp;&nbsp; LISTENING&nbsp;&nbsp;&nbsp;&nbsp; 2029&nbsp;&nbsp;&nbsp;&nbsp;
/var/run/mysqld/mysqld.sock <br>
                  <br>
And the rtpproxy socket configuration at ser.cfg is ok too: <br>
# -- nathelper params -- <br>
modparam("nathelper", "natping_interval", 30) <br>
modparam("nathelper", "ping_nated_only", 1) <br>
modparam("nathelper", "rtpproxy_sock", "unix:/var/run/rtpproxy.sock") <br>
                  <br>
                </blockquote>
Try this instead: <br>
modparam("nathelper", "rtpproxy_sock", "/var/run/rtpproxy.sock") <br>
                <br>
                <br>
              </blockquote>
              <br>
              <br>
            </blockquote>
            <br>
            <br>
          </blockquote>
          </span></div>
          </div>
          <br>
_______________________________________________<br>
Serusers mailing list<br>
          <a href="mailto:Serusers@lists.iptel.org" target="_blank"
 onclick="return top.js.OpenExtLink(window,event,this)">Serusers@lists.iptel.org</a><br>
          <a href="http://lists.iptel.org/mailman/listinfo/serusers"
 target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://lists.iptel.org/mailman/listinfo/serusers</a><br>
          <br>
          <br>
        </blockquote>
        </div>
        <br>
      </blockquote>
    </blockquote>
    <pre wrap=""><hr size="4" width="90%">
_______________________________________________
Serusers mailing list
<a class="moz-txt-link-abbreviated"
 href="mailto:Serusers@lists.iptel.org">Serusers@lists.iptel.org</a>
<a class="moz-txt-link-freetext"
 href="http://lists.iptel.org/mailman/listinfo/serusers">http://lists.iptel.org/mailman/listinfo/serusers</a>
  </pre>
  </blockquote>
</blockquote>
</body>
</html>