[OpenWrt-Devel] Request for Support for namespaces in uci and netifd

2015-08-14 Thread Ashok Rao
I've started playing around with namespaces and it is quite powerful.
Allows one to build multiple routers and connect them all inside the same
low cost router platform.

However there doesn't seem to be any support for namespace in the config
files and generally within openwrt so  developing a package which uses
namespaces requires quite a few hacks.  For example running a dhcp client
on  an interface on a different non-default namespace requires some work -
for an example see
https://forum.openwrt.org/viewtopic.php?id=53332



Ashok
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] MSS clamping in POSTROUTING instead of FORWARD?

2012-03-02 Thread Ashok Rao
I don't see why moving the clamping to POSTROUTING causes the hiding of
issues inside openwrt. The example presented by Etienne is perfectly valid
and the suggestion to mpve the clamping to the POSTROUTING chain seems the
right way to go when you have multiple interfaces that could be used for a
packet.

I think this could be submitted as a ticket and we could let the developers
decide.  The other option of course is to add this to only the multiwan
package.

Ashok
On Wed, Feb 22, 2012 at 2:24 PM, Oliver
oli...@8.c.9.b.0.7.4.0.1.0.0.2.ip6.arpa wrote:

 On Wednesday 22 Feb 2012 10:09:09 Philip Prindeville wrote:
  I actually don't think that.
 
  I'm just pointing out that in corner cases, being overly conservative
  will increase your chances of success.

 Correct, but it does so by essentially alleviating the symptom of an
 underlying problem; since this change would be a great way of hiding any
 underlying TCP issues inside OpenWRT itself, I'm firmly against this idea -
 we should fix the root cause of a problem, not its symptoms.
  ___
 openwrt-devel mailing list
 openwrt-devel@lists.openwrt.org
 https://lists.openwrt.org/mailman/listinfo/openwrt-devel

___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] Dennis Ritchie, pioneer of C programming language and Unix, reported dead at age 70

2011-10-13 Thread Ashok Rao
Like many others this was the first book on programming that I bought
and after 30 years I still go back to it from time to time

http://www.engadget.com/2011/10/13/dennis-ritchie-pioneer-of-c-programming-language-and-unix-repo/
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] Preserving mgetty file permissions

2011-03-22 Thread Ashok Rao
I've run into this strange problem that if I use opkg to install
mgetty then the files in  /etc/mgetty+sendfax/ get set with the
correct permissions (0600).  However if I build mgetty into the image
and do a clean flash then the permissions revert to providing read and
write permissions to non root users. That is a problem because mgetty
refuses to accept logins if the login.config file in that directory is
read or writeable by normal users.

The mgetty makefile has the correct install  -m600  command. I have
also tried created postinst scripts which do not fix the problem. The
package is fine if installed afterwards - but not if it is built into
the image.

It appears that this might be related to Sergey's findings below
regarding the default permissions of files. I could change 0755 to
0600 but not sure what havoc that could cause.Other than putting
in a kludge to chmod every time the system boots - am at a loss

Ashok



On Sat, Nov 6, 2010 at 2:23 PM, Sergey Vlasov v...@altlinux.ru wrote:

 During the first OpenWrt boot after a clean flash (when the jffs2
 partition is not yet initialized) tmpfs is used instead of the usual
 jffs2 overlay filesystem.  If this tmpfs is mounted with default
 options, all directories created there (/etc, /etc/config, other
 subdirectories in /etc) get permissions 1777 by default, and these
 permissions then persist in the created jffs2 at least until
 subsequent sysupgrade.  Mounting tmpfs with mode=0755 fixes the
 permission problem.

 Signed-off-by: Sergey Vlasov v...@altlinux.ru
 ---
  package/base-files/files/lib/functions/boot.sh |    2 +-
  1 files changed, 1 insertions(+), 1 deletions(-)

 diff --git a/package/base-files/files/lib/functions/boot.sh 
 b/package/base-files/files/lib/functions/boot.sh
 index fc93eba..66423d9 100644
 --- a/package/base-files/files/lib/functions/boot.sh
 +++ b/package/base-files/files/lib/functions/boot.sh
 @@ -142,7 +142,7 @@ fopivot() { # rw_root ro_root dupe?

  ramoverlay() {
        mkdir -p /tmp/root
 -       mount -t tmpfs root /tmp/root
 +       mount -t tmpfs -o mode=0755 root /tmp/root
        fopivot /tmp/root /rom 1
  }

 --
 1.7.2.rc3.50.gbbbd

 ___
 openwrt-devel mailing list
 openwrt-devel@lists.openwrt.org
 https://lists.openwrt.org/mailman/listinfo/openwrt-devel
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] Adding ppp chat script results to interface status in luci

