001 //$HeadURL: https://svn.wald.intevation.org/svn/deegree/base/branches/2.4_testing/src/org/deegree/security/drm/SecurityRegistry.java $ 002 /*---------------------------------------------------------------------------- 003 This file is part of deegree, http://deegree.org/ 004 Copyright (C) 2001-2009 by: 005 Department of Geography, University of Bonn 006 and 007 lat/lon GmbH 008 009 This library is free software; you can redistribute it and/or modify it under 010 the terms of the GNU Lesser General Public License as published by the Free 011 Software Foundation; either version 2.1 of the License, or (at your option) 012 any later version. 013 This library is distributed in the hope that it will be useful, but WITHOUT 014 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS 015 FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more 016 details. 017 You should have received a copy of the GNU Lesser General Public License 018 along with this library; if not, write to the Free Software Foundation, Inc., 019 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 020 021 Contact information: 022 023 lat/lon GmbH 024 Aennchenstr. 19, 53177 Bonn 025 Germany 026 http://lat-lon.de/ 027 028 Department of Geography, University of Bonn 029 Prof. Dr. Klaus Greve 030 Postfach 1147, 53001 Bonn 031 Germany 032 http://www.geographie.uni-bonn.de/deegree/ 033 034 e-mail: info@deegree.org 035 ----------------------------------------------------------------------------*/ 036 package org.deegree.security.drm; 037 038 import java.util.LinkedList; 039 import java.util.List; 040 import java.util.Properties; 041 042 import org.deegree.framework.util.StringPair; 043 import org.deegree.security.GeneralSecurityException; 044 import org.deegree.security.drm.model.Group; 045 import org.deegree.security.drm.model.Privilege; 046 import org.deegree.security.drm.model.Right; 047 import org.deegree.security.drm.model.RightType; 048 import org.deegree.security.drm.model.Role; 049 import org.deegree.security.drm.model.SecurableObject; 050 import org.deegree.security.drm.model.SecuredObject; 051 import org.deegree.security.drm.model.Service; 052 import org.deegree.security.drm.model.User; 053 054 /** 055 * This is an interface for datastores that are able to stores the following object types and their relations: 056 * <ul> 057 * <li><code>User</code> 058 * <li><code>Group</code> 059 * <li><code>Role</code> 060 * <li><code>SecurableObject</code> 061 * <li><code>Right / RightType</code> 062 * <li><code>Privilege</code> 063 * </ul> 064 * 065 * @author <a href="mailto:mschneider@lat-lon.de">Markus Schneider </a> 066 * @version $Revision: 18195 $ 067 */ 068 public interface SecurityRegistry { 069 070 /** 071 * Initializes the <code>Registry</code> -instance according to the contents of the submitted 072 * <code>Properties</code>. 073 * <p> 074 * The supported keys and values depend on the concrete implementation. 075 * 076 * @param properties 077 * @throws GeneralSecurityException 078 */ 079 void initialize( Properties properties ) 080 throws GeneralSecurityException; 081 082 /** 083 * Signals the <code>Registry</code> that a new transaction starts. 084 * <p> 085 * Only one transaction can be active at a time. 086 * 087 * @param transaction 088 * 089 * @throws GeneralSecurityException 090 */ 091 void beginTransaction( SecurityTransaction transaction ) 092 throws GeneralSecurityException; 093 094 /** 095 * Signals the <code>Registry</code> that the current transaction ends. Changes made during the transaction are now 096 * made persistent. 097 * 098 * @param transaction 099 * 100 * @throws GeneralSecurityException 101 */ 102 void commitTransaction( SecurityTransaction transaction ) 103 throws GeneralSecurityException; 104 105 /** 106 * Signals the <code>Registry</code> that the transaction shall be aborted. Changes made by the transaction are 107 * undone. 108 * 109 * @param transaction 110 * 111 * @throws GeneralSecurityException 112 */ 113 void abortTransaction( SecurityTransaction transaction ) 114 throws GeneralSecurityException; 115 116 /** 117 * Deletes all data from the <code>Registry</code> and sets the default objects (SEC_ADMIN user, role and group) and 118 * standard rights and privileges. 119 * 120 * @param transaction 121 * @throws GeneralSecurityException 122 */ 123 void clean( SecurityTransaction transaction ) 124 throws GeneralSecurityException; 125 126 /** 127 * Adds a new User-account to the <code>Registry</code>. 128 * 129 * @param transaction 130 * @param name 131 * @param password 132 * @param lastName 133 * @param firstName 134 * @param mailAddress 135 * @return the new user 136 * 137 * @throws GeneralSecurityException 138 * this is a <code>DuplicateException</code> if the group already existed 139 */ 140 User registerUser( SecurityTransaction transaction, String name, String password, String lastName, 141 String firstName, String mailAddress ) 142 throws GeneralSecurityException; 143 144 /** 145 * Removes an existing <code>User<code> from the <code>Registry</code>. 146 * 147 * @param transaction 148 * @param user 149 * 150 * @throws GeneralSecurityException 151 */ 152 void deregisterUser( SecurityTransaction transaction, User user ) 153 throws GeneralSecurityException; 154 155 /** 156 * Updates the metadata (name, email, etc.) of a <code>User</code> in the <code>Registry</code>. 157 * 158 * @param transaction 159 * @param user 160 * 161 * @throws GeneralSecurityException 162 * this is a <code>DuplicateException</code> if a user with the new name already existed 163 */ 164 void updateUser( SecurityTransaction transaction, User user ) 165 throws GeneralSecurityException; 166 167 /** 168 * Retrieves a <code>User</code> from the <code>Registry</code>. 169 * 170 * @param securityAccess 171 * @param name 172 * @return the user 173 * 174 * @throws GeneralSecurityException 175 * this is an <code>UnknownException</code> if the user is not known to the <code>Registry</code> 176 */ 177 User getUserByName( SecurityAccess securityAccess, String name ) 178 throws GeneralSecurityException; 179 180 /** 181 * Retrieves a <code>User</code> from the <code>Registry</code>. 182 * 183 * @param securityAccess 184 * @param id 185 * @return the user 186 * 187 * @throws GeneralSecurityException 188 * this is an <code>UnknownException</code> if the user is not known to the <code>Registry</code> 189 */ 190 User getUserById( SecurityAccess securityAccess, int id ) 191 throws GeneralSecurityException; 192 193 /** 194 * Retrieves all <code>User</code> s from the <code>Registry</code>. 195 * 196 * @param securityAccess 197 * @return the users 198 * 199 * @throws GeneralSecurityException 200 */ 201 User[] getAllUsers( SecurityAccess securityAccess ) 202 throws GeneralSecurityException; 203 204 /** 205 * Retrieves all <code>Users</code> s from the <code>Registry</code> that are associated DIRECTLY (SecurityAccess 206 * securityAccess, i.e. not via group memberships) with a given <code>Role</code>. 207 * 208 * @param securityAccess 209 * @param role 210 * @return the users 211 * 212 * @throws GeneralSecurityException 213 */ 214 User[] getUsersWithRole( SecurityAccess securityAccess, Role role ) 215 throws GeneralSecurityException; 216 217 /** 218 * Retrieves all <code>User</code> s from the <code>Registry</code> belong to the given <code>Group</code>. 219 * 220 * @param securityAccess 221 * @param group 222 * @return the users 223 * 224 * @throws GeneralSecurityException 225 */ 226 User[] getUsersInGroup( SecurityAccess securityAccess, Group group ) 227 throws GeneralSecurityException; 228 229 /** 230 * Sets the <code>User</code> s that are members of a given <code>Group</code>. 231 * 232 * @param transaction 233 * @param group 234 * @param users 235 * 236 * @throws GeneralSecurityException 237 */ 238 void setUsersInGroup( SecurityTransaction transaction, Group group, User[] users ) 239 throws GeneralSecurityException; 240 241 /** 242 * Sets the <code>User</code> s that a given <code>Role</code> is associated to. 243 * 244 * @param transaction 245 * @param role 246 * @param users 247 * 248 * @throws GeneralSecurityException 249 */ 250 void setUsersWithRole( SecurityTransaction transaction, Role role, User[] users ) 251 throws GeneralSecurityException; 252 253 /** 254 * Adds a new Group-account to the <code>Registry</code>. 255 * 256 * @param transaction 257 * @param name 258 * @param title 259 * @return the group 260 * 261 * @throws GeneralSecurityException 262 * this is a <code>DuplicateException</code> if the group already existed 263 */ 264 Group registerGroup( SecurityTransaction transaction, String name, String title ) 265 throws GeneralSecurityException; 266 267 /** 268 * Removes an existing <code>Group</code> from the <code>Registry</code> (including its relations). 269 * 270 * @param transaction 271 * @param group 272 * 273 * @throws GeneralSecurityException 274 */ 275 void deregisterGroup( SecurityTransaction transaction, Group group ) 276 throws GeneralSecurityException; 277 278 /** 279 * Retrieves a <code>Group</code> from the <code>Registry</code>. 280 * 281 * @param securityAccess 282 * @param name 283 * @return the group 284 * 285 * @throws GeneralSecurityException 286 * this is an <code>UnknownException</code> if the group is not known to the <code>Registry</code> 287 */ 288 Group getGroupByName( SecurityAccess securityAccess, String name ) 289 throws GeneralSecurityException; 290 291 /** 292 * Retrieves a <code>Group</code> from the <code>Registry</code>. 293 * 294 * @param securityAccess 295 * @param id 296 * @return the group 297 * 298 * @throws GeneralSecurityException 299 * this is an <code>UnknownException</code> if the group is not known to the <code>Registry</code> 300 */ 301 Group getGroupById( SecurityAccess securityAccess, int id ) 302 throws GeneralSecurityException; 303 304 /** 305 * Retrieves all <code>Group</code> s from the <code>Registry</code>. 306 * 307 * @param securityAccess 308 * @return the groups 309 * 310 * @throws GeneralSecurityException 311 */ 312 Group[] getAllGroups( SecurityAccess securityAccess ) 313 throws GeneralSecurityException; 314 315 /** 316 * Retrieves all <code>Group</code> s from the <code>Registry</code> that the given <code>User</code> belongs to. 317 * 318 * @param securityAccess 319 * @param user 320 * @return the groups 321 * 322 * @throws GeneralSecurityException 323 */ 324 Group[] getGroupsForUser( SecurityAccess securityAccess, User user ) 325 throws GeneralSecurityException; 326 327 /** 328 * Retrieves all <code>Group</code> s from the <code>Registry</code> that the given <code>Group</code> belongs to. 329 * 330 * @param securityAccess 331 * @param group 332 * @return the groups 333 * 334 * @throws GeneralSecurityException 335 */ 336 Group[] getGroupsForGroup( SecurityAccess securityAccess, Group group ) 337 throws GeneralSecurityException; 338 339 /** 340 * Retrieves all <code>Group</code> s from the <code>Registry</code> belong to the given <code>Group</code>. 341 * 342 * @param securityAccess 343 * @param group 344 * @return the groups 345 * 346 * @throws GeneralSecurityException 347 */ 348 Group[] getGroupsInGroup( SecurityAccess securityAccess, Group group ) 349 throws GeneralSecurityException; 350 351 /** 352 * Retrieves all <code>Group</code> s from the <code>Registry</code> that are associated with a given 353 * <code>Role</code>. 354 * 355 * @param securityAccess 356 * @param role 357 * @return the groups 358 * 359 * @throws GeneralSecurityException 360 */ 361 Group[] getGroupsWithRole( SecurityAccess securityAccess, Role role ) 362 throws GeneralSecurityException; 363 364 /** 365 * Sets the <code>Group</code> s that a given <code>User</code> is a DIRECT member of. 366 * 367 * @param transaction 368 * @param user 369 * @param groups 370 * 371 * @throws GeneralSecurityException 372 */ 373 void setGroupsForUser( SecurityTransaction transaction, User user, Group[] groups ) 374 throws GeneralSecurityException; 375 376 /** 377 * Sets the <code>Groups</code> s that are members of a given <code>Group</code>. 378 * 379 * @param transaction 380 * @param group 381 * @param groups 382 * 383 * @throws GeneralSecurityException 384 */ 385 void setGroupsInGroup( SecurityTransaction transaction, Group group, Group[] groups ) 386 throws GeneralSecurityException; 387 388 /** 389 * Sets the <code>Group</code> s that a given <code>Role</code> is associated to. 390 * 391 * @param transaction 392 * @param role 393 * @param groups 394 * 395 * @throws GeneralSecurityException 396 */ 397 void setGroupsWithRole( SecurityTransaction transaction, Role role, Group[] groups ) 398 throws GeneralSecurityException; 399 400 /** 401 * Sets the <code>Groups</code> s that a given <code>Group</code> is member of DIRECTLY (i.e. not via group 402 * membership). 403 * 404 * @param transaction 405 * @param group 406 * @param groups 407 * 408 * @throws GeneralSecurityException 409 */ 410 void setGroupsForGroup( SecurityTransaction transaction, Group group, Group[] groups ) 411 throws GeneralSecurityException; 412 413 /** 414 * Adds a new role to the <code>Registry</code>. 415 * 416 * @param transaction 417 * @param name 418 * @return the role 419 * 420 * @throws GeneralSecurityException 421 * this is a <code>DuplicateException</code> if the role already existed 422 */ 423 Role registerRole( SecurityTransaction transaction, String name ) 424 throws GeneralSecurityException; 425 426 /** 427 * Removes an existing <code>Role</code> from the <code>Registry</code> (including its relations). 428 * 429 * @param transaction 430 * @param role 431 * 432 * @throws GeneralSecurityException 433 */ 434 void deregisterRole( SecurityTransaction transaction, Role role ) 435 throws GeneralSecurityException; 436 437 /** 438 * Retrieves a <code>Role</code> from the <code>Registry</code>. 439 * 440 * @param securityAccess 441 * @param name 442 * @return the role 443 * 444 * @throws GeneralSecurityException 445 * this is an <code>UnknownException</code> if the role is not known to the <code>Registry</code> 446 */ 447 Role getRoleByName( SecurityAccess securityAccess, String name ) 448 throws GeneralSecurityException; 449 450 /** 451 * Retrieves all <code>Role</code> s from the <code>Registry</code> that have a certain namespace. 452 * 453 * @param securityAccess 454 * @param ns 455 * @return the roles 456 * 457 * @throws GeneralSecurityException 458 */ 459 Role[] getRolesByNS( SecurityAccess securityAccess, String ns ) 460 throws GeneralSecurityException; 461 462 /** 463 * Retrieves a <code>Role</code> from the <code>Registry</code>. 464 * 465 * @param securityAccess 466 * @param id 467 * @return the role 468 * 469 * @throws GeneralSecurityException 470 * this is an <code>UnknownException</code> if the role is not known to the <code>Registry</code> 471 */ 472 Role getRoleById( SecurityAccess securityAccess, int id ) 473 throws GeneralSecurityException; 474 475 /** 476 * Retrieves all <code>Role</code> s from the <code>Registry</code>, except those that are only used internally 477 * (these end with a $ symbol); 478 * 479 * @param securityAccess 480 * @return the roles 481 * 482 * @throws GeneralSecurityException 483 */ 484 Role[] getAllRoles( SecurityAccess securityAccess ) 485 throws GeneralSecurityException; 486 487 /** 488 * Retrieves all <code>Role</code> s from the <code>Registry</code> that are associated with a given 489 * <code>User</code> DIRECTLY (i.e. not via group memberships). 490 * 491 * @param securityAccess 492 * @param user 493 * @return the roles 494 * 495 * @throws GeneralSecurityException 496 */ 497 Role[] getRolesForUser( SecurityAccess securityAccess, User user ) 498 throws GeneralSecurityException; 499 500 /** 501 * Retrieves all <code>Role</code> s from the <code>Registry</code> that are associated with a given 502 * <code>Group</code> DIRECTLY (i.e. not via group memberships). 503 * 504 * @param securityAccess 505 * @param group 506 * @return the roles 507 * 508 * @throws GeneralSecurityException 509 */ 510 Role[] getRolesForGroup( SecurityAccess securityAccess, Group group ) 511 throws GeneralSecurityException; 512 513 /** 514 * Sets the <code>Role</code> s that a given <code>User</code> is directly associated to. 515 * 516 * @param transaction 517 * @param user 518 * @param roles 519 * 520 * @throws GeneralSecurityException 521 */ 522 void setRolesForUser( SecurityTransaction transaction, User user, Role[] roles ) 523 throws GeneralSecurityException; 524 525 /** 526 * Sets the <code>Role</code> s that a given <code>Group</code> is associated to. 527 * 528 * @param transaction 529 * @param group 530 * @param roles 531 * 532 * @throws GeneralSecurityException 533 */ 534 void setRolesForGroup( SecurityTransaction transaction, Group group, Role[] roles ) 535 throws GeneralSecurityException; 536 537 /** 538 * Adds a new <code>SecuredObject</code> to the <code>Registry</code>. 539 * 540 * @param transaction 541 * @param type 542 * @param name 543 * @param title 544 * @return the new object 545 * 546 * @throws GeneralSecurityException 547 * this is a <code>DuplicateException</code> if the object already existed 548 */ 549 SecuredObject registerSecuredObject( SecurityTransaction transaction, String type, String name, String title ) 550 throws GeneralSecurityException; 551 552 /** 553 * Removes an existing <code>SecuredObject</code> from the <code>Registry</code> (including its associated rights). 554 * 555 * @param transaction 556 * @param object 557 * 558 * @throws GeneralSecurityException 559 */ 560 void deregisterSecuredObject( SecurityTransaction transaction, SecuredObject object ) 561 throws GeneralSecurityException; 562 563 /** 564 * Retrieves a <code>SecuredObject</code> from the <code>Registry</code>. 565 * 566 * @param securityAccess 567 * @param name 568 * @param type 569 * @return the object 570 * 571 * @throws GeneralSecurityException 572 * this is an <code>UnknownException</code> if the <code>SecuredObject</code> is not known to the 573 * <code>Registry</code> 574 */ 575 SecuredObject getSecuredObjectByName( SecurityAccess securityAccess, String name, String type ) 576 throws GeneralSecurityException; 577 578 /** 579 * Retrieves all <code>SecuredObject</code> s from the <code>Registry</code> that have a certain namespace. 580 * 581 * @param securityAccess 582 * @param ns 583 * @param type 584 * @return the objects 585 * 586 * @throws GeneralSecurityException 587 */ 588 SecuredObject[] getSecuredObjectsByNS( SecurityAccess securityAccess, String ns, String type ) 589 throws GeneralSecurityException; 590 591 /** 592 * Retrieves a <code>SecuredObject</code> from the <code>Registry</code>. 593 * 594 * @param securityAccess 595 * @param id 596 * @return the object 597 * 598 * @throws GeneralSecurityException 599 * this is an <code>UnknownException</code> if the <code>SecuredObject</code> is not known to the 600 * <code>Registry</code> 601 */ 602 SecuredObject getSecuredObjectById( SecurityAccess securityAccess, int id ) 603 throws GeneralSecurityException; 604 605 /** 606 * Retrieves all <code>SecuredObject</code> s from the <code>Registry</code>. 607 * 608 * @param securityAccess 609 * @param type 610 * @return the objects 611 * 612 * @throws GeneralSecurityException 613 */ 614 SecuredObject[] getAllSecuredObjects( SecurityAccess securityAccess, String type ) 615 throws GeneralSecurityException; 616 617 /** 618 * Adds a new <code>Privilege</code> to the <code>Registry</code>. 619 * 620 * @param transaction 621 * @param name 622 * @return the privilege 623 * 624 * @throws GeneralSecurityException 625 * this is a <code>DuplicateException</code> if the <code>Privilege</code> already existed 626 */ 627 Privilege registerPrivilege( SecurityTransaction transaction, String name ) 628 throws GeneralSecurityException; 629 630 /** 631 * Removes an existing</code> Privilege</code> from the <code>Registry </code> (including its relations). 632 * 633 * @param transaction 634 * @param privilege 635 * 636 * @throws GeneralSecurityException 637 */ 638 void deregisterPrivilege( SecurityTransaction transaction, Privilege privilege ) 639 throws GeneralSecurityException; 640 641 /** 642 * Retrieves a <code>Privilege</code> from the <code>Registry</code>. 643 * 644 * @param securityAccess 645 * @param name 646 * @return the privilege 647 * 648 * @throws GeneralSecurityException 649 * this is an <code>UnknownException</code> if the privilege is not known to the <code>Registry</code> 650 */ 651 Privilege getPrivilegeByName( SecurityAccess securityAccess, String name ) 652 throws GeneralSecurityException; 653 654 /** 655 * Retrieves all <code>Privileges</code> s from the <code>Registry</code> that are associated with a given 656 * <code>Role</code>. 657 * 658 * @param securityAccess 659 * @param role 660 * @return the privileges 661 * 662 * @throws GeneralSecurityException 663 */ 664 Privilege[] getPrivilegesForRole( SecurityAccess securityAccess, Role role ) 665 throws GeneralSecurityException; 666 667 /** 668 * Sets all <code>Privilege</code> s that are associated with a given <code>Role</code>. 669 * 670 * @param transaction 671 * @param role 672 * @param privileges 673 * 674 * @throws GeneralSecurityException 675 */ 676 void setPrivilegesForRole( SecurityTransaction transaction, Role role, Privilege[] privileges ) 677 throws GeneralSecurityException; 678 679 /** 680 * Adds a new <code>RightType</code> to the <code>Registry</code>. 681 * 682 * @param transaction 683 * @param name 684 * @return the right type 685 * 686 * @throws GeneralSecurityException 687 * this is a <code>DuplicateException</code> if the <code>RightType</code> already existed 688 */ 689 RightType registerRightType( SecurityTransaction transaction, String name ) 690 throws GeneralSecurityException; 691 692 /** 693 * Removes an existing <code>RightType</code> from the <code>Registry</code> (including its relations). 694 * 695 * @param transaction 696 * @param type 697 * 698 * @throws GeneralSecurityException 699 */ 700 void deregisterRightType( SecurityTransaction transaction, RightType type ) 701 throws GeneralSecurityException; 702 703 /** 704 * Retrieves a <code>RightType</code> from the <code>Registry</code>. 705 * 706 * @param securityAccess 707 * @param name 708 * @return the right type 709 * 710 * @throws GeneralSecurityException 711 * this is an <code>UnknownException</code> if the <code>RightType</code> is not known to the 712 * <code>Registry</code> 713 */ 714 RightType getRightTypeByName( SecurityAccess securityAccess, String name ) 715 throws GeneralSecurityException; 716 717 /** 718 * Retrieves the <code>Rights</code> from the <code>Registry</code> that are associated with a given 719 * <code>Role</code> and a <code>SecurableObject</code>. 720 * 721 * @param securityAccess 722 * @param object 723 * @param role 724 * @return the rights 725 * 726 * @throws GeneralSecurityException 727 */ 728 Right[] getRights( SecurityAccess securityAccess, SecurableObject object, Role role ) 729 throws GeneralSecurityException; 730 731 /** 732 * Sets the <code>Rights</code> to be associated with a given <code>Role</code> and <code>SecurableObject</code>. 733 * 734 * @param transaction 735 * @param object 736 * @param role 737 * @param rights 738 * 739 * @throws GeneralSecurityException 740 */ 741 void setRights( SecurityTransaction transaction, SecurableObject object, Role role, Right[] rights ) 742 throws GeneralSecurityException; 743 744 /** 745 * Sets one <code>Right</code> to be associated with a given <code>Role</code> and all given 746 * <code>SecurableObjects</code>. 747 * 748 * @param transaction 749 * @param objects 750 * @param role 751 * @param right 752 * 753 * @throws GeneralSecurityException 754 */ 755 void setRights( SecurityTransaction transaction, SecurableObject[] objects, Role role, Right right ) 756 throws GeneralSecurityException; 757 758 /** 759 * @param access 760 * @param address 761 * @return the service 762 * @throws GeneralSecurityException 763 */ 764 Service getServiceByAddress( SecurityAccess access, String address ) 765 throws GeneralSecurityException; 766 767 /** 768 * @param transaction 769 * @param address 770 * @param title 771 * @param objects 772 * @param type 773 * @return the new service 774 * @throws GeneralSecurityException 775 */ 776 Service registerService( SecurityTransaction transaction, String address, String title, List<StringPair> objects, 777 String type ) 778 throws GeneralSecurityException; 779 780 /** 781 * @param transaction 782 * @param service 783 * @throws GeneralSecurityException 784 */ 785 void deregisterService( SecurityTransaction transaction, Service service ) 786 throws GeneralSecurityException; 787 788 /** 789 * @param access 790 * @return all services 791 * @throws GeneralSecurityException 792 */ 793 LinkedList<Service> getAllServices( SecurityAccess access ) 794 throws GeneralSecurityException; 795 796 /** 797 * @param securityTransaction 798 * @param oldService 799 * @param newService 800 * @throws GeneralSecurityException 801 */ 802 void updateService( SecurityTransaction securityTransaction, Service oldService, Service newService ) 803 throws GeneralSecurityException; 804 805 /** 806 * @param securityTransaction 807 * @param service 808 * @param oldName 809 * @param newName 810 * @throws GeneralSecurityException 811 */ 812 void renameObject( SecurityTransaction securityTransaction, Service service, String oldName, String newName ) 813 throws GeneralSecurityException; 814 815 /** 816 * @param securityTransaction 817 * @param service 818 * @param newTitle 819 * @param newAddress 820 * @throws GeneralSecurityException 821 */ 822 void editService( SecurityTransaction securityTransaction, Service service, String newTitle, String newAddress ) 823 throws GeneralSecurityException; 824 825 }