Links that are 'no-export' are not distributed to the rest of the IRC network (including local peers).
This provides a core primitive for 'anycasting' services (but the actual issue of synchronizing data in
a services package is left to the authors of the services package).
* compressed - compress traffic via ziplinks
* topicburst - burst topics between servers
* ssl - ssl/tls encrypted server connections
* compressed - compress traffic via ziplinks
* topicburst - burst topics between servers
* ssl - ssl/tls encrypted server connections
+ * no-export - marks the link as a no-export link (not exported to other links)
*/
flags = compressed, topicburst;
};
*/
flags = compressed, topicburst;
};
#define SERVER_TB 0x0010
#define SERVER_AUTOCONN 0x0020
#define SERVER_SSL 0x0040
#define SERVER_TB 0x0010
#define SERVER_AUTOCONN 0x0020
#define SERVER_SSL 0x0040
+#define SERVER_NO_EXPORT 0x0080
#define ServerConfIllegal(x) ((x)->flags & SERVER_ILLEGAL)
#define ServerConfEncrypted(x) ((x)->flags & SERVER_ENCRYPTED)
#define ServerConfIllegal(x) ((x)->flags & SERVER_ILLEGAL)
#define ServerConfEncrypted(x) ((x)->flags & SERVER_ENCRYPTED)
#define ServerConfTb(x) ((x)->flags & SERVER_TB)
#define ServerConfAutoconn(x) ((x)->flags & SERVER_AUTOCONN)
#define ServerConfSSL(x) ((x)->flags & SERVER_SSL)
#define ServerConfTb(x) ((x)->flags & SERVER_TB)
#define ServerConfAutoconn(x) ((x)->flags & SERVER_AUTOCONN)
#define ServerConfSSL(x) ((x)->flags & SERVER_SSL)
+#define ServerConfNoExport(x) ((x)->flags & SERVER_NO_EXPORT)
extern struct server_conf *make_server_conf(void);
extern void free_server_conf(struct server_conf *);
extern struct server_conf *make_server_conf(void);
extern void free_server_conf(struct server_conf *);
{ "encrypted", SERVER_ENCRYPTED },
{ "topicburst", SERVER_TB },
{ "ssl", SERVER_SSL },
{ "encrypted", SERVER_ENCRYPTED },
{ "topicburst", SERVER_TB },
{ "ssl", SERVER_SSL },
+ { "no-export", SERVER_NO_EXPORT },
if(!IsPerson(target_p))
continue;
if(!IsPerson(target_p))
continue;
+ if(MyClient(target_p->from) && target_p->localClient->att_sconf != NULL && ServerConfNoExport(target_p->localClient->att_sconf))
+ continue;
+
send_umode(NULL, target_p, 0, ubuf);
if(!*ubuf)
{
send_umode(NULL, target_p, 0, ubuf);
if(!*ubuf)
{
if(target_p == client_p)
continue;
if(target_p == client_p)
continue;
+ if(target_p->localClient->att_sconf != NULL && ServerConfNoExport(target_p->localClient->att_sconf))
+ continue;
+
if(has_id(target_p) && has_id(client_p))
{
sendto_one(target_p, ":%s SID %s 2 %s :%s%s",
if(has_id(target_p) && has_id(client_p))
{
sendto_one(target_p, ":%s SID %s 2 %s :%s%s",
if(IsMe(target_p) || target_p->from == client_p)
continue;
if(IsMe(target_p) || target_p->from == client_p)
continue;
+ /* don't distribute downstream leaves of servers that are no-export */
+ if(MyClient(target_p->from) && target_p->from->localClient->att_sconf != NULL && ServerConfNoExport(target_p->from->localClient->att_sconf))
+ continue;
+
/* presumption, if target has an id, so does its uplink */
if(has_id(client_p) && has_id(target_p))
sendto_one(client_p, ":%s SID %s %d %s :%s%s",
/* presumption, if target has an id, so does its uplink */
if(has_id(client_p) && has_id(target_p))
sendto_one(client_p, ":%s SID %s %d %s :%s%s",