<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Login with valid client IP to HP-UX11i in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/login-with-valid-client-ip-to-hp-ux11i/m-p/3221315#M571127</link>
    <description>Hello Dietmar,&lt;BR /&gt;i've coded the following. But everytime the script does the "else" statement with tis message.&lt;BR /&gt;&lt;BR /&gt;checkip_dittbern[16]: [[192.168.1.36:  not found. &lt;BR /&gt;------------------------------------------&lt;BR /&gt;who -Rm | read line&lt;BR /&gt;FROM=${line##*\(}; FROM=${FROM%%\)*}&lt;BR /&gt;echo "$FROM"&lt;BR /&gt;&lt;BR /&gt;sleep 2&lt;BR /&gt;&lt;BR /&gt;if [[ $FROM != [0-9]*.[0-9]*.[0-9]*.[0-9]* ]]; then&lt;BR /&gt;FROM=$(nslookup $FROM | grep Adress | tail -1 | awk -F '[^0-9.]+''{print $2}')&lt;BR /&gt;fi&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;#if [["$FROM" = 192.168.1.116 ]]; then&lt;BR /&gt;if "$FROM" = 192.168.1.36&lt;BR /&gt;then&lt;BR /&gt;echo "Right IP $FROM"&lt;BR /&gt;sleep 2&lt;BR /&gt;exec ba6.1&lt;BR /&gt;&lt;BR /&gt;else&lt;BR /&gt;echo "Wrong IP $FROM"&lt;BR /&gt;exit&lt;BR /&gt;&lt;BR /&gt;fi&lt;BR /&gt;------------------------------------------</description>
    <pubDate>Fri, 19 Mar 2004 02:40:06 GMT</pubDate>
    <dc:creator>Bernd Dittmar</dc:creator>
    <dc:date>2004-03-19T02:40:06Z</dc:date>
    <item>
      <title>Login with valid client IP to HP-UX11i</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/login-with-valid-client-ip-to-hp-ux11i/m-p/3221306#M571118</link>
      <description>Hello all,&lt;BR /&gt;i want to check, if a user comes from a valid client after login.&lt;BR /&gt;In .profile: check if client ip &amp;lt;&amp;gt; 192.168.x.x&lt;BR /&gt;then exit&lt;BR /&gt;Anny ideas ?&lt;BR /&gt;&lt;BR /&gt;Regards Bernd</description>
      <pubDate>Wed, 17 Mar 2004 07:20:39 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/login-with-valid-client-ip-to-hp-ux11i/m-p/3221306#M571118</guid>
      <dc:creator>Bernd Dittmar</dc:creator>
      <dc:date>2004-03-17T07:20:39Z</dc:date>
    </item>
    <item>
      <title>Re: Login with valid client IP to HP-UX11i</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/login-with-valid-client-ip-to-hp-ux11i/m-p/3221307#M571119</link>
      <description>Bernd,&lt;BR /&gt;Could you please elaborate a little more on what you are trying to achieve?&lt;BR /&gt;&lt;BR /&gt;Are you trying to limit the users logging into your server based on a pattern of client ip addresses like 192.168.x.x&lt;BR /&gt;&lt;BR /&gt;rgds&lt;BR /&gt;Mobeen</description>
      <pubDate>Wed, 17 Mar 2004 07:32:01 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/login-with-valid-client-ip-to-hp-ux11i/m-p/3221307#M571119</guid>
      <dc:creator>Mobeen_1</dc:creator>
      <dc:date>2004-03-17T07:32:01Z</dc:date>
    </item>
    <item>
      <title>Re: Login with valid client IP to HP-UX11i</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/login-with-valid-client-ip-to-hp-ux11i/m-p/3221308#M571120</link>
      <description>Hello Mobeen,&lt;BR /&gt;&lt;BR /&gt;i want to check, if the user "ABC" is not telnet 'ing from the clients ip (e.g)&lt;BR /&gt;192.168.1.35, then exit in .profile.&lt;BR /&gt;&lt;BR /&gt;I don't want to block a range of IP's.&lt;BR /&gt;&lt;BR /&gt;Is there a system variable for the client IP ?&lt;BR /&gt;&lt;BR /&gt;Regards Bernd</description>
      <pubDate>Wed, 17 Mar 2004 07:40:46 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/login-with-valid-client-ip-to-hp-ux11i/m-p/3221308#M571120</guid>
      <dc:creator>Bernd Dittmar</dc:creator>
      <dc:date>2004-03-17T07:40:46Z</dc:date>
    </item>
    <item>
      <title>Re: Login with valid client IP to HP-UX11i</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/login-with-valid-client-ip-to-hp-ux11i/m-p/3221309#M571121</link>
      <description>You will need a table of valid IP addresses and then have something like this in the .profile&lt;BR /&gt; &lt;BR /&gt; grep `who -R am i | cut -c39-` &lt;IP list="" file=""&gt; &amp;gt; /dev/null || {&lt;BR /&gt; echo "Invalid ip address"&lt;BR /&gt; exit&lt;BR /&gt;}&lt;BR /&gt; &lt;BR /&gt;Look at the output of who -R to see where this is going.&lt;/IP&gt;</description>
      <pubDate>Wed, 17 Mar 2004 08:01:11 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/login-with-valid-client-ip-to-hp-ux11i/m-p/3221309#M571121</guid>
      <dc:creator>Mark Grant</dc:creator>
      <dc:date>2004-03-17T08:01:11Z</dc:date>
    </item>
    <item>
      <title>Re: Login with valid client IP to HP-UX11i</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/login-with-valid-client-ip-to-hp-ux11i/m-p/3221310#M571122</link>
      <description>Some recycled code from another script I hacked some years ago...&lt;BR /&gt; &lt;BR /&gt;who -Rm | read line&lt;BR /&gt;FROM=${line##*\(}; FROM=${FROM%%\)*}&lt;BR /&gt;if [[ $FROM != [0-9]*.[0-9]*.[0-9]*.[0-9]* ]]; then&lt;BR /&gt;  FROM=$(nslookup $FROM | grep Address | tail -1 | awk -F '[^0-9.]+' '{print $2}')&lt;BR /&gt;fi&lt;BR /&gt;&lt;BR /&gt;if [[ "$FROM" != [0-9]*.[0-9]*.[0-9]*.[0-9]* ]]; then&lt;BR /&gt;  echo "Unknown Source IP."&lt;BR /&gt;  exit&lt;BR /&gt;fi&lt;BR /&gt;&lt;BR /&gt;if [[ "$FROM" = 192.168.1.35 ]]; then&lt;BR /&gt;  echo "Forbidden Source IP $FROM."&lt;BR /&gt;  exit&lt;BR /&gt;fi&lt;BR /&gt; &lt;BR /&gt;Best regards...&lt;BR /&gt;Dietmar.</description>
      <pubDate>Wed, 17 Mar 2004 08:27:08 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/login-with-valid-client-ip-to-hp-ux11i/m-p/3221310#M571122</guid>
      <dc:creator>Dietmar Konermann</dc:creator>
      <dc:date>2004-03-17T08:27:08Z</dc:date>
    </item>
    <item>
      <title>Re: Login with valid client IP to HP-UX11i</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/login-with-valid-client-ip-to-hp-ux11i/m-p/3221311#M571123</link>
      <description>Oops... I forgot another straight-forward and more bullet-proof approach.&lt;BR /&gt; &lt;BR /&gt;Don't use .profile... use /var/adm/inetd.sec inestead:&lt;BR /&gt; &lt;BR /&gt;telnet deny 192.168.1.35 &lt;BR /&gt;ftp deny 192.168.1.35&lt;BR /&gt;shell deny 192.168.1.35&lt;BR /&gt;login deny 192.168.1.35&lt;BR /&gt; &lt;BR /&gt;Best regards...&lt;BR /&gt;Dietmar.</description>
      <pubDate>Wed, 17 Mar 2004 08:57:43 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/login-with-valid-client-ip-to-hp-ux11i/m-p/3221311#M571123</guid>
      <dc:creator>Dietmar Konermann</dc:creator>
      <dc:date>2004-03-17T08:57:43Z</dc:date>
    </item>
    <item>
      <title>Re: Login with valid client IP to HP-UX11i</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/login-with-valid-client-ip-to-hp-ux11i/m-p/3221312#M571124</link>
      <description>Hello Dietmar,&lt;BR /&gt;&lt;BR /&gt;it's o.k. in .profile !&lt;BR /&gt;&lt;BR /&gt;I'll do the following:&lt;BR /&gt;&lt;BR /&gt;..........&lt;BR /&gt;if [["$FROM" &amp;lt;&amp;gt; 192.168.1.116]]; then&lt;BR /&gt;echo "Wrong client / User combination"&lt;BR /&gt;exit&lt;BR /&gt;fi&lt;BR /&gt;&lt;BR /&gt;Regards Bernd</description>
      <pubDate>Wed, 17 Mar 2004 09:11:54 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/login-with-valid-client-ip-to-hp-ux11i/m-p/3221312#M571124</guid>
      <dc:creator>Bernd Dittmar</dc:creator>
      <dc:date>2004-03-17T09:11:54Z</dc:date>
    </item>
    <item>
      <title>Re: Login with valid client IP to HP-UX11i</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/login-with-valid-client-ip-to-hp-ux11i/m-p/3221313#M571125</link>
      <description>I have to agree with Dietmar here.  Using /var/adm/inetd.sec will be MUCH MUCH easier and much less work thatn worrying with the users .profile.  You can add multiple entries, or entire networks to inetd.sec and all you have to do after a change is an 'inetd -c' and you are done.</description>
      <pubDate>Wed, 17 Mar 2004 09:23:24 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/login-with-valid-client-ip-to-hp-ux11i/m-p/3221313#M571125</guid>
      <dc:creator>Patrick Wallek</dc:creator>
      <dc:date>2004-03-17T09:23:24Z</dc:date>
    </item>
    <item>
      <title>Re: Login with valid client IP to HP-UX11i</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/login-with-valid-client-ip-to-hp-ux11i/m-p/3221314#M571126</link>
      <description>inetd.sec is by far the better choice because it would be trivially easy for a user to change his own .profile (or at least remove it even if owned by root).&lt;BR /&gt;</description>
      <pubDate>Wed, 17 Mar 2004 10:47:23 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/login-with-valid-client-ip-to-hp-ux11i/m-p/3221314#M571126</guid>
      <dc:creator>A. Clay Stephenson</dc:creator>
      <dc:date>2004-03-17T10:47:23Z</dc:date>
    </item>
    <item>
      <title>Re: Login with valid client IP to HP-UX11i</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/login-with-valid-client-ip-to-hp-ux11i/m-p/3221315#M571127</link>
      <description>Hello Dietmar,&lt;BR /&gt;i've coded the following. But everytime the script does the "else" statement with tis message.&lt;BR /&gt;&lt;BR /&gt;checkip_dittbern[16]: [[192.168.1.36:  not found. &lt;BR /&gt;------------------------------------------&lt;BR /&gt;who -Rm | read line&lt;BR /&gt;FROM=${line##*\(}; FROM=${FROM%%\)*}&lt;BR /&gt;echo "$FROM"&lt;BR /&gt;&lt;BR /&gt;sleep 2&lt;BR /&gt;&lt;BR /&gt;if [[ $FROM != [0-9]*.[0-9]*.[0-9]*.[0-9]* ]]; then&lt;BR /&gt;FROM=$(nslookup $FROM | grep Adress | tail -1 | awk -F '[^0-9.]+''{print $2}')&lt;BR /&gt;fi&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;#if [["$FROM" = 192.168.1.116 ]]; then&lt;BR /&gt;if "$FROM" = 192.168.1.36&lt;BR /&gt;then&lt;BR /&gt;echo "Right IP $FROM"&lt;BR /&gt;sleep 2&lt;BR /&gt;exec ba6.1&lt;BR /&gt;&lt;BR /&gt;else&lt;BR /&gt;echo "Wrong IP $FROM"&lt;BR /&gt;exit&lt;BR /&gt;&lt;BR /&gt;fi&lt;BR /&gt;------------------------------------------</description>
      <pubDate>Fri, 19 Mar 2004 02:40:06 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/login-with-valid-client-ip-to-hp-ux11i/m-p/3221315#M571127</guid>
      <dc:creator>Bernd Dittmar</dc:creator>
      <dc:date>2004-03-19T02:40:06Z</dc:date>
    </item>
    <item>
      <title>Re: Login with valid client IP to HP-UX11i</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/login-with-valid-client-ip-to-hp-ux11i/m-p/3221316#M571128</link>
      <description>&lt;BR /&gt;if [[ $FROM = "192.168.1.36" ]] ; then&lt;BR /&gt;&lt;BR /&gt;you really should use inetd.sec this is what it is designed to do.&lt;BR /&gt;&lt;BR /&gt;John.</description>
      <pubDate>Fri, 19 Mar 2004 03:02:45 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/login-with-valid-client-ip-to-hp-ux11i/m-p/3221316#M571128</guid>
      <dc:creator>John Carr_2</dc:creator>
      <dc:date>2004-03-19T03:02:45Z</dc:date>
    </item>
  </channel>
</rss>

