From: Mike C. <mch...@ma...> - 2002-08-17 20:43:04
|
i am starting to implement role validation on the server. so when you try to do something like change the message of the day for the server, you can only do it if you are an admin. where do you think we should validate the user? For example, consider changing the room topic. this is done through: FCAChatRoom.setTopic(topic) This is exposed to the chat, through the /topic command defined in topic.asc. Should I validate the client has permission in setTopic or in the command file (topic.asc). The advantage of doing it in the command, is that it allows you to define commands that allow anyone to change the topic. however, in the case of setTopic, the function will allow you to set the topic if you are an admin or room administrator. if we validate in setTopic, then we have to pass the FCAClientWrapper for the client making the command: FACChatRoom.setTopic(topic, fClient) if we do it externally, then we have to make the room admins available outside of the room (which we will do anyways). FCAChatRoom.getRoomAdmins(); thoughts? mike chambers me...@ma... |