@@ -954,7 +954,7 @@ std::string netchToSS(std::vector<nodeInfo> &nodes, extra_settings &ext)
954
954
switch (x.linkType )
955
955
{
956
956
case SPEEDTEST_MESSAGE_FOUNDSS:
957
- proxyStr = " ss://" + urlsafe_base64_encode (method + " :" + password + " @" + hostname + " :" + port) ;
957
+ proxyStr = " ss://" + urlsafe_base64_encode (method + " :" + password) + " @" + hostname + " :" + port;
958
958
if (plugin.size () && pluginopts.size ())
959
959
{
960
960
proxyStr += " /?plugin=" + UrlEncode (plugin + " ;" +pluginopts);
@@ -963,7 +963,7 @@ std::string netchToSS(std::vector<nodeInfo> &nodes, extra_settings &ext)
963
963
break ;
964
964
case SPEEDTEST_MESSAGE_FOUNDSSR:
965
965
if (std::count (ss_ciphers.begin (), ss_ciphers.end (), method) > 0 && protocol == " origin" && obfs == " plain" )
966
- proxyStr = " ss://" + urlsafe_base64_encode (method + " :" + password + " @" + hostname + " :" + port) + " #" + UrlEncode (remark);
966
+ proxyStr = " ss://" + urlsafe_base64_encode (method + " :" + password) + " @" + hostname + " :" + port + " #" + UrlEncode (remark);
967
967
break ;
968
968
default :
969
969
continue ;
@@ -1317,7 +1317,7 @@ std::string netchToSSD(std::vector<nodeInfo> &nodes, std::string &group, extra_s
1317
1317
{
1318
1318
json.Parse (x.proxyStr .data ());
1319
1319
1320
- remark = x.remarks ;
1320
+ remark = " \" " + replace_all_distinct ( UTF8ToCodePoint ( x.remarks ), " \\ u1f1 " , " \\ ud83c \\ udd " ) + " \" " ;
1321
1321
hostname = GetMember (json, " Hostname" );
1322
1322
port = (unsigned short )stoi (GetMember (json, " Port" ));
1323
1323
password = GetMember (json, " Password" );
@@ -1348,7 +1348,7 @@ std::string netchToSSD(std::vector<nodeInfo> &nodes, std::string &group, extra_s
1348
1348
writer.Key (" plugin_options" );
1349
1349
writer.String (pluginopts.data ());
1350
1350
writer.Key (" remarks" );
1351
- writer.String (remark.data ());
1351
+ writer.RawValue (remark.data (), remark. size (), rapidjson::Type:: kStringType );
1352
1352
writer.Key (" id" );
1353
1353
writer.Int (index);
1354
1354
writer.EndObject ();
@@ -1367,7 +1367,7 @@ std::string netchToSSD(std::vector<nodeInfo> &nodes, std::string &group, extra_s
1367
1367
writer.String (password.data ());
1368
1368
writer.String (pluginopts.data ());
1369
1369
writer.Key (" remarks" );
1370
- writer.String (remark.data ());
1370
+ writer.RawValue (remark.data (), remark. size (), rapidjson::Type:: kStringType );
1371
1371
writer.Key (" id" );
1372
1372
writer.Int (index);
1373
1373
writer.EndObject ();
0 commit comments