mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
AAE-22443 disable insecure eval support for pdf viewer (#9780)
This commit is contained in:
@@ -181,7 +181,8 @@ export class PdfViewerComponent implements OnChanges, OnDestroy {
|
|||||||
const pdfOptions = {
|
const pdfOptions = {
|
||||||
...this.pdfjsDefaultOptions,
|
...this.pdfjsDefaultOptions,
|
||||||
data: reader.result,
|
data: reader.result,
|
||||||
withCredentials: this.appConfigService.get<boolean>('auth.withCredentials', undefined)
|
withCredentials: this.appConfigService.get<boolean>('auth.withCredentials', undefined),
|
||||||
|
isEvalSupported: false
|
||||||
};
|
};
|
||||||
this.executePdf(pdfOptions);
|
this.executePdf(pdfOptions);
|
||||||
};
|
};
|
||||||
@@ -193,7 +194,8 @@ export class PdfViewerComponent implements OnChanges, OnDestroy {
|
|||||||
const pdfOptions: any = {
|
const pdfOptions: any = {
|
||||||
...this.pdfjsDefaultOptions,
|
...this.pdfjsDefaultOptions,
|
||||||
url: urlFile.currentValue,
|
url: urlFile.currentValue,
|
||||||
withCredentials: this.appConfigService.get<boolean>('auth.withCredentials', undefined)
|
withCredentials: this.appConfigService.get<boolean>('auth.withCredentials', undefined),
|
||||||
|
isEvalSupported: false
|
||||||
};
|
};
|
||||||
if (this.cacheType) {
|
if (this.cacheType) {
|
||||||
pdfOptions.httpHeaders = {
|
pdfOptions.httpHeaders = {
|
||||||
|
Reference in New Issue
Block a user