2011-01-09 Thread Ashok Rao
Hi Jo-Philipp:
Thanks for your suggestion. I had looked at network.lua  before - your
suggestion to use rv and the JSON API is very helpful
Thanks
Ashok


On Sat, Jan 8, 2011 at 10:54 AM, Jo-Philipp Wich x...@subsignal.org wrote:

 -BEGIN PGP SIGNED MESSAGE-
 Hash: SHA1

 Hey.

 So I assume you also managed to obtain the intersting information and
 are now stuck with trying to display it?

 Personally I'd do the following:

 - - Enhance controller/admin/network.lua, function iface_status and add
  the infor bits you want to display to the rv structrue
 - - Modify view/admin_network/iface_status.htm to pick up the extra data
  and render it along with the other stuff

 ~ Jow
 -BEGIN PGP SIGNATURE-
 Version: GnuPG v1.4.10 (GNU/Linux)
 Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

 iEYEARECAAYFAk0oiJoACgkQdputYINPTPMmHgCfUnaVrbewiSXdAWrHiyZ61JZB
 mpsAnRMCU3DfWoXS5/QH3iJnKWU7/8rC
 =dMik
 -END PGP SIGNATURE-

___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] Adding ppp chat script results to interface status in luci

2011-01-08 Thread Ashok Rao
Dear Jo-Philipp:

I am trying to enhance the ppp interface status  to report chat
results like NO DIALTONE, BUSY, etc. (for dial up).  While it is
relatively easy to filter syslog to extract this status (using
cmatch), I haven't been so successful in figuring out how to display
it through  (Admininstration/Network/Interfaces/Overview, and
Administration/Network/Interfaces/WAN).
Am starting with  model/cbi/admin_network/ifaces.lua  and the following section:

st = s:taboption(general, DummyValue, __status, translate(Status))
st.template = admin_network/iface_status
st.network  = arg[1]

If I use http.write - then it doesn't get written in this section (as
to be expected)

Ideally I would like to display the chat results here along with the
other interface statistics. This is primarily if the network is not up
yet due to a modem dial out error- so I started trying to enhance
view/admin_network/iface_status.htm.

But it's not been easy due to my lack of familiarity with the way luci
is set  up.  Have looked through the documentation  and that has
helped a bit.

Any pointers on the easiest way to do this.  I don't want to create a
new application or new screens for something which could exist  along
with other  interface statistics.

Thanks


Ashok Rao
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] [PATCH] Allows TIMEOUT to be specified as an environmental variable in chat scripts used by chat

2010-09-13 Thread Ashok Rao
Florian:
The patch to chat has been accepted upstream by Paul Mackerras -
maintainer of the pppd package.
See http://git.ozlabs.org/?p=ppp.git;a=summary
The next release of ppp (2.4.6 ?) should have it.
I think openwrt is currently one release behind  - i.e. it is at 2.4.4
Ashok




On Sun, Sep 5, 2010 at 9:45 PM, Ashok Rao greatar...@gmail.com wrote:
 OK Florian will do that. Looks like chat has not been worked on for
 years so I don't know how successful I will be.
 Regards
 Ashok


 On Sat, Sep 4, 2010 at 12:16 PM, Florian Fainelli flor...@openwrt.org wrote:
 Le Monday 23 August 2010 20:32:33, Ashok Rao a écrit :
 The ability of chat ( the program is found within the openwrt ppp
 package) to read environmental variables was introduced in 1999 !
 The TIMEOUT directive,  however, requires a hard coded value and
 ignores environmental variables (which are normally
 specified with a $..) .
 This is a simple one line addition to chat.c

 Can you submit that upstream as well?


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] [PATCH] Allows TIMEOUT to be specified as an environmental variable in chat scripts used by chat

2010-09-05 Thread Ashok Rao
OK Florian will do that. Looks like chat has not been worked on for
years so I don't know how successful I will be.
Regards
Ashok


