Skip to content
Closed

dummy #881

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions .github/workflows/pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,7 @@ jobs:
maven-version: ${{ env.MAVEN_VERSION }}
project-name: com.sap.cds.feature.attachments
included-modules: cds-feature-attachments,cds-feature-attachments-oss,cds-feature-attachments-fs
scan_mode: RAPID
rapid_compare_mode: BOM_COMPARE # PRs might only be blocked by things they introduce, not by pre-existing issues that could have appeared in the main branch in the meantime
scan_mode: FULL

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Best Practices: Switching from RAPID to FULL scan mode on every PR will significantly increase CI runtime and may block PRs for pre-existing issues that were already present on the main branch.

The removed rapid_compare_mode: BOM_COMPARE setting was deliberately chosen so that PRs are only blocked by vulnerabilities they actually introduce, not by pre-existing issues that could have appeared on main in the meantime. With FULL scan mode and no compare mode, every PR will fail if main itself has any open Black Duck findings — even ones the PR author has no control over. This can make it unnecessarily hard to merge otherwise-clean PRs and will increase scan time.

Consider reverting to RAPID + BOM_COMPARE, or if a FULL scan is intentionally required, at least document the rationale and be aware of the impact on PR velocity.


Please provide feedback on the review comment by checking the appropriate box:

  • 🌟 Awesome comment, a human might have missed that.
  • ✅ Helpful comment
  • 🤷 Neutral
  • ❌ This comment is not helpful


build-and-test:
uses: ./.github/workflows/pipeline.yml
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ The UI Facet can also be added directly after other UI Facets in a `cds` file in
### Single (Inline) Attachments

> [!Important]
> Inline attachments require **cds-services 4.9.0** or higher and are available from **cds-feature-attachments 1.6.0**.
> Inline attachments are available from **cds-feature-attachments 1.7.0**.

In addition to the composition-based `Attachments` aspect (which supports multiple files), `cds-feature-attachments` provides the `Attachment` type for **single-file** attachment fields directly on an entity. This is useful when an entity needs exactly one file, for example a profile icon or a cover image.

Expand Down
8 changes: 6 additions & 2 deletions doc/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,15 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/).
## Unreleased

### Added
### Changed

## Version 1.7.0 - 2026-08-19

- Added support for single (inline) attachments via the `Attachment` type. Requires cds-services 4.9.0 or higher. (#768)
### Added

- Added support for single (inline) attachments via the `Attachment` type. (#768)
- Added top-level `Attachments` aspect to allow usage without `sap.attachments` namespace (#806), i.e., `using {Attachments} from 'com.sap.cds/cds-feature-attachments'`.

### Changed
### Security

- Attachment content is now served with `Content-Disposition: attachment` by default (previously `inline`) to mitigate stored XSS (CWE-79) via user-uploaded SVG/HTML payloads (cds-calesi #1263). Applications that require inline previews can opt in by annotating `content` in their own CDS model — see the "Content Disposition" section in the README. It is recommended to combine this with `@Core.AcceptableMediaTypes` restricting inline content to non-scriptable types (e.g. `image/jpeg`, `image/png`, `application/pdf`).
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@
</distributionManagement>

<properties>
<revision>1.6.0</revision>
<revision>1.7.0</revision>
<java.version>21</java.version>
<maven.compiler.release>${java.version}</maven.compiler.release>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
Expand Down
2 changes: 1 addition & 1 deletion samples/bookshop/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
<dependency>
<groupId>com.sap.cds</groupId>
<artifactId>cds-feature-attachments</artifactId>
<version>1.6.0</version>
<version>1.7.0</version>
</dependency>
</dependencies>
</dependencyManagement>
Expand Down
Loading