1 10 package org.mmbase.security; 11 12 import java.util.*; 13 14 20 final public class NoAuthorization extends Authorization { 21 22 private static final String EVERYBODY = "everybody"; 24 private static final Set possibleContexts = Collections.unmodifiableSet(new HashSet(Arrays.asList( new String []{EVERYBODY, NoAuthentication.userContext.getOwnerField()}))); 25 26 29 protected void load() { 30 } 31 32 35 public void create(UserContext user, int nodeid) { 36 } 37 38 41 public void update(UserContext user, int nodeid) { 42 } 43 44 47 public void remove(UserContext user, int nodeid) { 48 } 49 50 54 public boolean check(UserContext user, int nodeid, Operation operation) { 55 return true; 56 } 57 58 61 public void verify(UserContext user, int nodeid, Operation operation) throws org.mmbase.security.SecurityException { 62 } 63 64 68 public boolean check(UserContext user, int nodeid, int srcNodeid, int dstNodeid, Operation operation) { 69 return true; 70 } 71 72 75 public void verify(UserContext user, int nodeid, int srcNodeid, int dstNodeid, Operation operation) throws SecurityException { 76 } 77 78 79 82 public String getContext(UserContext user, int nodeid) throws SecurityException { 83 return EVERYBODY; 84 } 85 86 89 public void setContext(UserContext user, int nodeid, String context) throws SecurityException { 90 } 92 93 96 public Set getPossibleContexts(UserContext user, int nodeid) throws SecurityException { 97 return possibleContexts; 98 } 99 100 public QueryCheck check(UserContext user, org.mmbase.bridge.Query query, Operation operation) { 101 return COMPLETE_CHECK; 102 } 103 104 } 105 | Popular Tags |