GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — [apex] added rule to detect inaccessible AuraEnabled getters by pozil · Pull Request #3322 · pmd/pmd

Conversation

@pozil

@pozil pozil commented Jun 1, 2021

Copy link
Copy Markdown
Contributor

Describe the PR

In the Summer '21 release, a mandatory security update enforces access modifiers on Apex properties in Lightning component markup. The update prevents access to private or protected Apex getters from Aura and Lightning Web Components.
This rule detects and reports such getters.

Related issues

  • Fixes [apex] New rule to detect inaccessible AuraEnabled getters (summer '21 security update) #3321

Ready?

  • Added unit tests for fixed bug/feature
  • Passing all unit tests
  • Complete build ./mvnw clean verify passes (checked automatically by github actions)
  • Added (in-code) documentation (if needed)

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@pozil
Feat: added rule to detect inaccessible AuraEnabled getters
b957352
@oowekyala oowekyala changed the title Feat: added Apex rule to detect inaccessible AuraEnabled getters [apex] added rule to detect inaccessible AuraEnabled getters Jun 1, 2021
@oowekyala oowekyala added the a:new-rule Proposal to add a new built-in rule label Jun 1, 2021
@rsoesemann
rsoesemann self-requested a review June 2, 2021 07:16
rsoesemann
rsoesemann approved these changes Jun 2, 2021
View reviewed changes

@rsoesemann rsoesemann left a comment

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great @pozil. Thanks for the great and timely rule addition.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

pozil reacted with hooray emoji
All reactions
  • 🎉 1 reaction
@rsoesemann

rsoesemann commented Jun 2, 2021

Copy link
Copy Markdown
Member

@oowekyala maybe you can have a short look too. I know you added some AST node changes that also applied to Apex in the last months.

And @adangel is 6.36 right as the release mentioned in the tests? Will this rule make it into the next one?

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@rsoesemann rsoesemann added this to the 6.36.0 milestone Jun 2, 2021
oowekyala
oowekyala reviewed Jun 2, 2021
View reviewed changes

@oowekyala oowekyala left a comment

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi, thanks for your contribution! It's nice, but your formatter settings don't match ours. Please use a 4 space indentation instead of tabs (also in the XML file).

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

rsoesemann reacted with eyes emoji
All reactions
  • 👀 1 reaction
Comment thread pmd-apex/src/main/resources/category/apex/errorprone.xml Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread pmd-apex/src/main/resources/category/apex/errorprone.xml Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread pmd-apex/src/main/resources/category/apex/errorprone.xml Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread pmd-apex/src/main/resources/category/apex/errorprone.xml Resolved

Uh oh!

There was an error while loading. Please reload this page.

pozil added 2 commits June 2, 2021 20:51
@pozil
Applied proper code formatting
f70fd18
@pozil
Reformatted examples and added comments
634cf32
@pozil

pozil commented Jun 2, 2021

Copy link
Copy Markdown
Contributor Author

Thanks for the review @oowekyala. I've applied your recommendations. We should be good to go.

rsoesemann reacted with rocket emoji
All reactions
  • 🚀 1 reaction

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@ghost

ghost commented Jun 3, 2021

Copy link
Copy Markdown
1 Message
📖 No java rules are changed!

Generated by 🚫 Danger

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@rsoesemann
rsoesemann merged commit 33aee7b into pmd:master Jun 8, 2021
oowekyala added a commit that referenced this pull request Jun 8, 2021
@oowekyala
Update release notes, refs #3322, #3321
d0d6929
CC @rsoesemann please do this when merging :)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@oowekyala oowekyala oowekyala left review comments
@rsoesemann rsoesemann rsoesemann approved these changes

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

a:new-rule Proposal to add a new built-in rule

Projects

None yet

Milestone

6.36.0

Development

Successfully merging this pull request may close these issues.

[apex] New rule to detect inaccessible AuraEnabled getters (summer '21 security update)

Uh oh!

There was an error while loading. Please reload this page.

3 participants

@pozil @rsoesemann @oowekyala
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.