awslabs / threat-composer

A simple threat modeling tool to help humans to reduce time-to-value when threat modeling
https://awslabs.github.io/threat-composer/
Apache License 2.0
409 stars 40 forks source link

[BUG] Architecture images that are too large cannot be imported #100

Closed cogwirrel closed 3 months ago

cogwirrel commented 3 months ago

Describe the bug

Architecture images from threat models generated by PDK's cdk graph plugin are often too large to import and fail.

Expected Behavior

Images to import successfully

Current Behavior

Screenshot 2024-03-14 at 9 23 51 am

Reproduction Steps

Possible Solution

Either increase the size limit, or add support for svg images which will generally be smaller.

Additional Information/Context

No response

jessieweiyi commented 3 months ago

Hi @cogwirrel, thanks for reporting the bug.

Currently, the base 64 image field is limited to 1,000,000 characters. Since we are using local storage, we are cautious about the data size.

We do support usage of svg. However, there is a bug when validating the image field for image/svg+xml format. We will release a bug fix soon.

cogwirrel commented 3 months ago

Awesome, thank you! 😄

github-actions[bot] commented 3 months ago

:tada: This issue has been resolved in version 1.0.41 :tada:

The release is available on GitHub release

Your semantic-release bot :package::rocket: