123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263 |
- // \file PostfixMilterConf.hpp
- //
- // Copyright (C) 2011 ARM Research Labs, LLC.
- // See www.armresearch.com for the copyright terms.
- //
- // This file defines the PostfixMilterConf interface.
- //
- // $Id$
- //
- ///////////////////////////////////////////////////////////////////////////////////////////////////
-
- #ifndef PostfixMilterConfhpp_included
- #define PostfixMilterConfhpp_included
-
- #include <string>
-
- /// Class to update smtpd_milters line in the postfix main.cf file.
- //
- //////////////////////////////////////////////////////////////////////////////////////////////////////////
- class PostfixMilterConf {
-
- public:
-
- /// Load a new configuration line.
- void ConfLine(std::string Line);
-
- /// Check whether the configuration line indicates that SNFMilter is integrated.
- //
- // \returns true if the line indicates integration, false otherwise.
- //
- bool IsIntegrated();
-
- /// Update the configuration line to integrate with SNFMilter.
- void AddIntegration();
-
- /// Update the configuration line to remove integration with SNFMilter.
- void RemoveIntegration();
-
- /// Get a copy of the configuration line.
- std::string ConfLine();
-
- /// Check whether the configuration line is a milter specification.
- //
- // \returns true if the configuration line is a milter
- // specification, false otherwise.
- //
- bool IsMilterLine();
-
- private:
-
- /// Check whether the configuration line contains a SNFMilter soecket specification.
- //
- // \returns true if the configuration line contains a SNFMilter
- // socket specification, false otherwise.
- //
- bool ContainsSnfMilterSocketSpec();
-
- /// Configuration line.
- std::string ConfigurationLine;
-
- };
-
- #endif
|