Security
Headlines
HeadlinesLatestCVEs

Headline

CVE-2021-24963: Changeset 2634373 – WordPress Plugin Repository

The LiteSpeed Cache WordPress plugin before 4.4.4 does not escape the qc_res parameter before outputting it back in the JS code of an admin page, leading to a Reflected Cross-Site Scripting

CVE
#sql#web#apache#redis#memcached#js#java
  • litespeed-cache/trunk/lang/litespeed-cache.pot

    r2613854

    r2634373

3

3

msgid ""

4

4

msgstr ""

5

 

"Project-Id-Version: LiteSpeed Cache 4.4.3\\n"

 

5

"Project-Id-Version: LiteSpeed Cache 4.4.4\\n"

6

6

"Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/litespeed-cache\\n"

7

 

"POT-Creation-Date: 2021-10-11 17:31:14+00:00\\n"

 

7

"POT-Creation-Date: 2021-11-19 21:27:41+00:00\\n"

8

8

"MIME-Version: 1.0\\n"

9

9

"Content-Type: text/plain; charset=UTF-8\\n"

…

…

 

54

54

msgstr ""

55

55

56

 

#: src/admin-display.cls.php:123 src/gui.cls.php:593

 

56

#: src/admin-display.cls.php:123 src/gui.cls.php:602

57

57

#: tpl/dash/dashboard.tpl.php:55 tpl/dash/network\_dash.tpl.php:27

58

58

msgid "Image Optimization"

…

…

 

103

103

msgstr ""

104

104

105

 

#: src/admin-display.cls.php:232 src/admin-display.cls.php:826

106

 

#: src/admin-display.cls.php:855 src/admin-display.cls.php:906

 

105

#: src/admin-display.cls.php:232 src/admin-display.cls.php:832

 

106

#: src/admin-display.cls.php:861 src/admin-display.cls.php:912

107

107

#: tpl/cache/settings-cache.tpl.php:19

108

108

#: tpl/cache/settings\_inc.cache\_mobile.tpl.php:71 tpl/cdn/settings.tpl.php:49

…

…

 

114

114

msgstr ""

115

115

116

 

#: src/admin-display.cls.php:233 src/admin-display.cls.php:827

117

 

#: src/admin-display.cls.php:854 src/admin-display.cls.php:906

 

116

#: src/admin-display.cls.php:233 src/admin-display.cls.php:833

 

117

#: src/admin-display.cls.php:860 src/admin-display.cls.php:912

118

118

#: tpl/cache/settings-cache.tpl.php:19

119

119

#: tpl/cache/settings\_inc.object.tpl.php:210 tpl/cdn/settings.tpl.php:54

…

…

 

124

124

msgstr ""

125

125

126

 

#: src/admin-display.cls.php:281 src/gui.cls.php:584

 

126

#: src/admin-display.cls.php:281 src/gui.cls.php:593

127

127

msgid "Settings"

128

128

msgstr ""

129

129

130

 

#: src/admin-display.cls.php:450

 

130

#: src/admin-display.cls.php:455

131

131

msgid "Dismiss"

132

132

msgstr ""

133

133

134

 

#: src/admin-display.cls.php:695 src/admin-display.cls.php:700

 

134

#: src/admin-display.cls.php:701 src/admin-display.cls.php:706

135

135

msgid "Save Changes"

136

136

msgstr ""

137

137

138

 

#: src/admin-display.cls.php:918

 

138

#: src/admin-display.cls.php:924

139

139

msgid "This setting is overwritten by the PHP constant %s"

140

140

msgstr ""

141

141

142

 

#: src/admin-display.cls.php:921

 

142

#: src/admin-display.cls.php:927

143

143

msgid "This setting is overwritten by the primary site setting"

144

144

msgstr ""

145

145

146

 

#: src/admin-display.cls.php:924

 

146

#: src/admin-display.cls.php:930

147

147

msgid "This setting is overwritten by the Network setting"

148

148

msgstr ""

149

149

150

 

#: src/admin-display.cls.php:928

 

150

#: src/admin-display.cls.php:934

151

151

msgid "currently set to %s"

152

152

msgstr ""

153

153

154

 

#: src/admin-display.cls.php:938 tpl/cache/settings\_inc.object.tpl.php:103

 

154

#: src/admin-display.cls.php:944 tpl/cache/settings\_inc.object.tpl.php:103

155

155

#: tpl/crawler/settings-general.tpl.php:60

156

156

#: tpl/crawler/settings-general.tpl.php:74

…

…

 

159

159

msgstr ""

160

160

161

 

#: src/admin-display.cls.php:969 src/admin-display.cls.php:974

 

161

#: src/admin-display.cls.php:975 src/admin-display.cls.php:980

162

162

#: tpl/cdn/settings.tpl.php:99

163

163

msgid "Default value"

164

164

msgstr ""

165

165

166

 

#: src/admin-display.cls.php:998

 

166

#: src/admin-display.cls.php:1004

167

167

msgid "Invalid rewrite rule"

168

168

msgstr ""

169

169

170

 

#: src/admin-display.cls.php:1015

 

170

#: src/admin-display.cls.php:1021

171

171

msgid "Path must end with %s"

172

172

msgstr ""

173

173

174

 

#: src/admin-display.cls.php:1033

 

174

#: src/admin-display.cls.php:1039

175

175

msgid "Minimum value"

176

176

msgstr ""

177

177

178

 

#: src/admin-display.cls.php:1036

 

178

#: src/admin-display.cls.php:1042

179

179

msgid "Maximum value"

180

180

msgstr ""

181

181

182

 

#: src/admin-display.cls.php:1048

 

182

#: src/admin-display.cls.php:1054

183

183

msgid "Zero, or"

184

184

msgstr ""

185

185

186

 

#: src/admin-display.cls.php:1055

 

186

#: src/admin-display.cls.php:1061

187

187

msgid "Larger than"

188

188

msgstr ""

189

189

190

 

#: src/admin-display.cls.php:1058

 

190

#: src/admin-display.cls.php:1064

191

191

msgid "Smaller than"

192

192

msgstr ""

193

193

194

 

#: src/admin-display.cls.php:1061

 

194

#: src/admin-display.cls.php:1067

195

195

msgid "Value range"

196

196

msgstr ""

197

197

198

 

#: src/admin-display.cls.php:1086

 

198

#: src/admin-display.cls.php:1092

199

199

msgid "Invalid IP"

200

200

msgstr ""

201

201

202

 

#: src/admin-display.cls.php:1106 tpl/cache/settings-esi.tpl.php:95

 

202

#: src/admin-display.cls.php:1112 tpl/cache/settings-esi.tpl.php:95

203

203

#: tpl/page\_optm/settings\_css.tpl.php:175

204

204

#: tpl/page\_optm/settings\_html.tpl.php:85

…

…

 

213

213

msgstr ""

214

214

215

 

#: src/admin-display.cls.php:1107

 

215

#: src/admin-display.cls.php:1113

216

216

msgid "Server variable(s) %s available to override this setting."

217

217

msgstr ""

218

218

219

 

#: src/admin-display.cls.php:1119

 

219

#: src/admin-display.cls.php:1125

220

220

msgid "The URLs will be compared to the REQUEST\_URI server variable."

221

221

msgstr ""

222

222

223

 

#: src/admin-display.cls.php:1120

 

223

#: src/admin-display.cls.php:1126

224

224

msgid "For example, for %s, %s can be used here."

225

225

msgstr ""

226

226

227

 

#: src/admin-display.cls.php:1122

 

227

#: src/admin-display.cls.php:1128

228

228

msgid "To match the beginning, add %s to the beginning of the item."

229

229

msgstr ""

230

230

231

 

#: src/admin-display.cls.php:1123

 

231

#: src/admin-display.cls.php:1129

232

232

msgid "To do an exact match, add %s to the end of the URL."

233

233

msgstr ""

234

234

235

 

