Follow @Openwall on Twitter for new release announcements and other news
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Thu, 17 Mar 2011 01:58:06 +0100
From: Piotr Meyer <aniou@...tek.pl>
To: owl-dev@...ts.openwall.com
Subject: Re: VLANs in Owl way?

On Thu, Mar 17, 2011 at 03:11:04AM +0300, Solar Designer wrote:
 
> Are you saying that the lines that you're commenting out were dead code
> before your change, because GATEWAY and GATEWAYDEV were never(?) set by
> that point?

Not exactly - the code provides support for GATEWAY (without GATEWAYDEV)
settings in ifcfg-*, but I don't remember if I even seen similar config
in real world. This is fragment of original code:

[...]
    # this is broken! it's only here for compatibility with old RH systems
    if [ "${GATEWAY}" != "" -a "${GATEWAY}" != "none" ]; then
        route add default gw ${GATEWAY} metric 1 ${DEVICE}
    fi

    . /etc/sysconfig/network

    if [ "${GATEWAYDEV}" = "" -o "${GATEWAYDEV}" = "${DEVICE}" ]; then
        # set up default gateway
        if [ "${GATEWAY}" != "" ]; then
            route add default gw ${GATEWAY} ${DEVICE}
            DEFGW=${GATEWAY}
        elif [ "${GATEWAYDEV}" = "${DEVICE}" ]; then
            route add default ${DEVICE}
        fi
    fi
[...]

As you see - /etc/sysconfig/network is included after 'broken' code and
GATEWAY may be set only in ifcfg-* interface config. It is even mentioned
in sysconfig.txt (additional GATEWAY parameter in interface session, I
miss it before). 

'Normal' gateway is set in next session, after including /etc/sysconfig/network.

I can preserve this code even without ipcalc comparisons, if it is necessary,
but I'm not sure that is worth it.

> Have you tested your patched scripts on a system that does _not_ use
> VLANs - that is, on a system with just a very basic networking config
> (such as what "settle" produces)?

I make additional tests and wrote report, ok?

-- 
Piotr 'aniou' Meyer

Powered by blists - more mailing lists

Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.