aboutsummaryrefslogtreecommitdiffstats
path: root/include/dir_fns.php
diff options
context:
space:
mode:
authorfriendica <info@friendica.com>2013-10-24 19:38:50 -0700
committerfriendica <info@friendica.com>2013-10-24 19:38:50 -0700
commit0b0bd3c20765d267ec6d7cc261c7713917a22582 (patch)
tree84c997aa781afa566536ca5f66eb8f90ef468476 /include/dir_fns.php
parent3da20b3797b6d29d78197c16f4daac8fed6db895 (diff)
downloadvolse-hubzilla-0b0bd3c20765d267ec6d7cc261c7713917a22582.tar.gz
volse-hubzilla-0b0bd3c20765d267ec6d7cc261c7713917a22582.tar.bz2
volse-hubzilla-0b0bd3c20765d267ec6d7cc261c7713917a22582.zip
create update record for accounts on directory server itself during profile changes, re-queue failed directory sync packets, fix account_id index in queue creation, be more selective about updating hubloc_connected (only when we're talking to the associated site). But we still need a way to flag dead accounts and these mechanisms won't cut it, because it isn't a requirement that channels communicate with anybody, except for contacting the directory when the account is created. I think we need to make every channel ping the directory once a month. Then we can find those that have not done so (after syncing with other directories). We can't have the directory just flag dead accounts as this would create a way for an anti-social attacker to become a directory server and mark all the accounts dead.
Diffstat (limited to 'include/dir_fns.php')
-rw-r--r--include/dir_fns.php7
1 files changed, 5 insertions, 2 deletions
diff --git a/include/dir_fns.php b/include/dir_fns.php
index adbcb6e3c..e234ae0fa 100644
--- a/include/dir_fns.php
+++ b/include/dir_fns.php
@@ -118,6 +118,7 @@ function update_directory_entry($ud) {
);
}
}
+
}
@@ -128,7 +129,7 @@ function syncdirs($uid) {
logger('syncdirs', LOGGER_DEBUG);
- $p = q("select channel.channel_hash, channel_timezone, profile.* from profile left join channel on channel_id = uid where uid = %d and is_default = 1",
+ $p = q("select channel.channel_hash, channel_address, channel_timezone, profile.* from profile left join channel on channel_id = uid where uid = %d and is_default = 1",
intval($uid)
);
@@ -199,6 +200,8 @@ function syncdirs($uid) {
}
}
- // TODO send refresh zots to downstream directory servers
+ $ud_hash = random_string();
+ update_modtime($ud_hash,$hash,$p[0]['channel_address'] . '@' . get_app()->get_hostname(),1);
+
}