| 1096 | } |
| 1097 | |
| 1098 | void ClntAuthBlock::extractDataFromPluginTo(ClumpletWriter& user_id) |
| 1099 | { |
| 1100 | // Add user login name |
| 1101 | if (cliOrigUserName.hasData()) |
| 1102 | { |
| 1103 | HANDSHAKE_DEBUG(fprintf(stderr, "Cli: extractDataFromPluginTo: cliOrigUserName=%s\n", |
| 1104 | cliOrigUserName.c_str())); |
| 1105 | user_id.insertString(CNCT_login, cliOrigUserName); |
| 1106 | } |
| 1107 | |
| 1108 | // Add plugin name |
| 1109 | PathName pluginName = getPluginName(); |
| 1110 | if (pluginName.hasData()) |
| 1111 | { |
| 1112 | HANDSHAKE_DEBUG(fprintf(stderr, "Cli: extractDataFromPluginTo: pluginName=%s\n", pluginName.c_str())); |
| 1113 | user_id.insertString(CNCT_plugin_name, pluginName); |
| 1114 | } |
| 1115 | |
| 1116 | // Add plugin list |
| 1117 | if (pluginList.hasData()) |
| 1118 | { |
| 1119 | user_id.insertString(CNCT_plugin_list, pluginList); |
| 1120 | } |
| 1121 | |
| 1122 | // This is specially tricky field - user_id is limited to 255 bytes per entry, |
| 1123 | // and we have no ways to override this limit cause it can be sent to any version server. |
| 1124 | // Therefore divide data into 254-byte parts, leaving first byte for the number of that part. |
| 1125 | // This appears more reliable than put them in strict order. |
| 1126 | addMultiPartConnectParameter(dataFromPlugin, user_id, CNCT_specific_data); |
| 1127 | |
| 1128 | // Client's wirecrypt requested level |
| 1129 | user_id.insertInt(CNCT_client_crypt, clntConfig->getWireCrypt(WC_CLIENT)); |
| 1130 | } |
| 1131 | |
| 1132 | void ClntAuthBlock::resetClnt(const CSTRING* listStr) |
| 1133 | { |
no test coverage detected