[mirotalksfu] - fix getIP, getIpSocket, update dep

هذا الالتزام موجود في:
Miroslav Pejic
2025-11-04 02:06:15 +01:00
الأصل 8e5c792644
التزام 1a88a50ef7
5 ملفات معدلة مع 17 إضافات و13 حذوفات

عرض الملف

@@ -64,7 +64,7 @@ dev dependencies: {
* @license For commercial or closed source, contact us at license.mirotalk@gmail.com or purchase directly via CodeCanyon
* @license CodeCanyon: https://codecanyon.net/item/mirotalk-sfu-webrtc-realtime-video-conferences/40769970
* @author Miroslav Pejic - miroslav.pejic.85@gmail.com
* @version 1.9.97
* @version 1.9.98
*
*/
@@ -4025,15 +4025,19 @@ function startServer() {
}
function getIP(req) {
return req.headers['x-forwarded-for'] || req.headers['X-Forwarded-For'] || req.socket.remoteAddress || req.ip;
const forwarded = req.headers['x-forwarded-for'] || req.headers['X-Forwarded-For'];
if (forwarded) {
return forwarded.split(',')[0].trim();
}
return req.socket.remoteAddress || req.ip;
}
function getIpSocket(socket) {
return (
socket.handshake.headers['x-forwarded-for'] ||
socket.handshake.headers['X-Forwarded-For'] ||
socket.handshake.address
);
const forwarded = socket.handshake.headers['x-forwarded-for'] || socket.handshake.headers['X-Forwarded-For'];
if (forwarded) {
return forwarded.split(',')[0].trim();
}
return socket.handshake.address;
}
function updateHostAuthenticatedFlag() {

عرض الملف

@@ -1,6 +1,6 @@
{
"name": "mirotalksfu",
"version": "1.9.97",
"version": "1.9.98",
"description": "WebRTC SFU browser-based video calls",
"main": "Server.js",
"scripts": {
@@ -84,7 +84,7 @@
"mediasoup": "3.19.7",
"mediasoup-client": "3.18.0",
"nodemailer": "^7.0.10",
"openai": "^6.7.0",
"openai": "^6.8.0",
"qs": "6.14.0",
"sanitize-filename": "^1.6.3",
"socket.io": "4.8.1",

عرض الملف

@@ -78,7 +78,7 @@ let BRAND = {
},
about: {
imageUrl: '../images/mirotalk-logo.gif',
title: '<strong>WebRTC SFU v1.9.97</strong>',
title: '<strong>WebRTC SFU v1.9.98</strong>',
html: `
<button
id="support-button"

عرض الملف

@@ -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 license.mirotalk@gmail.com or purchase directly via CodeCanyon
* @license CodeCanyon: https://codecanyon.net/item/mirotalk-sfu-webrtc-realtime-video-conferences/40769970
* @author Miroslav Pejic - miroslav.pejic.85@gmail.com
* @version 1.9.97
* @version 1.9.98
*
*/
@@ -5765,7 +5765,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.9.97',
title: BRAND.about?.title && BRAND.about.title.trim() !== '' ? BRAND.about.title : 'WebRTC SFU v1.9.98',
html: `
<br />
<div id="about">

عرض الملف

@@ -9,7 +9,7 @@
* @license For commercial or closed source, contact us at license.mirotalk@gmail.com or purchase directly via CodeCanyon
* @license CodeCanyon: https://codecanyon.net/item/mirotalk-sfu-webrtc-realtime-video-conferences/40769970
* @author Miroslav Pejic - miroslav.pejic.85@gmail.com
* @version 1.9.97
* @version 1.9.98
*
*/