Skip to content
Open
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
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
Comment thread
lisajulia marked this conversation as resolved.

## 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