Revision 6518
Added by ben leinfelder over 12 years ago
D1NodeService.java | ||
---|---|---|
149 | 149 |
boolean allowed = false; |
150 | 150 |
|
151 | 151 |
// be sure the user is authenticated for create() |
152 |
if (subject.getValue() == null || |
|
153 |
subject.getValue().toLowerCase().equals("public") ) {
|
|
152 |
if (subject == null || subject.getValue() == null ||
|
|
153 |
subject.getValue().toLowerCase().equals(Constants.PUBLIC_SUBJECT) ) {
|
|
154 | 154 |
throw new NotAuthorized("1100", "The provided identity does not have " + |
155 |
"permission to WRITE to the Member Node.");
|
|
155 |
"permission to WRITE to the Node."); |
|
156 | 156 |
|
157 | 157 |
} |
158 | 158 |
|
... | ... | |
176 | 176 |
" is already used by another object and" + |
177 | 177 |
"therefore can not be used for this object. Clients should choose" + |
178 | 178 |
"a new identifier that is unique and retry the operation or " + |
179 |
"use CN_crud.reserveIdentifier() to reserve one.");
|
|
179 |
"use CN.reserveIdentifier() to reserve one."); |
|
180 | 180 |
|
181 | 181 |
} |
182 |
|
|
182 |
|
|
183 | 183 |
// check for permission |
184 | 184 |
try { |
185 | 185 |
allowed = isAuthorized(session, pid, Permission.WRITE); |
Also available in: Unified diff
set sysmeta submitter based on the subject given in the certificate