Re: [exim] ACL filtering 3 dashes in host name

Kezdőlap
Üzenet törlése
Válasz az üzenetre
Szerző: Always Learning
Dátum:  
Címzett: Exim Users
Tárgy: Re: [exim] ACL filtering 3 dashes in host name

Hi Eli,

> If you have access to Linux


Right next to me and also on two production servers at a data centre. I
use Centos 5 usually from the command line probably because that was the
way computers always worked before the luxury of GUIs. Wasn't Apple in
1986 the first ?

>, a good place to start to try to just figure out
> the basics of RE's is to "man regex".


Dislike 'man' in the command line environment. Never tried it yet in X.

> http://www.php.net/manual/en/pcre.pattern.php


I'll try the PHP one since you think its good.

> Unfortunately, as is your case, I do not have time to try and help you with
> your actual RE issue and create some for you to match hostnames with
> multiple dashes in them,


Not so much multiple but specifically 3, not 2 and not 4.

I was seeking a quick and short response. I received that from some of
the others and am grateful for their kind and enlightening assistance.

> though safe to say that you're in for a world of
> (brain-related) hurt when you try to figure out why your patterns are
> horribly, horribly wrong


You're kidding me. I can usually independently analyse most things and
devise an effective solution. Its called tenacity and uses normal brain
power. Understanding the logic why something does not work as expected
is relatively simple but can be time-consuming.

>(I'll give you a hint - the wildcard * is meant to
> match anything, right? How does it know you do NOT want it to also match a
> dash?


My answer is *- which in my programming experience means ''anything
including nothing'' followed by a ''dash''. Note the dash is the
trailing delimiter. No ending dash means no match.

> This is where the term "greedy" comes in to play... the asterisk
> wildcard, especially in RE's, is a "greedy" match, meaning it will take
> everything you got - even when you don't want it to).


Wasn't trying to use RegExp but the same logic which permits *.vn to
work. Another poster explained why one form of * worked but the other
didn't.

Had a brief look at RegExp before. Had a more detailed look today with
the suggestions helpfully contributed on this list.

> Although I am unsure of your actual intentions in using Exim,


To benefit from its superior, to my old mail server, facilities. Exim
is good. I like it. Did a lot of reading comparing Exim and Postfix and
decided on Exim. I want to stay with Exim and expand its functionality
and usefulness via its configuration file.

> from the
> sounds of things you may have tried to dive in head first in to a little
> pile of mess to try and fix something or implement something for a superior?


I moved servers to Centos in October and quickly discovered Exim's basic
default configuration worked well as a backup relay. I also discovered
the Apache / PHP ''bug'' which ignored, when using PHP mail, -f
Eventually I discovered how to fix that in Exim. The default Exim
configuration file could definitely benefit from including that keyword
as a commented-out example.

> In any case - that's just not how it works I'm afraid, and you really do
> have to "study" the subject before you can try and use it.


Generally, every computer programme or system should be useable and
changeable to a varying extent without reading hundreds of manual pages.
They usually are. Exim certainly is. Its the more involved items that
require the manual. Playing with a computer programme and experimenting
with it always teaches me more about it than the manual on its own.

A good analogy is children mastering the video and DVD etc. without ever
reading any manual. Adults tend to rely exclusively on manuals but then
retain doubts. Another good example is children learning a foreign
language simply by playing with kids in another country. No manuals, no
formal instruction and they become fluent faster than adults laboriously
reading books and trying to get everything precisely right before daring
to say a word. Its a bit like that with computers. Manuals definitely
help but one first needs a feel for the thing before massive amounts of
reading.

Regards,

Paul.

--