diff --git a/doc/conf/examples/example.conf b/doc/conf/examples/example.conf index dcbb32fc1..e5d652b41 100644 --- a/doc/conf/examples/example.conf +++ b/doc/conf/examples/example.conf @@ -215,16 +215,33 @@ link hub.mynet.org options { ssl; }; }; - password "00:11:22:33:44:55:66:77:88:99:AA:BB:CC:DD:EE:FF"; /* SSL fingerprint of other server */ + /* We use the SPKI fingerprint of the other server for authentication. + * Run './unrealircd spkifp' on the other side to get it. + * NOTE: requires UnrealIRCd 4.0.16 or later. + */ + password "AABBCCDDEEFFGGHHIIJJKKLLMMNNOOPPQQRRSSTTUUV=" { spkifp; }; + + class servers; +}; + +/* The link block for services is usually much simpler. + * For more information about what Services are, + * see https://www.unrealircd.org/docs/Services + */ +link services.mynet.org +{ + incoming { + mask 127.0.0.1; + }; + + password "changemeplease"; class servers; }; /* U-lines give other servers (even) more power/commands. * If you use services you must add them here. - * NEVER put the name of a (normal) UnrealIRCd server here!!! - * ( If you wonder what Services are then see - * https://www.unrealircd.org/docs/Services ) + * NEVER put the name of an UnrealIRCd server here!!! */ ulines { services.mynet.org; diff --git a/src/auth.c b/src/auth.c index 6c09bc5b7..8597b532b 100644 --- a/src/auth.c +++ b/src/auth.c @@ -507,6 +507,12 @@ int Auth_Check(aClient *cptr, anAuthStruct *as, char *para) case AUTHTYPE_PLAINTEXT: if (!para) return -1; + if (!strcmp(as->data, "changemeplease") && !strcmp(para, as->data)) + { + sendto_realops("Rejecting default password 'changemeplease'. " + "Please change the password in the configuration file."); + return -1; + } /* plain text compare */ if (!strcmp(para, as->data)) return 2;