5 Replies Latest reply on May 11, 2006 2:43 PM by acoliver

    Wildcard domains?

    osterday

      Can I get JBoss Mail Server to accept email to *.domain.com?

      Our app uses subdomains and I'd like to configure it to use wildcards - is this possible, or do I need to dig into the source?

      I've got a mail listener working to deliver basic emails into our app, but only with the main domain - I did try putting the wildcard in the config, but that didn't seem to work.

      Thanks!

        • 1. Re: Wildcard domains?
          acoliver

          No but you can list multiple domains. How many bla.domain.com's do you have? Meaning is this really that you really need to do this as a wildcard (which I don't really like from a security perspective to be honest) or is this just "I don't feel like typing them all" (and if so how many are we talking)? And how are your users mapped to these domains?

          • 2. Re: Wildcard domains?
            osterday

            There could be many subdomains and they are created dynamically. For our app we call the subdomains "sites". So one site could be x.domain.com and another might be y.domain.com and a@x.domain.com is different from a@y.domain.com.

            Basically all the user mapping and storage is done in our app. The listener will lookup if the user is valid in our system, etc.

            Does that make sense? I understand some of the security concerns, but I think that this might be useful for hosted apps.

            Another, and I guess better option, would be to programmatically add the domains to the DomainGroup - can that be done?

            Thanks!

            • 3. Re: Wildcard domains?
              acoliver

              hummm...sounds like you're selling V14GR4 ;-)

              This can be done programatically. However the programatic domains would not persist accross restarts. However, if you look at the code in org.jboss.mail.management (in HEAD and M5 branch) we have resolved that issue as well. It requires a later version of JBoss than JBCS 1.0M5pre1 will distribute with (the next RC3 or build from the 4.0 branch) but would do what you need (programatically add domains and persist them).

              • 4. Re: Wildcard domains?
                osterday

                Thanks for the reply.

                Nope, no V14GR4! Actually it's mainly for receiving emails, not sending. Our app sends out only from one email address, with the "reply to" going to the appropriate recipient.

                For our first version and tests, I think we can get by without dynamically adding domains, but it's great that we can do this in the future. And I guess that is better than just setting up a wildcard.

                I do worry about spam coming into JBoss Mail Server - I guess you guys have an idea about this too? And viruses? (I think I saw a post about a Java spam filter.) I was wondering if there was a way to configure our sendmail server to get the emails first, filter them (SpamAssassin and ClamAV), and forward to JBoss Mail Server... but that's getting off topic...

                Thanks!

                • 5. Re: Wildcard domains?
                  acoliver

                  Yeah this is about creating a mail listener for those. Just do me a favor and DONT have it send emails to the "REPLY TO" that "your email was filtered" because I get them from 1000000000 addresses on the net that some virus that THEY KNOW forges reply-to has indeed used my email as the reply-to :-)

                  We'll have a JASEN listener in the M6 release.