Example #1
0
if ($_SERVER['HTTP_X_SECONDLIFE_OWNER_NAME'] == $ownername || $_REQUEST['psk'] == $authuser) {
    $authorized = true;
}
$command = $_REQUEST['command'];
if ($command == "profilepic") {
    if (!$authorized) {
        genPipeError('auth');
    }
    if (!isset($_REQUEST['key'])) {
        genPipeError('param');
    }
    $key = avatarProfilePic($_REQUEST['key']);
    if ($key == null) {
        genPipeError('lookup');
    } else {
        genPipeResponse(friendlyUUID($key));
    }
} else {
    if ($command == "grouplist") {
        if (!$authorized) {
            genPipeError('auth');
        }
        if (!isset($_REQUEST['key'])) {
            genPipeError('param');
        }
        $list = avatarGroupList($_REQUEST['key']);
        genPipeResponse($list);
    } else {
        genPipeError('param');
    }
}
Example #2
0
if ($_SERVER['HTTP_X_SECONDLIFE_OWNER_NAME'] == $ownername || $_REQUEST['psk'] == $authuser) {
    $authorized = true;
}
$command = $_REQUEST['command'];
if ($command == "groupinfo") {
    if (!$authorized) {
        genPipeError('auth');
    }
    if (!isset($_REQUEST['group_key'])) {
        genPipeError('param');
    }
    $result = groupInfo($_REQUEST['group_key']);
    if ($result == null) {
        genPipeError('unknown');
    } else {
        genPipeResponse($result);
    }
    /*} else if ( $command == "getgroups" ) {
    	if ( !$authorized ) {
    		genPipeError('auth');
    	}
    	if ( ! isset($_REQUEST['av_key']) ) {
    		genPipeError('param');
    	}
    	$result = groupList($_REQUEST['av_key']);
    	if ( $result == null ) {
    		genPipeError('unknown');
    	} else {
    		genPipeResponse($result);
    	}*/
} else {