On Sat, Sep 4, 2010 at 12:16 PM, Florian Fainelli flor...@openwrt.org wrote:
 Le Monday 23 August 2010 20:32:33, Ashok Rao a écrit :
 The ability of chat ( the program is found within the openwrt ppp
 package) to read environmental variables was introduced in 1999 !
 The TIMEOUT directive,  however, requires a hard coded value and
 ignores environmental variables (which are normally
 specified with a $..) .
 This is a simple one line addition to chat.c

 Can you submit that upstream as well?

___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH] Modifies iptables Makefile to package libipq as a shared library

2010-07-13 Thread Ashok Rao
r21799 by jow  changed the staging install of libipq so that it is no
longer available as a static library but is dynamically linked in as a
shared library. However the libipq package was not being built. This
patch provides libipq.so as a package.

Signed-off-by: Ashok Rao greatar...@gmail.com

---

Index: Makefile
===
--- Makefile(revision 22140)
+++ Makefile(working copy)
@@ -44,7 +44,7 @@
 $(call Package/iptables/Default)
   TITLE:=IPv4 firewall administration tool
   MENU:=1
-  DEPENDS+= +kmod-ipt-core +libiptc +libxtables
+  DEPENDS+= +kmod-ipt-core +libiptc +libxtables +libipq
 endef
 define Package/iptables/description
@@ -261,6 +261,12 @@
  TITLE:=IPv4/IPv6 firewall - shared xtables library
 endef
+define Package/libipq
+$(call Package/iptables/Default)
+  SECTION:=libs
+  CATEGORY:=Libraries
+  TITLE:=IPv4/IPv6 firewall - shared libipq library
+endef
 TARGET_CPPFLAGS := \
-I$(PKG_BUILD_DIR)/include \
@@ -361,6 +367,11 @@
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libxtables.so* $(1)/usr/lib/
 endef
+define Package/libipq/install
+   $(INSTALL_DIR) $(1)/usr/lib
+   $(CP) $(PKG_INSTALL_DIR)/usr/lib/libipq.so* $(1)/usr/lib/
+endef
+
 define BuildPlugin
   define Package/$(1)/install
$(INSTALL_DIR) $$(1)/usr/lib/iptables
@@ -399,3 +410,4 @@
 $(eval $(call BuildPackage,ip6tables-utils))
 $(eval $(call BuildPackage,libiptc))
 $(eval $(call BuildPackage,libxtables))
+$(eval $(call BuildPackage,libipq))
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH] Adds rawnat and rawpost package options to xtables-addons and bumps version up to 1.24

2010-07-13 Thread Ashok Rao
rawpost is an addition to the netfilter raw table.  rawnat is used to
do stateless NAT and is useful for multi-link wan load balancing of a
single flow.   v1.22 and prior of xtables-addons required ipv6 support
for rawnat.  v1.23 and later made that support optional.
Request bumping up xtables-addons to version 1.24 at the very least.
The latest  version is 1.27.
Ashok


---

Index: Makefile
===
--- Makefile(revision 22145)
+++ Makefile(working copy)
@@ -9,11 +9,11 @@
 include $(INCLUDE_DIR)/kernel.mk

 PKG_NAME:=xtables-addons
-PKG_VERSION:=1.22
+PKG_VERSION:=1.24
 PKG_RELEASE:=1

 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
-PKG_MD5SUM:=990e2d84a1767c8247c92ae7b11e53a9
+PKG_MD5SUM:=1b538a25ef82edb7a7ea7411d599d6b9
 PKG_SOURCE_URL:=...@sf/xtables-addons
 PKG_BUILD_DEPENDS:=iptables

@@ -93,3 +93,5 @@
 $(eval $(call 
BuildTemplate,tarpit,TARPIT,xt_TARPIT,xt_TARPIT,46,+kmod-ipt-compat-xtables))
 $(eval $(call BuildTemplate,tee,TEE,xt_TEE,xt_TEE,46,+kmod-ipt-compat-xtables))
 $(eval $(call BuildTemplate,ipp2p,IPP2P,xt_ipp2p,xt_ipp2p,46,))
+$(eval $(call 
BuildTemplate,rawpost,RAWPOST,,iptable_rawpost,46,+kmod-ipt-compat-xtables))
+$(eval $(call BuildTemplate,rawnat,RAWNAT,xt_RAWDNAT
xt_RAWSNAT,xt_RAWNAT,46,+kmod-ipt-compat-xtables))
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel