Merge lp://staging/~abentley/launchpad/build-security into lp://staging/launchpad

Proposed by Aaron Bentley
Status: Merged
Approved by: Tim Penhey
Approved revision: no longer in the source branch.
Merged at revision: not available
Proposed branch: lp://staging/~abentley/launchpad/build-security
Merge into: lp://staging/launchpad
Diff against target: 139 lines (+64/-9)
3 files modified
lib/canonical/launchpad/security.py (+32/-6)
lib/lp/code/tests/test_sourcepackagerecipebuild.py (+29/-1)
lib/lp/testing/factory.py (+3/-2)
To merge this branch: bzr merge lp://staging/~abentley/launchpad/build-security
Reviewer Review Type Date Requested Status
Tim Penhey (community) Approve
Review via email: mp+23741@code.staging.launchpad.net

Commit message

Provide launchpad.View for SourcePackageRecipeBuild.

Description of the change

= Summary =
Fix bug 552976, "SourcePackageRecipeBuild security needs work"

== Proposed fix ==
Define launchpad.View such that it is only provided when the user has
launchpad.View on the recipe and the archive.

== Pre-implementation notes ==
None

== Implementation details ==
Extracted DerivedAuthorization from ViewSourcePackageRecipe, and reused it
for ViewSourcePackageRecipeBuild.

== Tests ==
bin/test -t test_view_private test_sourcepackagerecipebuild

== Demo and Q/A ==
None

= Launchpad lint =

Checking for conflicts. and issues in doctests and templates.
Running jslint, xmllint, pyflakes, and pylint.
Using normal rules.

Linting changed files:
  lib/lp/code/tests/test_sourcepackagerecipebuild.py
  lib/canonical/launchpad/security.py
  lib/lp/testing/factory.py

== Pylint notices ==

lib/lp/code/tests/test_sourcepackagerecipebuild.py
    13: [F0401] Unable to import 'transaction'
    14: [F0401] Unable to import 'zope.component'
    16: [F0401] Unable to import 'canonical.testing.layers'
    18: [F0401] Unable to import 'canonical.launchpad.webapp.authorization'
    19: [F0401] Unable to import 'lp.buildmaster.interfaces.buildbase'
    20: [F0401] Unable to import 'lp.buildmaster.interfaces.buildqueue'
    21: [F0401] Unable to import 'lp.code.interfaces.sourcepackagerecipebuild'
    24: [F0401] Unable to import 'lp.testing'

To post a comment you must log in.
Revision history for this message
Tim Penhey (thumper) wrote :

Yay

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
The diff is not available at this time. You can reload the page or download it.