#: src/admin-display.cls.php:1124 src/doc.cls.php:74

 

235

#: src/admin-display.cls.php:1130 src/doc.cls.php:74

236

236

msgid "One per line."

237

237

msgstr ""

238

238

239

 

#: src/admin-display.cls.php:1138

 

239

#: src/admin-display.cls.php:1144

240

240

msgid "%s groups"

241

241

msgstr ""

242

242

243

 

#: src/admin-display.cls.php:1141

 

243

#: src/admin-display.cls.php:1147

244

244

msgid "%s images"

245

245

msgstr ""

246

246

247

 

#: src/admin-display.cls.php:1151

 

247

#: src/admin-display.cls.php:1157

248

248

msgid "%s group"

249

249

msgstr ""

250

250

251

 

#: src/admin-display.cls.php:1154

 

251

#: src/admin-display.cls.php:1160

252

252

msgid "%s image"

253

253

msgstr ""

…

…

 

358

358

msgstr ""

359

359

360

 

#: src/conf.cls.php:701

 

360

#: src/conf.cls.php:704

361

361

msgid "Changed setting successfully."

362

362

msgstr ""

363

363

364

 

#: src/core.cls.php:283

 

364

#: src/core.cls.php:289

365

365

msgid "Notified LiteSpeed Web Server to purge everything."

366

366

msgstr ""

367

367

368

 

#: src/core.cls.php:288

 

368

#: src/core.cls.php:294

369

369

msgid "Notified LiteSpeed Web Server to purge the list."

370

370

msgstr ""

…

…

 

410

410

msgstr ""

411

411

412

 

#: src/data.cls.php:213

 

412

#: src/data.cls.php:219

413

413

msgid ""

414

414

"The database has been upgrading in the background since %s. This message "

…

…

 

416

416

msgstr ""

417

417

418

 

#: src/data.upgrade.func.php:83

 

418

#: src/data.upgrade.func.php:101

419

419

msgid ""

420

420

"LiteSpeed Cache upgraded successfully. NOTE: Due to changes in this version, "

…

…

 

424

424

msgstr ""

425

425

426

 

#: src/data.upgrade.func.php:83 src/lang.cls.php:115

 

426

#: src/data.upgrade.func.php:101 src/lang.cls.php:115

427

427

msgid "JS Combine"

428

428

msgstr ""

429

429

430

 

#: src/data.upgrade.func.php:83

 

430

#: src/data.upgrade.func.php:101

431

431

msgid "JS Defer"

432

432

msgstr ""

433

433

434

 

#: src/data.upgrade.func.php:84

 

434

#: src/data.upgrade.func.php:102

435

435

msgid "Click here to settings"

436

436

msgstr ""

…

…

 

704

704

msgstr ""

705

705

706

 

#: src/gui.cls.php:393

 

706

#: src/gui.cls.php:402

707

707

msgid "Purge this page"

708

708

msgstr ""

709

709

710

 

#: src/gui.cls.php:401

 

710

#: src/gui.cls.php:410

711

711

msgid "Mark this page as "

712

712

msgstr ""

713

713

714

 

#: src/gui.cls.php:413

 

714

#: src/gui.cls.php:422

715

715

msgid "Forced cacheable"

716

716

msgstr ""

717

717

718

 

#: src/gui.cls.php:424

 

718

#: src/gui.cls.php:433

719

719

msgid "Non cacheable"

720

720

msgstr ""

721

721

722

 

#: src/gui.cls.php:435

 

722

#: src/gui.cls.php:444

723

723

msgid "Private cache"

724

724

msgstr ""

725

725

726

 

#: src/gui.cls.php:446

 

726

#: src/gui.cls.php:455

727

727

msgid "No optimization"

728

728

msgstr ""

729

729

730

 

#: src/gui.cls.php:454

 

730

#: src/gui.cls.php:463

731

731

msgid "More settings"

732

732

msgstr ""

733

733

734

 

#: src/gui.cls.php:461 src/gui.cls.php:469 src/gui.cls.php:477

735

 

#: src/gui.cls.php:486 src/gui.cls.php:496 src/gui.cls.php:506

736

 

#: src/gui.cls.php:516 src/gui.cls.php:526 src/gui.cls.php:536

737

 

#: src/gui.cls.php:602 src/gui.cls.php:610 src/gui.cls.php:618

738

 

#: src/gui.cls.php:627 src/gui.cls.php:637 src/gui.cls.php:647

739

 

#: src/gui.cls.php:657 src/gui.cls.php:667 src/gui.cls.php:677

740

 

#: src/gui.cls.php:687 tpl/page\_optm/settings\_media.tpl.php:125

 

734

#: src/gui.cls.php:470 src/gui.cls.php:478 src/gui.cls.php:486

 

735

#: src/gui.cls.php:495 src/gui.cls.php:505 src/gui.cls.php:515

 

736

#: src/gui.cls.php:525 src/gui.cls.php:535 src/gui.cls.php:545

 

737

#: src/gui.cls.php:611 src/gui.cls.php:619 src/gui.cls.php:627

 

738

#: src/gui.cls.php:636 src/gui.cls.php:646 src/gui.cls.php:656

 

739

#: src/gui.cls.php:666 src/gui.cls.php:676 src/gui.cls.php:686

 

740

#: src/gui.cls.php:696 tpl/page\_optm/settings\_media.tpl.php:125

741

741

#: tpl/toolbox/purge.tpl.php:37 tpl/toolbox/purge.tpl.php:43

742

742

#: tpl/toolbox/purge.tpl.php:52 tpl/toolbox/purge.tpl.php:61

…

…

 

747

747

msgstr ""

748

748

749

 

#: src/gui.cls.php:469 src/gui.cls.php:560 src/gui.cls.php:610

 

749

#: src/gui.cls.php:478 src/gui.cls.php:569 src/gui.cls.php:619

750

750

msgid "LSCache"

751

751

msgstr ""

752

752

753

 

#: src/gui.cls.php:477 src/gui.cls.php:618 tpl/toolbox/purge.tpl.php:43

 

753

#: src/gui.cls.php:486 src/gui.cls.php:627 tpl/toolbox/purge.tpl.php:43

754

754

msgid "CSS/JS Cache"

755

755

msgstr ""

756

756

757

 

#: src/gui.cls.php:486 src/gui.cls.php:637 src/lang.cls.php:82

 

757

#: src/gui.cls.php:495 src/gui.cls.php:646 src/lang.cls.php:82

758

758

#: tpl/dash/dashboard.tpl.php:396 tpl/toolbox/purge.tpl.php:52

759

759

msgid "Object Cache"

760

760

msgstr ""

761

761

762

 

#: src/gui.cls.php:496 src/gui.cls.php:647 tpl/toolbox/purge.tpl.php:61

 

762

#: src/gui.cls.php:505 src/gui.cls.php:656 tpl/toolbox/purge.tpl.php:61

763

763

msgid "Opcode Cache"

764

764

msgstr ""

765

765

766

 

#: src/gui.cls.php:526 src/gui.cls.php:677

 

766

#: src/gui.cls.php:535 src/gui.cls.php:686

767

767

#: tpl/page\_optm/settings\_media.tpl.php:125 tpl/toolbox/purge.tpl.php:88

768

768

msgid "LQIP Cache"

769

769

msgstr ""

770

770

771

 

#: src/gui.cls.php:536 src/gui.cls.php:687 src/lang.cls.php:142

 

771

#: src/gui.cls.php:545 src/gui.cls.php:696 src/lang.cls.php:142

772

772

#: tpl/toolbox/purge.tpl.php:97

773

773

msgid "Gravatar Cache"

774

774

msgstr ""

775

775

776

 

#: src/gui.cls.php:560

 

776

#: src/gui.cls.php:569

777

777

msgid "LiteSpeed Cache Purge All"

778

778

msgstr ""

779

779

780

 

#: src/gui.cls.php:576 tpl/cdn/entry.tpl.php:7 tpl/cdn/settings.tpl.php:194

 

