YoushouldhavereceivedacopyoftheGNUGeneralPublicLicense alongwiththisprogram;ifnot,writetotheFreeSoftware
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */
class Wsrep_allowlist_service : public wsrep::allowlist_service
{ public: bool allowlist_cb(wsrep::allowlist_service::allowlist_key key, const wsrep::const_buffer& value) WSREP_NOEXCEPT override;
};
bool Wsrep_allowlist_service::allowlist_cb (
wsrep::allowlist_service::allowlist_key key, const wsrep::const_buffer& value)
WSREP_NOEXCEPT
{ // Allow all connections if user has not given list of // allowed addresses or stored them on mysql.wsrep_allowlist // table. Note that table is available after SEs are initialized. bool res=true;
std::string string_value(value.data()); if (wsrep_schema)
{
res= wsrep_schema->allowlist_check(key, string_value);
} // If wsrep_schema is not initialized check if user has given // list of addresses where connections are allowed elseif (wsrep_allowlist && wsrep_allowlist[0] != '\0')
{
res= false; // Allow only given addresses
std::vector<std::string> allowlist;
wsrep_split_allowlist(allowlist); for(auto allowed : allowlist)
{ if (!string_value.compare(allowed))
{
res= true; // Address found allow connection break;
}
}
} return res;
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.