Skip to content

ACL module supports UUIDs as ObjectIdentity, documentation update needed #7978

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
jonathan-graf opened this issue Feb 12, 2020 · 1 comment
Labels
in: acl An issue in spring-security-acl

Comments

@jonathan-graf
Copy link

jonathan-graf commented Feb 12, 2020

Summary

Since issue #6141 has been merged, the ACL module supports non-Long ObjectIdentity. @jzheaux has mentioned creating specific issues for documentation updates. I love Spring Security and have been a follower since the beta days of Acegi in 2006. I'm very proud to be a user and would greatly appreciate being able to contribute to the longevity of this wonderful project.

Actual Behavior

In the documentation, Section 11.6.3 Getting Started states:

Many parts of the ACL module rely on long identifiers. If you’re not using long (or an int, byte etc), there is a very good chance you’ll need to reimplement a number of classes. We do not intend to support non-long identifiers in Spring Security’s ACL module, as longs are already compatible with all database sequences, the most common identifier data type, and are of sufficient length to accommodate all common usage scenarios.

This statement is false. The ACL module fully supports UUID and String.

Expected Behavior

This statement should be removed. Updated schema DDL and instructions for using non-Long identifiers should be included.

Configuration

DDL updates

CREATE TABLE IF NOT EXISTS acl_class (
  id BIGINT NOT NULL AUTO_INCREMENT,
  class varchar(255) NOT NULL,
  class_id_type varchar(255),
  PRIMARY KEY (id),
  UNIQUE KEY unique_uk_2 (class)
);
 
CREATE TABLE IF NOT EXISTS acl_object_identity (
  id BIGINT NOT NULL AUTO_INCREMENT,
  object_id_class BIGINT NOT NULL,
  object_id_identity varchar(255) NOT NULL,
  parent_object BIGINT DEFAULT NULL,
  owner_sid BIGINT DEFAULT NULL,
  entries_inheriting tinyint(1) NOT NULL,
  PRIMARY KEY (id),
  UNIQUE KEY unique_uk_3 (object_id_class,object_id_identity)
);

Settings in ACL configuration

jdbcMutableAclService.setAclClassIdSupported(true);
lookupStrategy.setAclClassIdSupported(true);

Version

5.2.2

@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged label Feb 12, 2020
@jzheaux jzheaux added in: acl An issue in spring-security-acl and removed status: waiting-for-triage An issue we've not yet triaged labels Feb 14, 2020
@jzheaux
Copy link
Contributor

jzheaux commented Feb 14, 2020

@jonathan-graf Thanks for the suggestion. And, I like Spring Security, too. :) We certainly welcome your contributions.

Before we update the docs, let's see if we can come to a consensus on #7598 and #7621. Resolving those may change what we place in the docs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in: acl An issue in spring-security-acl
Projects
None yet
Development

No branches or pull requests

3 participants