780

#: src/gui.cls.php:585 tpl/cdn/entry.tpl.php:7 tpl/cdn/settings.tpl.php:194

781

781

#: tpl/db\_optm/entry.tpl.php:6

782

782

msgid "Manage"

783

783

msgstr ""

784

784

785

 

#: src/gui.cls.php:627 tpl/cdn/manage.tpl.php:17

 

785

#: src/gui.cls.php:636 tpl/cdn/manage.tpl.php:17

786

786

msgid "Cloudflare"

787

787

msgstr ""

788

788

789

 

#: src/gui.cls.php:706 tpl/img\_optm/summary.tpl.php:175

 

789

#: src/gui.cls.php:715 tpl/img\_optm/summary.tpl.php:175

790

790

msgid "Remove all previous unfinished image optimization requests."

791

791

msgstr ""

792

792

793

 

#: src/gui.cls.php:707 tpl/img\_optm/summary.tpl.php:177

 

793

#: src/gui.cls.php:716 tpl/img\_optm/summary.tpl.php:177

794

794

msgid "Clean Up Unfinished Data"

795

795

msgstr ""

796

796

797

 

#: src/gui.cls.php:725

 

797

#: src/gui.cls.php:734

798

798

msgid "Install %s"

799

799

msgstr ""

800

800

801

 

#: src/gui.cls.php:726

 

801

#: src/gui.cls.php:735

802

802

msgid "Install Now"

803

803

msgstr ""

804

804

805

 

#: src/gui.cls.php:745

 

805

#: src/gui.cls.php:754

806

806

msgid ""

807

807

"<a href=\\"%1$s\\" %2$s>View version %3$s details</a> or <a href=\\"%4$s\\" %5$s "

…

…

 

809

809

msgstr ""

810

810

811

 

#: src/gui.cls.php:748

 

811

#: src/gui.cls.php:757

812

812

msgid "View %1$s version %2$s details"

813

813

msgstr ""

814

814

815

 

#: src/gui.cls.php:753

 

815

#: src/gui.cls.php:762

816

816

msgid "Update %s now"

817

817

msgstr ""

…

…

 

821

821

msgstr ""

822

822

823

 

#: src/htaccess.cls.php:785

 

823

#: src/htaccess.cls.php:787

824

824

msgid ""

825

825

"<p>Please add/replace the following codes into the beginning of %1$s:</p> "

…

…

 

1773

1773

msgstr ""

1774

1774

1775

 

#: src/purge.cls.php:305

 

1775

#: src/purge.cls.php:309

1776

1776

msgid "Notified LiteSpeed Web Server to purge CSS/JS entries."

1777

1777

msgstr ""

1778

1778

1779

 

#: src/purge.cls.php:321

 

1779

#: src/purge.cls.php:325

1780

1780

msgid "Opcode cache is not enabled."

1781

1781

msgstr ""

1782

1782

1783

 

#: src/purge.cls.php:333

 

1783

#: src/purge.cls.php:337

1784

1784

msgid "Reset the entire opcode cache successfully."

1785

1785

msgstr ""

1786

1786

1787

 

#: src/purge.cls.php:361

 

1787

#: src/purge.cls.php:365

1788

1788

msgid "Object cache is not enabled."

1789

1789

msgstr ""

1790

1790

1791

 

#: src/purge.cls.php:374

 

1791

#: src/purge.cls.php:378

1792

1792

msgid "Purge all object caches successfully."

1793

1793

msgstr ""

1794

1794

1795

 

#: src/purge.cls.php:567

 

1795

#: src/purge.cls.php:571

1796

1796

msgid "Notified LiteSpeed Web Server to purge the front page."

1797

1797

msgstr ""

1798

1798

1799

 

#: src/purge.cls.php:580

 

1799

#: src/purge.cls.php:584

1800

1800

msgid "Notified LiteSpeed Web Server to purge all pages."

1801

1801

msgstr ""

1802

1802

1803

 

#: src/purge.cls.php:599

 

1803

#: src/purge.cls.php:603

1804

1804

msgid "Notified LiteSpeed Web Server to purge error pages."

1805

1805

msgstr ""

1806

1806

1807

 

#: src/purge.cls.php:626

 

1807

#: src/purge.cls.php:630

1808

1808

msgid "Purge category %s"

1809

1809

msgstr ""

1810

1810

1811

 

#: src/purge.cls.php:653

 

1811

#: src/purge.cls.php:657

1812

1812

msgid "Purge tag %s"

1813

1813

msgstr ""

1814

1814

1815

 

#: src/purge.cls.php:684

 

1815

#: src/purge.cls.php:688

1816

1816

msgid "Purge url %s"

1817

1817

msgstr ""

…

…

 

1961

1961

msgstr ""

1962

1962

1963

 

#. #-#-#-#-#  litespeed-cache.pot (LiteSpeed Cache 4.4.3)  #-#-#-#-#

 

1963

#. #-#-#-#-#  litespeed-cache.pot (LiteSpeed Cache 4.4.4)  #-#-#-#-#

1964

1964

#. Plugin Name of the plugin/theme

1965

1965

#: tpl/banner/new\_version.php:59 tpl/banner/new\_version\_dev.tpl.php:12

…

…

 

3271

3271

msgstr ""

3272

3272

3273

 

#: tpl/crawler/summary.tpl.php:106 tpl/dash/dashboard.tpl.php:563

 

3273

#: tpl/crawler/summary.tpl.php:106

3274

3274

msgid "<b>Last crawled:</b> %s item(s)"

3275

3275

msgstr ""

…

…

 

3514

3514

#: tpl/dash/dashboard.tpl.php:537

3515

3515

msgid "Currently active crawler"

 

3516

msgstr ""

 

3517

 

3518

#: tpl/dash/dashboard.tpl.php:563

 

3519

msgid "<b>Last crawled:</b> %d item(s)"

3516

3520

msgstr ""

3517

3521
  • litespeed-cache/trunk/litespeed-cache.php

    r2613854

    r2634373

4

4

 \* Plugin URI:        https://www.litespeedtech.com/products/cache-plugins/wordpress-acceleration

5

5

 \* Description:       High-performance page caching and site optimization from LiteSpeed

6

 

 \* Version:           4.4.3

 

6

 \* Version:           4.4.4

7

7

 \* Author:            LiteSpeed Technologies

8

8

 \* Author URI:        https://www.litespeedtech.com

…

…

 

34

34

}

35

35

36

 

! defined( 'LSCWP\_V' ) && define( 'LSCWP\_V', '4.4.3' );

 

36

! defined( 'LSCWP\_V' ) && define( 'LSCWP\_V', '4.4.4' );

37

37

38

38

! defined( 'LSCWP\_CONTENT\_DIR' ) && define( 'LSCWP\_CONTENT\_DIR', WP\_CONTENT\_DIR ) ;
  • litespeed-cache/trunk/readme.txt

    r2613854

    r2634373

3

3

Tags: caching, optimize, performance, pagespeed, core web vitals, seo, speed, image optimize, compress, object cache, redis, memcached, database cleaner

4

4

Requires at least: 4.0

5

 

Tested up to: 5.8.1

6

 

Stable tag: 4.4.3

 

5

Tested up to: 5.8.2

 

6

Stable tag: 4.4.4

7

7

License: GPLv3

8

8

License URI: http://www.gnu.org/licenses/gpl.html

…

…

 

249

249

250

250

\== Changelog ==

 

251

 

252

\= 4.4.4 - Nov 23 2021 =

 

253

\* \*\*Page Optimize\*\* Delay deletion of outdated CSS/JS files for a default of 20 days to avoid 404 errors with cached search engine copies.

 

254

\* \*\*Cache\*\* When caching, no longer send a purge request for CSS/JS removal to avoid cache engine conflicts.

 

255

