remove "VIAaaS" from server id

This commit is contained in:
creeper123123321 2021-03-24 14:48:40 -03:00 committed by GitHub
parent 52f6395bc0
commit cf4573fc9d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -161,8 +161,8 @@ suspend fun hasJoined(username: String, hash: String): JsonObject {
fun generate128Bits() = ByteArray(16).also { secureRandom.nextBytes(it) }
fun generateServerId() = "VIAaaS" + ByteArray(10).let {
fun generateServerId() = ByteArray(13).let {
secureRandom.nextBytes(it)
Base64.getEncoder().withoutPadding().encodeToString(it)
// https://developer.mozilla.org/en-US/docs/Glossary/Base64 133% of original
}
}