Nikita Vilunov nikita
  • Joined on 2023-08-25
nikita commented on pull request lavina/lavina#19 2023-10-01 22:28:51 +00:00
[xmpp] logopass auth

I don't think you need that clone here, you can just make the function argument mutable

nikita commented on pull request lavina/lavina#19 2023-10-01 22:28:51 +00:00
[xmpp] logopass auth

each unwrap() crashes the thread completely which is not very desirable. instead it's better to return an Err from the method

nikita commented on pull request lavina/lavina#19 2023-10-01 22:28:51 +00:00
[xmpp] logopass auth

not sure about the algorithm, afaik there could be three different segments: <authzid>\x00<authcid>\x00<passwd>, the first one could be empty and we don't really use it (for now? not sure), but it's better not to skip empty ones and just ignore them

nikita commented on pull request lavina/lavina#19 2023-10-01 22:28:51 +00:00
[xmpp] logopass auth

You can do

nikita suggested changes for lavina/lavina#19 2023-10-01 22:28:51 +00:00
[xmpp] logopass auth
nikita commented on pull request lavina/lavina#19 2023-10-01 22:28:51 +00:00
[xmpp] logopass auth

AuthBody.login here

nikita commented on pull request lavina/lavina#19 2023-10-01 22:28:51 +00:00
[xmpp] logopass auth

fine for now, but this fails the stream, and instead we should send a proper XML error to the client

nikita commented on pull request lavina/lavina#19 2023-10-01 22:28:51 +00:00
[xmpp] logopass auth

better to accept input as a slice

nikita commented on pull request lavina/lavina#19 2023-10-01 22:22:32 +00:00
[xmpp] logopass auth

you can just compare them directly without taking references and without specifying the numeric type (it will be inferred automatically)

if separated_words.len() == 2
nikita created pull request lavina/lavina#20 2023-10-01 19:55:05 +00:00
xmpp: fix parsing of unknown elements in messages
nikita pushed to fix-xmpp-messages at nikita/lavina 2023-10-01 19:54:31 +00:00
ea0377c78a fix message parsing
7c89936a87 xmpp: fix message parsing when unknown elements are present
2f034284cf rename telemetry mod to http
dc0a101fe6 split xmpp projection into a separate crate
854a244dbc split irc proejction into a separate crate (#18)
Compare 6 commits »
nikita created branch fix-xmpp-messages in nikita/lavina 2023-10-01 19:54:31 +00:00
nikita pushed to main at lavina/lavina 2023-10-01 16:16:20 +00:00
8047a97baa remove /test/
nikita pushed to main at lavina/lavina 2023-10-01 16:15:53 +00:00
47195f5eee add crates/README.md
nikita pushed to main at lavina/lavina 2023-09-30 23:50:13 +00:00
2f034284cf rename telemetry mod to http
nikita pushed to main at lavina/lavina 2023-09-30 23:47:28 +00:00
dc0a101fe6 split xmpp projection into a separate crate
nikita deleted branch proj-irc-crate from nikita/lavina 2023-09-30 23:34:36 +00:00
nikita pushed to main at lavina/lavina 2023-09-30 23:34:36 +00:00
854a244dbc split irc proejction into a separate crate (#18)
nikita merged pull request lavina/lavina#18 2023-09-30 23:34:36 +00:00
split irc proejction into a separate crate
nikita pushed to proj-irc-crate at nikita/lavina 2023-09-30 23:31:31 +00:00
18f9e89e6b remove old e2e tests