\* 🐞\*\*Core\*\* Optimized SQL queries while autoloading if expected options are missing; reduced by 7 and 3 queries on backend and frontend respectively. (#396425 Jackson)

 

256

\* \*\*Page Optm\*\* Fixed a 404 issue that occured when upgrading the plugin manually, with a package upload or through the plugin manager. (Tobolo/Małgorzata/Abe)

 

257

\* \*\*API\*\* Added \`litespeed\_ccss\_url\` and \`litespeed\_ucss\_url\` API to manipulate the request URL for CCSS and UCSS.

 

258

\* \*\*REST\*\* Fixed a potential warning when detecting cacheable status on REST call. (rafaucau)

 

259

\* \*\*OLS\*\* Fixed an issue where the \`COOKIEHASH\` constant was undefined when used with OpenLiteSpeed as an MU plugin or with network activation.

 

260

\* \*\*3rd\*\* Sanitized POST data for nextgengallery.

 

261

\* \*\*Cloud\*\* Sanitized GET data when linking to QUIC.cloud. (#591762 WPScan)

251

262

252

263

\= 4.4.3 - Oct 13 2021 =
  • litespeed-cache/trunk/src/admin-display.cls.php

    r2595736

    r2634373

386

386

        $msg\_name = $irremovable ? self::DB\_MSG\_PIN : self::DB\_MSG;

387

387

388

 

        $messages = self::get\_option( $msg\_name, array() );

 

388

        $messages = self::get\_option( $msg\_name );

 

389

        if ( ! is\_array( $messages ) ) {

 

390

            $messages = array();

 

391

        }

389

392

390

393

        if ( is\_array($msg) ) {

…

…

 

421

424

422

425

        // One time msg

423

 

        $messages = self::get\_option( self::DB\_MSG, array() );

 

426

        $messages = self::get\_option( self::DB\_MSG );

424

427

        $added\_thickbox = false;

425

428

        if( is\_array( $messages ) ) {

…

…

 

433

436

            }

434

437

        }

435

 

        self::delete\_option( self::DB\_MSG );

 

438

        if ( $messages != -1 ) {

 

439

            self::update\_option( self::DB\_MSG, -1 );

 

440

        }

436

441

437

442

        // Pinned msg

438

 

        $messages = self::get\_option( self::DB\_MSG\_PIN, array() );

 

443

        $messages = self::get\_option( self::DB\_MSG\_PIN );

439

444

        if( is\_array( $messages ) ) {

440

445

            foreach ( $messages as $k => $msg ) {

…

…

 

453

458

            }

454

459

        }

 

460

        if ( $messages != -1 ) {

 

461

            self::update\_option( self::DB\_MSG\_PIN, -1 );

 

462

        }

455

463

456

464

        if( empty( $\_GET\[ 'page' \] ) || strpos( $\_GET\[ 'page' \], 'litespeed' ) !== 0 ) {

…

…

 

494

502

        }

495

503

496

 

        $messages = self::get\_option( self::DB\_MSG\_PIN, array() );

497

 

        if ( empty( $messages\[ $\_GET\[ 'msgid' \] \] ) ) {

 

504

        $messages = self::get\_option( self::DB\_MSG\_PIN );

 

505

        if ( ! is\_array( $messages ) || empty( $messages\[ $\_GET\[ 'msgid' \] \] ) ) {

498

506

            return;

499

507

        }

…

…

 

501

509

        unset( $messages\[ $\_GET\[ 'msgid' \] \] );

502

510

        if ( ! $messages ) {

503

 

            self::delete\_option( self::DB\_MSG\_PIN );

504

 

        }

505

 

        else {

506

 

            self::update\_option( self::DB\_MSG\_PIN, $messages );

507

 

        }

 

511

            $messages = -1;

 

512

        }

 

513

        self::update\_option( self::DB\_MSG\_PIN, $messages );

508

514

    }

509

515
  • litespeed-cache/trunk/src/cloud.cls.php

    r2613854

    r2634373

1079

1079

1080

1080

        // Drop QS

1081

 

        echo "<script>window.history.pushState( 'remove\_gen\_link', document.title, window.location.href.replace( '&qc\_res=" . $\_GET\[ 'qc\_res' \] . "&domain\_hash=" . $\_GET\[ 'domain\_hash' \] . "', '' ) );</script>";

 

1081

        echo "<script>window.history.pushState( 'remove\_gen\_link', document.title, window.location.href.replace( '&qc\_res=" . sanitize\_key( $\_GET\[ 'qc\_res' \] ) . "&domain\_hash=" . sanitize\_key( $\_GET\[ 'domain\_hash' \] ) . "', '' ) );</script>";

1082

1082

    }

1083

1083
  • litespeed-cache/trunk/src/conf.cls.php

    r2595736

    r2634373

69

69

        $has\_delay\_conf\_tag = self::get\_option( '\_\_activation' );

70

70

        if ( ! $ver || $ver != Core::VER ) {

71

 

            if ( ( ! is\_admin() && ! defined( 'LITESPEED\_CLI' ) ) || ! $has\_delay\_conf\_tag ) { // Reuse \_\_activation to control the delay conf update

72

 

                $has\_delay\_conf\_tag || self::update\_option( '\_\_activation', Core::VER );

 

71

            if ( ( ! is\_admin() && ! defined( 'LITESPEED\_CLI' ) ) || ( ! $has\_delay\_conf\_tag || $has\_delay\_conf\_tag == -1 ) ) { // Reuse \_\_activation to control the delay conf update

 

72

                if ( ! $has\_delay\_conf\_tag || $has\_delay\_conf\_tag == -1 ) {

 

73

                    self::update\_option( '\_\_activation', Core::VER );

 

74

                }

73

75

74

76

                $this->set\_conf( $this->load\_default\_vals() );

…

…

 

136

138

         \* Cons: Conf upgrade won't get file correction if there is new values that are used in file

137

139

         \*/

138

 

        if ( $has\_delay\_conf\_tag ) {

 

140

        if ( $has\_delay\_conf\_tag && $has\_delay\_conf\_tag != -1 ) {

139

141

            // Check new version @since 2.9.3

140

142

            Cloud::version\_check( 'activate' . ( defined( 'LSCWP\_REF' ) ? '\_' . LSCWP\_REF : '' ) );

141

143

142

144

            $this->update\_confs(); // Files only get corrected in activation or saving settings actions.

143

 

144

 

            self::delete\_option( '\_\_activation' );

 

145

        }

 

146

        if ( $has\_delay\_conf\_tag != -1 ) {

 

147

            self::update\_option( '\_\_activation', -1 );

145

148

        }

146

149

    }
  • litespeed-cache/trunk/src/core.cls.php

    r2613854

    r2634373

80

80

81

81

        // Check if there is a purge request in queue

82

 

        if ( $purge\_queue = Purge::get\_option( Purge::DB\_QUEUE ) ) {

 

82

        $purge\_queue = Purge::get\_option( Purge::DB\_QUEUE );

 

83

        if ( $purge\_queue && $purge\_queue != -1 ) {

83

84

            @header( $purge\_queue );

84

85

            Debug2::debug( '\[Core\] Purge Queue found&sent: ' . $purge\_queue );

85

 

            Purge::delete\_option( Purge::DB\_QUEUE );

86

 

        }

87

 

        if ( $purge\_queue = Purge::get\_option( Purge::DB\_QUEUE2 ) ) {

 

86

        }

 

87

        if ( $purge\_queue != -1 ) {

 

88

            Purge::update\_option( Purge::DB\_QUEUE, -1 ); // Use 0 to bypass purge while still enable db update as WP's update\_option will check value===false to bypass update

 

89

        }

 

90

        $purge\_queue = Purge::get\_option( Purge::DB\_QUEUE2 );

 

91

        if ( $purge\_queue && $purge\_queue != -1 ) {

88

92

            @header( $purge\_queue );

89

93

            Debug2::debug( '\[Core\] Purge2 Queue found&sent: ' . $purge\_queue );

90

 

            Purge::delete\_option( Purge::DB\_QUEUE2 );

 

94

        }

 

95

        if ( $purge\_queue != -1 ) {

 

96

            Purge::update\_option( Purge::DB\_QUEUE2, -1 );

91

97

        }

92

98
  • litespeed-cache/trunk/src/crawler.cls.php

    r2595736

    r2634373

95

95

     \*/

96

96

    public function clear\_disabled\_list() {

97

 

        self::delete\_option( 'bypass\_list' );

 

97

        self::update\_option( 'bypass\_list', array() );

98

98

99

99

        $msg = \_\_( 'Crawler disabled list is cleared! All crawlers are set to active! ', 'litespeed-cache' );
  • litespeed-cache/trunk/src/css.cls.php

    r2613854

    r2634373

164

164

        $queue\_k = ( strlen( $vary ) > 32 ? md5( $vary ) : $vary ) . ' ' . $url\_tag;

165

165

        $this->\_queue\[ $queue\_k \] = array(

166

 

            'url'           => $request\_url,

 

166

            'url'           => apply\_filters( 'litespeed\_ccss\_url', $request\_url ),

167

167

            'user\_agent'    => substr( $ua, 0, 200 ),

168

168

            'is\_mobile'     => $this->\_separate\_mobile\_ccss(),

…

…

 

247

247

        $queue\_k = ( strlen( $vary ) > 32 ? md5( $vary ) : $vary ) . ' ' . $url\_tag;

248

248

        $this->\_queue\[ $queue\_k \] = array(

249

 

            'url'           => $request\_url,

 

249

            'url'           => apply\_filters( 'litespeed\_ucss\_url', $request\_url ),

250

250

            'user\_agent'    => substr( $ua, 0, 200 ),

251

251

            'is\_mobile'     => $this->\_separate\_mobile\_ccss(),
  • litespeed-cache/trunk/src/data.cls.php

    r2603914

    r2634373

25

25

            'litespeed\_update\_4\_3',

26

26

        ),

 

27

        '4.4.4-b1'  => array(

 

28

            'litespeed\_update\_4\_4\_4',

 

29

        ),

27

30

    );

28

31

…

…

 

193

196

    private function \_get\_upgrade\_lock() {

194

197

        $is\_upgrading = get\_option( 'litespeed.data.upgrading' );

 

198

        if ( ! $is\_upgrading ) {

 

199

            $this->\_set\_upgrade\_lock( false ); // set option value to existed to avoid repeated db query next time

 

200

        }

195

201

        if ( $is\_upgrading && time() - $is\_upgrading < 3600 ) {

196

202

            return $is\_upgrading;

…

…

 

221

227

    private function \_set\_upgrade\_lock( $lock ) {

222

228

        if ( ! $lock ) {

223

 

            delete\_option( 'litespeed.data.upgrading' );

 

229

            update\_option( 'litespeed.data.upgrading', -1 );

224

230

        }

225

231

        else {

…

…

 

467

473

        }

468

474

469

 

        $q = "SELECT \* FROM \`$tb\_url\_file\` WHERE url\_id=%d AND vary=%s AND type=%d";

 

475

        $q = "SELECT \* FROM \`$tb\_url\_file\` WHERE url\_id=%d AND vary=%s AND type=%d AND expired=0";

470

476

        $file\_row = $wpdb->get\_row( $wpdb->prepare( $q, array( $url\_id, $vary, $type ) ), ARRAY\_A );

471

 

        if ( ! $file\_row ) {

472

 

            $q = "INSERT INTO \`$tb\_url\_file\` SET url\_id=%d, vary=%s, filename=%s, type=%d";

473

 

            $wpdb->query( $wpdb->prepare( $q, array( $url\_id, $vary, $filecon\_md5, $type ) ) );

474

 

            return;

475

 

        }

476

477

477

478

        // Check if has previous file or not

…

…

 

480

481

        }

481

482

482

 

        $q = "UPDATE \`$tb\_url\_file\` SET filename=%s WHERE id=%d";

483

 

        $wpdb->query( $wpdb->prepare( $q, array( $filecon\_md5, $file\_row\[ 'id' \] ) ) );

 

483

        // If the new $filecon\_md5 is marked as expired by previous records, clear those records

 

484

        $q = "DELETE FROM \`$tb\_url\_file\` WHERE filename = %s AND expired > 0";

 

485

        $wpdb->query( $wpdb->prepare( $q, $filecon\_md5 ) );

 

486

 

487

        // Check if there is any other record used the same filename or not

 

488

        $q = "SELECT id FROM \`$tb\_url\_file\` WHERE filename = %s AND expired = 0 AND id != %d LIMIT 1";

 

489

        if ( $wpdb->get\_var( $wpdb->prepare( $q, array( $file\_row\[ 'filename' \], $file\_row\[ 'id' \] ) ) ) ) {

 

490

            $q = "UPDATE \`$tb\_url\_file\` SET filename=%s WHERE id=%d";

 

491

            $wpdb->query( $wpdb->prepare( $q, array( $filecon\_md5, $file\_row\[ 'id' \] ) ) );

 

492

            return;

 

493

        }

 

494

 

495

        // New record needed

 

496

        $q = "INSERT INTO \`$tb\_url\_file\` SET url\_id=%d, vary=%s, filename=%s, type=%d, expired = 0";

 

497

        $wpdb->query( $wpdb->prepare( $q, array( $url\_id, $vary, $filecon\_md5, $type ) ) );

 

498

 

499

        // Mark existing rows as expired

 

500

        if ( $file\_row ) {

 

501

            $q = "UPDATE \`$tb\_url\_file\` SET expired=%d WHERE id=%d";

 

502

            $expired = time() + 86400 \* apply\_filters( 'litespeed\_url\_file\_expired\_days', 20 );

 

503

            $wpdb->query( $wpdb->prepare( $q, array( $expired, $file\_row\[ 'id' \] ) ) );

 

504

 

505

            // Also check if has other files expired already to be deleted

 

506

            $q = "SELECT \* FROM \`$tb\_url\_file\` WHERE url\_id = %d AND expired BETWEEN 1 AND %d";

 

507

            $q = $wpdb->prepare( $q, array( $url\_id, time() ) );

 

508

            $list = $wpdb->get\_results( $q, ARRAY\_A );

 

509

            if ( $list ) {

 

510

                foreach ( $list as $v ) {

 

511

                    $file\_to\_del = $path . '/' . $v\[ 'filename' \] . '.' . ( $file\_type == 'js' ? 'js' : 'css' );

 

512

                    if ( file\_exists( $file\_to\_del ) ) {

 

513

                        // Safe to delete

 

514

                        Debug2::debug( '\[Data\] Delete expired unused file: ' . $file\_to\_del );

 

515

 

516

                        // Clear related lscache first to avoid cache copy of same URL w/ diff QS

 

517

                        // Purge::add( Tag::TYPE\_MIN . '.' . $file\_row\[ 'filename' \] . '.' . $file\_type );

 

518

 

519

                        unlink( $file\_to\_del );

 

520

                    }

 

521

                }

 

522

                $q = "DELETE FROM \`$tb\_url\_file\` WHERE url\_id = %d AND expired BETWEEN 1 AND %d";

 

523

                $wpdb->query( $wpdb->prepare( $q, array( $url\_id, time() ) ) );

 

524

            }

 

525

        }

484

526

485

527

        // Purge this URL to avoid cache copy of same URL w/ diff QS

486

 

        $this->cls( 'Purge' )->purge\_url( Utility::make\_relative( $request\_url ) ?: '/', true, true );

487

 

488

 

        // Check if has other records used this file or not

489

 

        $file\_to\_del = $path . '/' . $file\_row\[ 'filename' \] . '.' . ( $file\_type == 'js' ? 'js' : 'css' );

490

 

491

 

        $q = "SELECT id FROM \`$tb\_url\_file\` WHERE filename = %s LIMIT 1";

492

 

        if ( file\_exists( $file\_to\_del ) && ! $wpdb->get\_var( $wpdb->prepare( $q, $file\_row\[ 'filename' \] ) ) ) {

493

 

            // Safe to delete

494

 

            Debug2::debug( '\[Data\] Delete no more used file ' . $file\_to\_del );

495

 

496

 

            // Clear related lscache first to avoid cache copy of same URL w/ diff QS

497

 

            // Purge::add( Tag::TYPE\_MIN . '.' . $file\_row\[ 'filename' \] . '.' . $file\_type );

498

 

499

 

            unlink( $file\_to\_del );

500

 

        }

 

528

        // $this->cls( 'Purge' )->purge\_url( Utility::make\_relative( $request\_url ) ?: '/', true, true );

501

529

    }

502

530
  • litespeed-cache/trunk/src/data.upgrade.func.php

    r2613854

    r2634373

13

13

use LiteSpeed\\Admin\_Display;

14

14

use LiteSpeed\\File;

 

15

 

16

/\*\*

 

17

 \* Add expired to url\_file table

 

18

 \* @since 4.4.4

 

19

 \*/

 

20

function litespeed\_update\_4\_4\_4() {

 

21

    global $wpdb;

 

22

    Debug2::debug( "\[Data\] Upgrade url\_file table" );

 

23

    $tb\_exists = $wpdb->get\_var( 'SHOW TABLES LIKE "' . $wpdb->prefix . 'litespeed\_url\_file"' );

 

24

    if ( $tb\_exists ) {

 

25

        $q = 'ALTER TABLE \`' . $wpdb->prefix . 'litespeed\_url\_file\`

 

26

                ADD COLUMN \`expired\` int(11) NOT NULL DEFAULT 0,

 

27

                ADD KEY \`filename\_2\` (\`filename\`,\`expired\`),

 

28

                ADD KEY \`url\_id\` (\`url\_id\`,\`expired\`)

 

29

            ';

 

30

        $wpdb->query( $q );

 

31

    }

 

32

}

15

33

16

34

/\*\*
  • litespeed-cache/trunk/src/data_structure/url_file.sql

    r2524344

    r2634373

1

1

\`id\` bigint(20) NOT NULL AUTO\_INCREMENT,

2

2

\`url\_id\` bigint(20) NOT NULL,

3

 

\`vary\` varchar(32) NOT NULL DEFAULT '' COMMENT 'md5 of final vary',

4

 

\`filename\` varchar(32) NOT NULL DEFAULT '' COMMENT 'md5 of file content',

 

3

\`vary\` varchar(32) COLLATE utf8mb4\_unicode\_ci NOT NULL DEFAULT '' COMMENT 'md5 of final vary',

 

4

\`filename\` varchar(32) COLLATE utf8mb4\_unicode\_ci NOT NULL DEFAULT '' COMMENT 'md5 of file content',

5

5

\`type\` tinyint(4) NOT NULL COMMENT 'css=1,js=2,ccss=3,ucss=4',

 

6

\`expired\` int(11) NOT NULL DEFAULT 0,

6

7

PRIMARY KEY (\`id\`),

7

8

KEY \`filename\` (\`filename\`),

8

9

KEY \`type\` (\`type\`),

9

 

KEY \`url\_id\_2\` (\`url\_id\`,\`vary\`,\`type\`)

 

10

KEY \`url\_id\_2\` (\`url\_id\`,\`vary\`,\`type\`),

 

11

KEY \`filename\_2\` (\`filename\`,\`expired\`),

 

12

KEY \`url\_id\` (\`url\_id\`,\`expired\`)
  • litespeed-cache/trunk/src/gui.cls.php

    r2595736

    r2634373

186

186

                }

187

187

188

 

                $promo\_tag = $\_GET\[ 'promo\_tag' \];

 

188

                $promo\_tag = sanitize\_key( $\_GET\[ 'promo\_tag' \] );

189

189

190

190

                if ( empty( $\_instance->\_promo\_list\[ $promo\_tag \] ) ) {

…

…

 

232

232

     \*/

233

233

    public static function has\_msg\_ruleconflict() {

234

 

        return self::get\_option( Admin\_Display::DB\_DISMISS\_MSG ) == Admin\_Display::RULECONFLICT\_ON;

 

234

        $db\_dismiss\_msg = self::get\_option( Admin\_Display::DB\_DISMISS\_MSG );

 

235

        if ( ! $db\_dismiss\_msg ) {

 

236

            self::update\_option( Admin\_Display::DB\_DISMISS\_MSG, -1 );

 

237

        }

 

238

        return $db\_dismiss\_msg == Admin\_Display::RULECONFLICT\_ON;

235

239

    }

236

240

…

…

 

243

247

     \*/

244

248

    public static function has\_whm\_msg() {

245

 

        return self::get\_option( self::WHM\_MSG ) == self::WHM\_MSG\_VAL;

 

249

        $val = self::get\_option( self::WHM\_MSG );

 

250

        if ( ! $val ) {

 

251

            self::dismiss\_whm();

 

252

            return false;

 

253

        }

 

254

        return $val == self::WHM\_MSG\_VAL;

246

255

    }

247

256

…

…

 

253

262

     \*/

254

263

    public static function dismiss\_whm() {

255

 

        self::delete\_option( self::WHM\_MSG );

 

264

        self::update\_option( self::WHM\_MSG, -1 );

256

265

    }

257

266
  • litespeed-cache/trunk/src/htaccess.cls.php

    r2613854

    r2634373

526

526

        $vary\_cookies = $cfg\[ $id \] ? array( $cfg\[ $id \] ) : array();

527

527

        if ( LITESPEED\_SERVER\_TYPE === 'LITESPEED\_SERVER\_OLS' ) { // Need to keep this due to different behavior of OLS when handling response vary header @Sep/22/2018

528

 

            $vary\_cookies\[\] = ',wp-postpass\_' . COOKIEHASH;

 

528

            if ( defined( 'COOKIEHASH' ) ) {

 

529

                $vary\_cookies\[\] = ',wp-postpass\_' . COOKIEHASH;

 

530

            }

529

531

            $vary\_cookies = apply\_filters( 'litespeed\_vary\_cookies', $vary\_cookies ); // todo: test if response vary header can work in latest OLS, drop the above two lines

530

532

        }
  • litespeed-cache/trunk/src/optimize.cls.php

    r2613854

    r2634373

807

807

                continue;

808

808

            }

 

809

            if ( ! empty( $attrs\[ 'data-cfasync' \] ) && $attrs\[ 'data-cfasync' \] === 'false'  ) {

 

810

                continue;

 

811

            }

809

812

            if ( ! empty( $attrs\[ 'type' \] ) && $attrs\[ 'type' \] != 'text/javascript' ) {

810

813

                continue;
  • litespeed-cache/trunk/src/purge.cls.php

    r2613854

    r2634373

285

285

     \*/

286

286

    private function \_purge\_all\_cssjs( $silence = false ) {

 

287

        if ( defined( 'LITESPEED\_DID\_send\_headers' ) ) {

 

288

            Debug2::debug( "❌ Bypassed cssjs delete as header sent (lscache purge after this point will fail)" );

 

289

            return;

 

290

        }

287

291

        $this->\_purge\_all\_lscache( $silence ); // Purge CSSJS must purge lscache too to avoid 404

288

292
  • litespeed-cache/trunk/src/report.cls.php

    r2524344

    r2634373

48

48

49

49

        // Generate link

50

 

        $link = ! empty( $\_POST\[ 'link' \] ) ? $\_POST\[ 'link' \] : '';

51

 

52

 

        $notes = ! empty( $\_POST\[ 'notes' \] ) ? $\_POST\[ 'notes' \] : '';

 

50

        $link = ! empty( $\_POST\[ 'link' \] ) ? esc\_url( $\_POST\[ 'link' \] ) : '';

 

51

 

52

        $notes = ! empty( $\_POST\[ 'notes' \] ) ? esc\_html( $\_POST\[ 'notes' \] ) : '';

53

53

54

54

        $data = array(
  • litespeed-cache/trunk/src/router.cls.php

    r2613854

    r2634373

189

189

        $rest\_prefix = function\_exists( 'rest\_get\_url\_prefix' ) ? rest\_get\_url\_prefix() : apply\_filters( 'rest\_url\_prefix', 'wp-json' );

190

190

        if (

191

 

            strpos( $\_SERVER\[ 'REQUEST\_URI' \], $rest\_prefix . '/wp/v2/media' ) !== false

192

 

            && strpos( $\_SERVER\[ 'HTTP\_REFERER' \], 'wp-admin') !== false

 

191

            ! empty( $\_SERVER\[ 'REQUEST\_URI' \] ) &&

 

192

            strpos( $\_SERVER\[ 'REQUEST\_URI' \], $rest\_prefix . '/wp/v2/media' ) !== false &&

 

193

            strpos( $\_SERVER\[ 'HTTP\_REFERER' \], 'wp-admin') !== false

193

194

        ) {

194

195

            Debug2::debug( '\[Router\] CDN bypassed: wp-json on admin page' );

…

…

 

625

626

            self::$\_ip = self::get\_ip();

626

627

        }

 

628

 

629

        if ( ! self::$\_ip ) {

 

630

            return false;

 

631

        }

627

632

        // $uip = explode('.', $\_ip);

628

633

        // if(empty($uip) || count($uip) != 4) Return false;

…

…

 

645

650

    public static function get\_ip() {

646

651

        $\_ip = '';

647

 

        if ( function\_exists( 'apache\_request\_headers' ) ) {

648

 

            $apache\_headers = apache\_request\_headers();

649

 

            $\_ip = ! empty( $apache\_headers\['True-Client-IP'\] ) ? $apache\_headers\['True-Client-IP'\] : false;

650

 

            if ( ! $\_ip ) {

651

 

                $\_ip = ! empty( $apache\_headers\['X-Forwarded-For'\] ) ? $apache\_headers\['X-Forwarded-For'\] : false;

652

 

                $\_ip = explode( ',', $\_ip );

653

 

                $\_ip = $\_ip\[ 0 \];

654

 

            }

655

 

656

 

        }

 

652

        // if ( function\_exists( 'apache\_request\_headers' ) ) {

 

653

        // $apache\_headers = apache\_request\_headers();

 

654

        // $\_ip = ! empty( $apache\_headers\['True-Client-IP'\] ) ? $apache\_headers\['True-Client-IP'\] : false;

 

655

        // if ( ! $\_ip ) {

 

656

        //      $\_ip = ! empty( $apache\_headers\['X-Forwarded-For'\] ) ? $apache\_headers\['X-Forwarded-For'\] : false;

 

657

        //      $\_ip = explode( ',', $\_ip );

 

658

        //      $\_ip = $\_ip\[ 0 \];

 

659

        // }

 

660

 

661

        // }

657

662

658

663

        if ( ! $\_ip ) {
  • litespeed-cache/trunk/thirdparty/nextgengallery.cls.php

    r2295686

    r2634373

73

73

    {

74

74

        if ( isset( $\_REQUEST\[ 'gallery\_id' \] ) ) {

75

 

            do\_action( 'litespeed\_purge', self::CACHETAG\_GALLERIES . $\_REQUEST\[ 'gallery\_id' \] ) ;

 

75

            do\_action( 'litespeed\_purge', self::CACHETAG\_GALLERIES . sanitize\_key( $\_REQUEST\[ 'gallery\_id' \] ) );

76

76

            return ;

77

77

        }

…

…

 

82

82

83

83

            if ( ! empty( $task\_list\[ 0 \]\[ 'query' \]\[ 'id' \] ) ) {

84

 

                do\_action( 'litespeed\_purge', self::CACHETAG\_GALLERIES . $task\_list\[ 0 \]\[ 'query' \]\[ 'id' \] ) ;

 

84

                do\_action( 'litespeed\_purge', self::CACHETAG\_GALLERIES . sanitize\_key( $task\_list\[ 0 \]\[ 'query' \]\[ 'id' \] ) );

85

85

                return ;

86

86

            }

…

…

 

88

88

89

89

        if ( isset($\_POST\['id'\]) ) {

90

 

            $id = $\_POST\['id'\] ;

 

90

            $id = (int)$\_POST\['id'\] ;

91

91

        }

92

92

        elseif ( isset($\_POST\['image'\]) ) {

93

 

            $id = $\_POST\['image'\] ;

 

93

            $id = (int)$\_POST\['image'\] ;

94

94

        }

95

95

        elseif ( isset($\_GET\['pid'\]) ) {

96

 

            $id = $\_GET\['pid'\] ;

 

96

            $id = (int)$\_GET\['pid'\] ;

97

97

        }

98

98

        else {

…

…

 

115

115

    {

116

116

        if ( isset($\_GET\['gid'\]) ) {

117

 

            do\_action( 'litespeed\_purge', self::CACHETAG\_GALLERIES . $\_GET\['gid'\] );

 

117

            do\_action( 'litespeed\_purge', self::CACHETAG\_GALLERIES . sanitize\_key( $\_GET\['gid'\] ) );

118

118

        }

119

119

    }
  • litespeed-cache/trunk/tpl/crawler/summary.tpl.php

    r2595736

    r2634373

98

98

    <p class='litespeed-desc'>

99

99

        <b><?php echo \_\_( 'Ended reason', 'litespeed-cache' ); ?>:</b>

100

 

        <?php echo $summary\[ 'end\_reason' \]; ?>

 

100

        <?php echo esc\_html( $summary\[ 'end\_reason' \] ); ?>

101

101

    </p>

102

102

    <?php endif; ?>
  • litespeed-cache/trunk/tpl/dash/dashboard.tpl.php

    r2595736

    r2634373

405

405

                                <span class="litespeed-label-danger litespeed-label-dashboard">OFF</span>

406

406

                            <?php endif; ?>

407

 

                            <?php echo $title; ?>

 

407

                            <?php echo esc\_html( $title ); ?>

408

408

                        </p>

409

409

                    <?php endforeach; ?>

…

…

 

438

438

                        </p>

439

439

                        <p>

440

 

                            <?php echo \_\_( 'Time to execute previous request', 'litespeed-cache' ) . ': <code>' . $css\_summary\[ 'last\_spent\_ccss' \] . 's</code>'; ?>

 

440

                            <?php echo \_\_( 'Time to execute previous request', 'litespeed-cache' ) . ': <code>' . esc\_html( $css\_summary\[ 'last\_spent\_ccss' \] ) . 's</code>'; ?>

441

441

                        </p>

442

442

                    <?php endif; ?>

…

…

 

471

471

                        </p>

472

472

                        <p>

473

 

                            <?php echo \_\_( 'Time to execute previous request', 'litespeed-cache' ) . ': <code>' . $css\_summary\[ 'last\_spent\_ucss' \] . 's</code>'; ?>

 

473

                            <?php echo \_\_( 'Time to execute previous request', 'litespeed-cache' ) . ': <code>' . esc\_html( $css\_summary\[ 'last\_spent\_ucss' \] ) . 's</code>'; ?>

474

474

                        </p>

475

475

                    <?php endif; ?>

…

…

 

504

504

                        </p>

505

505

                        <p>

506

 

                            <?php echo \_\_( 'Time to execute previous request', 'litespeed-cache' ) . ': <code>' . $placeholder\_summary\[ 'last\_spent' \] . 's</code>'; ?>

 

506

                            <?php echo \_\_( 'Time to execute previous request', 'litespeed-cache' ) . ': <code>' . esc\_html( $placeholder\_summary\[ 'last\_spent' \] ) . 's</code>'; ?>

507

507

                        </p>

508

508

                    <?php endif; ?>

…

…

 

535

535

                    </p>

536

536

                    <p>

537

 

                        <?php echo \_\_( 'Currently active crawler', 'litespeed-cache' ); ?>: <code><?php echo $crawler\_summary\[ 'curr\_crawler' \] ?></code>

 

537

                        <?php echo \_\_( 'Currently active crawler', 'litespeed-cache' ); ?>: <code><?php echo esc\_html( $crawler\_summary\[ 'curr\_crawler' \] ); ?></code>

538

538

                    </p>

539

539

…

…

 

555

555

                    <p class='litespeed-desc'>

556

556

                        <b><?php echo \_\_( 'Ended reason', 'litespeed-cache' ); ?>:</b>

557

 

                        <?php echo $crawler\_summary\[ 'end\_reason' \]; ?>

 

557

                        <?php echo esc\_html( $crawler\_summary\[ 'end\_reason' \] ); ?>

558

558

                    </p>

559

559

                    <?php endif; ?>

…

…

 

561

561

                    <?php if ( $crawler\_summary\[ 'last\_crawled' \] ) : ?>

562

562

                    <p class='litespeed-desc'>

563

 

                        <?php echo sprintf(\_\_('<b>Last crawled:</b> %s item(s)', 'litespeed-cache'), $crawler\_summary\[ 'last\_crawled' \] ); ?>

 

563

                        <?php echo sprintf(\_\_('<b>Last crawled:</b> %d item(s)', 'litespeed-cache'), $crawler\_summary\[ 'last\_crawled' \] ); ?>

564

564

                    </p>

565

565

                    <?php endif; ?>
  • litespeed-cache/trunk/tpl/dash/network_dash.tpl.php

    r2292926

    r2634373

78

78

                                    <h3><?php echo ( $svc == 'img\_optm' ? \_\_('Fast Queue Usage','litespeed-cache') : \_\_( 'Usage', 'litespeed-cache' ) ); ?></h3>

79

79

                                    <p>

80

 

                                        <strong><?php echo $used; ?></strong>

 

80

                                        <strong><?php echo esc\_html( $used ); ?></strong>

81

81

                                        <?php if( $used != $quota ) { ?>

82

 

                                            <span class="litespeed-desc"> of <?php echo $quota; ?></span>

 

82

                                            <span class="litespeed-desc"> of <?php echo esc\_html( $quota ); ?></span>

83

83

                                        <?php } ?>

84

84

                                    </p>

…

…

 

88

88

                        <?php if ( $pag\_total > 0 ) { ?>

89

89

                            <p class="litespeed-dashboard-stats-payg" data-balloon-pos="up" aria-label="<?php echo \_\_('Pay as You Go','litespeed-cache'); ?>">

90

 

                                <?php echo \_\_('PAYG Balance','litespeed-cache'); ?>: <strong><?php echo $pag\_bal; ?></strong>

91

 

                                <button class="litespeed-info-button" data-balloon-pos="up" aria-label="<?php echo \_\_('This Month Usage','litespeed-cache'); ?>: <?php echo $pag\_used;?>">

 

90

                                <?php echo \_\_('PAYG Balance','litespeed-cache'); ?>: <strong><?php echo esc\_html( $pag\_bal ); ?></strong>

 

91

                                <button class="litespeed-info-button" data-balloon-pos="up" aria-label="<?php echo \_\_('This Month Usage','litespeed-cache'); ?>: <?php echo esc\_html( $pag\_used );?>">

92

92

                                    <span class="dashicons dashicons-info"></span>

93

93

                                    <span class="screen-reader-text"><?php echo \_\_( 'Pay as You Go Usage Statistics', 'litespeed-cache' );?></span>

…

…

 

98

98

                        <?php if ( $svc == 'img\_optm' ) { ?>

99

99

                            <p class="litespeed-dashboard-stats-total">

100

 

                                <?php echo \_\_('Total Usage','litespeed-cache'); ?>: <strong><?php echo $total\_used; ?> / ∞</strong>

 

100

                                <?php echo \_\_('Total Usage','litespeed-cache'); ?>: <strong><?php echo esc\_html( $total\_used ); ?> / ∞</strong>

101

101

                                <button class="litespeed-info-button" data-balloon-pos="up" aria-label="<?php echo \_\_('Total images optimized in this month','litespeed-cache'); ?>">

102

102

                                    <span class="dashicons dashicons-info"></span>
  • litespeed-cache/trunk/tpl/img_optm/summary.tpl.php

    r2595736

    r2634373

64

64

65

65

            <p>

66

 

                <?php echo sprintf( \_\_( 'You can request a maximum of %s images at once.', 'litespeed-cache' ), '<strong>' . $allowance . '</strong>' ); ?>

 

66

                <?php echo sprintf( \_\_( 'You can request a maximum of %s images at once.', 'litespeed-cache' ), '<strong>' . intval( $allowance ) . '</strong>' ); ?>

67

67

            </p>

68

68

…

…

 

195

195

                            <?php if ( $optm\_summary\[ 'bk\_summary' \]\[ 'count' \] ) : ?>

196

196

                                <p>

197

 

                                    <?php echo \_\_( 'Files', 'litespeed-cache' ) . ': <code>' . $optm\_summary\[ 'bk\_summary' \]\[ 'count' \] . '</code>'; ?>

 

197

                                    <?php echo \_\_( 'Files', 'litespeed-cache' ) . ': <code>' . intval( $optm\_summary\[ 'bk\_summary' \]\[ 'count' \] ) . '</code>'; ?>

198

198

                                </p>

199

199

                                <p>
  • litespeed-cache/trunk/tpl/inc/check_cache_disabled.php

    r2326888

    r2634373

38

38

        <?php foreach ( $reasons as $v ) : ?>

39

39

            <li>

40

 

                <?php echo $v\[ 'title' \] ; ?>

 

40

                <?php echo esc\_html( $v\[ 'title' \] ); ?>

41

41

42

42

                <a href="<?php echo $v\[ 'link' \] ; ?>" target="\_blank" class="litespeed-learn-more"><?php echo \_\_( 'Learn More', 'litespeed-cache' ) ; ?></a>
  • litespeed-cache/trunk/tpl/page_optm/settings_css.tpl.php

    r2613854

    r2634373

105

105

                            <?php if ( ! is\_array( $v ) ) continue; ?>

106

106

                            <?php if ( ! empty( $v\[ '\_status' \] ) ) : ?><span class="litespeed-success"><?php endif; ?>

107

 

                            <?php echo $v\[ 'url' \]; ?>

 

107

                            <?php echo esc\_html( $v\[ 'url' \] ); ?>

108

108

                            <?php if ( ! empty( $v\[ '\_status' \] ) ) : ?></span><?php endif; ?>

109

109

                            <?php if ( $pos = strpos( $k, ' ' ) ) echo ' (' . \_\_( 'Vary Group', 'litespeed-cache' ) . ':' . substr( $k, 0, $pos ) . ')'; ?>

…

…

 

215

215

                            <?php if ( ! is\_array( $v ) ) continue; ?>

216

216

                            <?php if ( ! empty( $v\[ '\_status' \] ) ) : ?><span class="litespeed-success"><?php endif; ?>

217

 

                            <?php echo $v\[ 'url' \]; ?>

 

217

                            <?php echo esc\_html( $v\[ 'url' \] ); ?>

218

218

                            <?php if ( ! empty( $v\[ '\_status' \] ) ) : ?></span><?php endif; ?>

219

219

                            <?php if ( $pos = strpos( $k, ' ' ) ) echo ' (' . \_\_( 'Vary Group', 'litespeed-cache' ) . ':' . substr( $k, 0, $pos ) . ')'; ?>

CVE: Latest News

CVE-2023-50976: Transactions API Authorization by oleiman · Pull Request #14969 · redpanda-data/redpanda
CVE-2023-6905
CVE-2023-6903
CVE-2023-6904
CVE-2023-3907