Skip to content

Commit 6017142

Browse files
committed
Fix Up Dependencies
1 parent 3e9637d commit 6017142

File tree

3 files changed

+15
-6
lines changed

3 files changed

+15
-6
lines changed

.github/workflows/php.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ jobs:
9898
uses: shivammathur/setup-php@v2
9999
with:
100100
php-version: ${{ matrix.php }}
101-
extensions: dom, gd, mbstring, xml, zip
101+
extensions: ctype, dom, fileinfo, filter, gd, libxml, mbstring, SimpleXML, xml, xmlwriter, xsl, zip, zlib
102102
coverage: ${{ (matrix.php == '8.3') && 'xdebug' || 'none' }}
103103

104104
- uses: actions/checkout@v2

composer.json

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -115,10 +115,15 @@
115115
"ext-xml": "*",
116116
"ext-zip": "*",
117117
"phpoffice/math": "^0.3",
118-
"symfony/polyfill-php72": "^1.30"
118+
"symfony/polyfill-php72": "^1.30",
119+
"ext-zlib": "*",
120+
"ext-filter": "*",
121+
"ext-ctype": "*",
122+
"ext-fileinfo": "*",
123+
"ext-SimpleXML": "*",
124+
"ext-libxml": "*"
119125
},
120126
"require-dev": {
121-
"ext-libxml": "*",
122127
"dompdf/dompdf": "^2.0 || ^3.0",
123128
"friendsofphp/php-cs-fixer": "^3.3",
124129
"mpdf/mpdf": "^7.0 || ^8.0",
@@ -127,12 +132,16 @@
127132
"phpstan/phpstan-phpunit": "^1.0 || ^2.0",
128133
"phpunit/phpunit": "^7.0 || ^8.0 || ^9.0 || ^10.0",
129134
"symfony/process": "^4.4 || ^5.0 || ^6.0 || ^7.0 || 7.4.x-dev",
130-
"tecnickcom/tcpdf": "^6.5"
135+
"tecnickcom/tcpdf": "^6.5",
136+
"ext-xmlwriter": "*",
137+
"ext-xsl": "*"
131138
},
132139
"suggest": {
133140
"ext-xmlwriter": "Allows writing OOXML and ODF",
134141
"ext-xsl": "Allows applying XSL style sheet to headers, to main document part, and to footers of an OOXML template",
135-
"dompdf/dompdf": "Allows writing PDF"
142+
"dompdf/dompdf": "Allows writing PDF",
143+
"mpdf/mpdf": "Allows writing PDF",
144+
"tecnickcom/tcpdf": "Allows writing PDF"
136145
},
137146
"autoload": {
138147
"psr-4": {

src/PhpWord/Writer/Word2007/Part/Settings.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -197,7 +197,7 @@ private function setDocumentProtection($documentProtection): void
197197
];
198198
} else {
199199
if ($documentProtection->getSalt() == null) {
200-
$documentProtection->setSalt((string) openssl_random_pseudo_bytes(16));
200+
$documentProtection->setSalt(random_bytes(16));
201201
}
202202
$passwordHash = PasswordEncoder::hashPassword($documentProtection->getPassword(), $documentProtection->getAlgorithm(), $documentProtection->getSalt(), $documentProtection->getSpinCount());
203203
$this->settings['w:documentProtection'] = [

0 commit comments

Comments
 (0)