-
-
Notifications
You must be signed in to change notification settings - Fork 354
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
b01d874
commit 50e6dfa
Showing
5 changed files
with
29 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -58,7 +58,7 @@ dev dependencies: { | |
* @license For commercial or closed source, contact us at [email protected] or purchase directly via CodeCanyon | ||
* @license CodeCanyon: https://codecanyon.net/item/mirotalk-sfu-webrtc-realtime-video-conferences/40769970 | ||
* @author Miroslav Pejic - [email protected] | ||
* @version 1.7.25 | ||
* @version 1.7.26 | ||
* | ||
*/ | ||
|
||
|
@@ -416,12 +416,22 @@ function startServer() { | |
}); | ||
return res.status(400).send({ status: 404, message: err.message }); // Bad request | ||
} | ||
if (req.path.substr(-1) === '/' && req.path.length > 1) { | ||
let query = req.url.slice(req.path.length); | ||
res.redirect(301, req.path.slice(0, -1) + query); | ||
} else { | ||
next(); | ||
|
||
// Remove multiple leading slashes & normalize path | ||
let cleanPath = req.path.replace(/^\/+/, ''); // Removes all leading slashes | ||
let query = req.url.slice(req.path.length); | ||
|
||
// Prevent open redirect attacks by checking if the path is an external domain | ||
if (/^([a-zA-Z0-9-]+\.)+[a-zA-Z]{2,}/.test(cleanPath)) { | ||
return res.status(400).send('Bad Request: Potential Open Redirect Detected'); | ||
} | ||
|
||
// If a trailing slash exists, redirect to a clean version | ||
if (req.path.endsWith('/') && req.path.length > 1) { | ||
return res.redirect(301, '/' + cleanPath + query); | ||
} | ||
|
||
next(); | ||
}); | ||
|
||
// OpenID Connect - Dynamically set baseURL based on incoming host and protocol | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,7 +11,7 @@ if (location.href.substr(0, 5) !== 'https') location.href = 'https' + location.h | |
* @license For commercial or closed source, contact us at [email protected] or purchase directly via CodeCanyon | ||
* @license CodeCanyon: https://codecanyon.net/item/mirotalk-sfu-webrtc-realtime-video-conferences/40769970 | ||
* @author Miroslav Pejic - [email protected] | ||
* @version 1.7.25 | ||
* @version 1.7.26 | ||
* | ||
*/ | ||
|
||
|
@@ -4905,7 +4905,7 @@ function showAbout() { | |
position: 'center', | ||
imageUrl: BRAND.about?.imageUrl && BRAND.about.imageUrl.trim() !== '' ? BRAND.about.imageUrl : image.about, | ||
customClass: { image: 'img-about' }, | ||
title: BRAND.about?.title && BRAND.about.title.trim() !== '' ? BRAND.about.title : 'WebRTC SFU v1.7.25', | ||
title: BRAND.about?.title && BRAND.about.title.trim() !== '' ? BRAND.about.title : 'WebRTC SFU v1.7.26', | ||
html: ` | ||
<br /> | ||
<div id="about"> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,7 +9,7 @@ | |
* @license For commercial or closed source, contact us at [email protected] or purchase directly via CodeCanyon | ||
* @license CodeCanyon: https://codecanyon.net/item/mirotalk-sfu-webrtc-realtime-video-conferences/40769970 | ||
* @author Miroslav Pejic - [email protected] | ||
* @version 1.7.25 | ||
* @version 1.7.26 | ||
* | ||
*/ | ||
|
||
|
@@ -8967,7 +8967,12 @@ class RoomClient { | |
} catch (error) { | ||
switch (error.code) { | ||
case 'quota_not_enough': | ||
this.msgPopup('warning', 'You’ve reached your quota limit for this demo account. Please consider upgrading for more features.', 6000, 'top'); | ||
this.msgPopup( | ||
'warning', | ||
'You’ve reached your quota limit for this demo account. Please consider upgrading for more features.', | ||
6000, | ||
'top', | ||
); | ||
break; | ||
// ... | ||
default: | ||
|