8ca @verb #12:"add_connect_place" this none this rxd #55 @program #12:"add_connect_place" this none this !caller_perms().wizard && raise(E_PERM) {where} = args dynamic = 0 if (is_ip = $network:is_ip(where)) where = $string_utils:from_list($list_utils:reverse($string_utils:explode(where, ".")), ".") endif "Assume the IP is not dynamic unless otherwise implied to be." if (match((where_exp = $string_utils:explode(where, "."))[1], "[0-9][0-9]+")) "It has numbers in the first bit? Well that's an obvious tipoff of a dynamic IP" dynamic = 1 endif site = "" for chunk in ($list_utils:reverse(where_exp)) site = tostr(chunk, site && ".", site) if (site in $network.static_domains) dynamic = 0 break "No matter what." endif endfor "Ok, phase one is complete. We have determined whether the address is dynamic or not (Albeit in a simple sort of way)" "Phase two, the construction of a new entry to merge the data of all addresses similar to this one (If there are any)." done = 0 gathered = deletes = {} for i in [1..length(places = this:all_connect_places())] if ((places_exp = $string_utils:explode(places[i], "."))[2..$] == where_exp[2..$]) if (places_exp[1][1] == "[" && places_exp[1][$] == "]") "This has already been tagged as dynamic." gathered = {@$string_utils:explode(places_exp[1][2..$ - 1], "|"), @gathered} deletes = {@deletes, i} else gathered = {places_exp[1], @gathered} deletes = {i, @deletes} endif endif endfor for del in (deletes) places = listdelete(places, del) endfor gathered = setremove($list_utils:remove_duplicates(gathered), where_exp[1]) if (dynamic || length(where_exp[1]) > 160) where_exp[1] = "*" elseif (gathered) where_exp[1] = tostr("[", $string_utils:from_list({@gathered, where_exp[1]}, "|"), "]") endif is_ip && (where_exp = $list_utils:reverse(where_exp)) where = $string_utils:from_list(where_exp, ".") this:filewrite("all_connect_places", {@places, where}) this:filesetaccess("all_connect_places", "") "This verb previously owned by Raptor (#6319), and chowned to $slacker upon dewizarding (Sat Aug 17 14:48:42 2002 MDT)." "Last modified by Dax (#789) on Sat Aug 17 14:48:42 2002 MDT." . 0