commit 4733ccd8a7dabb97cfeafe0224d3729429be45f0 Author: polynom.me CI system Date: Sat Feb 3 16:02:50 2024 +0000 Deploy new version 1ac1d00b5c1c0510ec791d7d7854da0a334d707a diff --git a/404.html b/404.html new file mode 100644 index 0000000..f8414f0 --- /dev/null +++ b/404.html @@ -0,0 +1,3 @@ + +404 Not Found +

404 Not Found

diff --git a/CNAME b/CNAME new file mode 100644 index 0000000..810aa0d --- /dev/null +++ b/CNAME @@ -0,0 +1 @@ +moxxy.org \ No newline at end of file diff --git a/blog/groupchat-gsoc-project/index.html b/blog/groupchat-gsoc-project/index.html new file mode 100644 index 0000000..486685f --- /dev/null +++ b/blog/groupchat-gsoc-project/index.html @@ -0,0 +1,82 @@ + + + + + + + + + + + + + Moxxy's First GSoC Project! + + + +
+
+
+ + + + + + + Moxxy + + + +
+ + Blog + Developers + Source +
+
+ + +
+
+

Moxxy's First GSoC Project!

+ Posted by Ikjot Singh Dhody on 2023-05-06 +
+

Hello readers!

+

As we know, Moxxy is an experimental IM for XMPP built using Flutter. While it does have a great set of features as described here, it currently lacks support for group chats (or Multi-User-Chats). A great piece of news is that Google has accepted my proposal to add support for multi user chats in Moxxy.

+ +

To implement multi user chats in Moxxy, the XEP-0045 standard will be followed and implemented. The project will run in two phases, since the major changes required will be in the moxxmpp and Moxxy codebases. First, XEP-0045 support will be added to moxxmpp with all the handlers, events and routines required to cleanly integrate the same with Moxxy. The second phase will be the UI changes in the Moxxy Flutter application, that builds upon the existing, reusable infrastructure.

+

The usecases planned to be implemented are listed below (subject to changes before the coding period begins):

+
    +
  • Join a room
  • +
  • Leave a room
  • +
  • Change availability status
  • +
  • View member list
  • +
  • Send/receive a message to/from all occupants
  • +
  • Send/receive a private message to/from a specific occupant
  • +
+

Some extra usecases are planned in case time permits:

+
    +
  • Change nickname
  • +
  • Kick an occupant (if user has such a permission)
  • +
  • Ban an occupant (if user has such a permission)
  • +
  • Grant/revoke membership (if user has such a permission)
  • +
+

The coding period for this project will begin on May 29. In case of any queries/interest, please join the following - xmpp:dev@muc.moxxy.org?join.

+ +
+
+
+ +
+ + + + diff --git a/blog/index.html b/blog/index.html new file mode 100644 index 0000000..4a3cfc3 --- /dev/null +++ b/blog/index.html @@ -0,0 +1,142 @@ + + + + + + + + + + + + + Moxxy | A modern XMPP client + + + +
+
+
+ + + + + + + Moxxy + + + +
+ + Blog + Developers + Source +
+
+ + +
+
+
+

Blog posts

+ + + + + + +
+ +
+ + +
+ +

GSoC report - Moxxy MUC implementation

+
+ Posted by Ikjot Singh Dhody on 2023-08-20 + + + + + +
+ + +
+ +

Joining an MUC with Moxxy!

+
+ Posted by Ikjot Singh Dhody on 2023-07-24 + + + +

Greetings, readers!

+

Welcome back to our series of blogs on the Google Summer of Code (GSoC) project. In this blog post, I'll be sharing the progress made in implementing Multi-User Chat (MUC) support in Moxxy, the frontend counterpart to my GSoC project.

+ +
+
+ + +
+ +

XEP-0045 implementation in Moxxmpp

+
+ Posted by Ikjot Singh Dhody on 2023-06-17 + + + +

Hello readers!

+

Welcome back to the GSoC series of blogs. This one is about my implementation of the MUC XEP (XEP-0045) in Moxxmpp.

+ +
+
+ + +
+ +

Moxxy's First GSoC Project!

+
+ Posted by Ikjot Singh Dhody on 2023-05-06 + + + +

Hello readers!

+

As we know, Moxxy is an experimental IM for XMPP built using Flutter. While it does have a great set of features as described here, it currently lacks support for group chats (or Multi-User-Chats). A great piece of news is that Google has accepted my proposal to add support for multi user chats in Moxxy.

+ +
+
+ + +
+ +

Moxxy's New Website

+
+ Posted by PapaTutuWawa on 2023-01-24 + + + +

Hello everyone! Welcome on Moxxy's new website. It currently does not contain +much but that may change in the future.

+ +
+
+ +
+
+
+ +
+ + + + diff --git a/blog/join-muc-with-moxxy/index.html b/blog/join-muc-with-moxxy/index.html new file mode 100644 index 0000000..8537689 --- /dev/null +++ b/blog/join-muc-with-moxxy/index.html @@ -0,0 +1,119 @@ + + + + + + + + + + + + + Joining an MUC with Moxxy! + + + +
+
+
+ + + + + + + Moxxy + + + +
+ + Blog + Developers + Source +
+
+ + +
+
+

Joining an MUC with Moxxy!

+ Posted by Ikjot Singh Dhody on 2023-07-24 +
+

Greetings, readers!

+

Welcome back to our series of blogs on the Google Summer of Code (GSoC) project. In this blog post, I'll be sharing the progress made in implementing Multi-User Chat (MUC) support in Moxxy, the frontend counterpart to my GSoC project.

+

Introduction

+

As you may recall, Moxxy is a frontend application developed as an innovative XMPP client. To enhance its functionality, my GSoC project focuses on adding MUC support. Before diving into the Moxxy implementation, it was crucial to establish the necessary MUC support in Moxxmpp, which is highlighted in this blog.

+

Currently, the implementation progress is to allow users to join an MUC through Moxxy, and view incoming live messages in the chat.

+

Design Plan for MUC Support in Moxxy

+

To implement MUC support in Moxxy, we need to extend its functionality and introduce new components. Let's outline the design plan for the MUC feature:

+

New Page

+

JoinGroupchatPage

+

This page will contain just 1 text field - for the nickname that the user wants to join with. It also has a button that allows us to join the MUC with said nickname. It is an additional route to the current StartChat page, if the user selects that they want to join a groupchat.

+

New Command

+

JoinGroupchatCommand

+

This command is sent to the data layer worker (separate thread) from the UI, when the user clicks on the join groupchat button on the new join groupchat page. It contains information about the JID and the nick that the user tried to join with. This will only be sent to the worker thread if the input validations are cleared.

+

New Event

+

JoinGroupchatResult

+

This event is sent back as a result of the JoinGroupchatCommand. Based on whether the request succeeded or failed, it will return the new Conversation object that has just been created.

+

Database changes

+

GroupchatDetails table

+

Add a new GrouchatDetails table to the database containing two data items - the jid and the nick. The main reason to have a separate table for the groupchat details, instead of to just have a new nick item in the Conversation table - was to maintain the single responsibility principle.

+

When the user fetches a conversation of type groupchat from the database, a separate call will be made that fetches the relevant groupchat details from this new table, and attaches it to the Conversation object.

+

Miscellaneous changes

+
    +
  • +

    Changed the external helpers for the ConversationType to an enhanced enum. This allows us to include the functions within the enum.

    +
  • +
  • +

    The MUCManager was added to the list of registered managers for Moxxy. Not only this, the OccupantIdManager was also registered which will allow for the unique occupant identification moving forward. This will be required for message reactions/retractions in an MUC.

    +
  • +
+

New Service

+

GroupchatService

+

Added a new GroupchatService that allows for the following functions:

+
    +
  • getRoomInformation: Sends a request to moxxmpp to receive disco info about the MUC.
  • +
  • joinRoom: Sends a request to moxxmpp to join the MUC if it's not password protected.
  • +
  • addGroupchatDetailsFromData: Adds a new GroupchatDetails object to the database table.
  • +
  • getGroupchatDetailsByJid: Fetches the GroupchatDetails from the database based on the JID provided. This is required as a separate step while fetching an MUC conversation since the Conversations and GroupchatDetails table are decoupled.
  • +
+

Handling Errors

+

To prevent avoidable errors, Moxxy performs frontend checks when joining a room. These checks include ensuring to validate the JID input field, and checking for empty nicknames.

+

Possible errors that users may encounter during the MUC workflow include invalid or already in use nicknames, disallowed registration, invalid stanza format, and invalid disco info response. Moxxy will handle these errors gracefully.

+

Challenges and Considerations

+

Here is an enumeration of the possible challenges that we could face in the future implementation, and the ones I faced in the current implementation as well:

+
    +
  1. +

    Differentiating Messages from Oneself: Moxxy/Moxxmpp need to distinguish between messages from other users and self-echoed messages. To address this, Moxxy uses the origin ID of the message. If the origin ID of the response matches the sent origin ID, the message is ignored and not displayed in the UI.

    +
  2. +
  3. +

    Handling Impersonation in Anonymous MUCs: In anonymous MUCs, users can impersonate others by reusing their nicknames after leaving. To tackle this, Moxxmpp leverages the occupant ID, as described in XEP-0421. Each user joining the group receives a unique occupant ID, which helps track message origins accurately.

    +
  4. +
  5. +

    Managing Discussion History on Rejoining: When a user rejoins an MUC, the room history is resent, including errors, self-presence with status code, room history, room subject, and live message/presence updates. To prevent appending duplicate history to the UI, Moxxy/Moxxmpp will have to wait until it receives the room subject before listening for message stanzas.

    +
  6. +
+

Conclusion and Future Work

+

In this blog post, we explored the implementation plan for adding MUC support, specifically XEP-0045, to Moxxy. Moxxmpp serves as the backbone for Moxxy's XMPP functionality, handling communication between the client and XMPP server. We discussed the directory structure, and key routines required for MUC support in Moxxmpp. Additionally, we addressed various challenges and considerations related to MUC features.

+

The implementation process has already commenced, with a pull request (PR) underway. Once the PR is complete, Moxxy will support joining a groupchat and listening to live messages. In further PRs, sending messages and leaving the MUC will be supported as well. The addition of MUC support will empower Moxxy users to enjoy enhanced collaboration and communication within XMPP group chats.

+

Stay tuned for future updates on the progress of MUC support in Moxxy. Until then, happy chatting!

+ +
+
+
+ +
+ + + + diff --git a/blog/moxxy-muc-gsoc-final-report/index.html b/blog/moxxy-muc-gsoc-final-report/index.html new file mode 100644 index 0000000..26ed820 --- /dev/null +++ b/blog/moxxy-muc-gsoc-final-report/index.html @@ -0,0 +1,258 @@ + + + + + + + + + + + + + GSoC report - Moxxy MUC implementation + + + +
+
+
+ + + + + + + Moxxy + + + +
+ + Blog + Developers + Source +
+
+ + +
+
+

GSoC report - Moxxy MUC implementation

+ Posted by Ikjot Singh Dhody on 2023-08-20 +
+

GSoC Final Report: XMPP Standards Foundation - Moxxy: Implement Group Chats

+

Project: Moxxy - Implement Group Chats
+Organization: XMPP Standards Foundation
+Duration: March 2023 - August 2023
+Student: Ikjot Singh Dhody
+Mentor: Alexander

+

Introduction

+

This report presents the culmination of my work on the GSoC project "Moxxy: Implement Group Chats" under the mentorship of Alexander at the XMPP Standards Foundation. Over the course of this project, I have been engaged in implementing a group chat feature for the Moxxy application, aiming to enhance its functionality and user experience.

+

About Me

+

Personal and Social/Contact Details

+
    +
  • Name: Ikjot Singh Dhody
  • +
  • Jabber ID: ikjot-2605[at]jabber.fr
  • +
  • Email: ikjotsd[at]gmail.com
  • +
  • GitHub: ikjot-2605
  • +
  • LinkedIn: LinkedIn Profile
  • +
+

Educational Background

+
    +
  • University: National Institute of Technology Karnataka, Surathkal
  • +
  • Major: Computer Science and Engineering
  • +
  • Year: Senior Year
  • +
  • Degree: Bachelor of Technology (B. Tech)
  • +
+

The Project

+

Before getting into the details of the actual project - here is a demo screencast for the implementation:

+

+

I have outlined the features I implemented through the GSoC period below.

+

PRs merged

+ +

Feature Use-Cases

+

The group chat feature required changes to the Moxxy codebase, as well as the moxxmpp codebase. Moxxmpp is the data worker that sends and maintains all the request requirements of the Moxxy frontend. These are the list of contributions across both projects:

+
    +
  • Joining rooms and getting disco info for the room.
  • +
  • Sending messages to a group chat and receiving messages from the group chat.
  • +
  • Leaving the group chat.
  • +
  • Displaying a UI for joining a group chat and providing a nickname.
  • +
  • Handling group chat details and database support.
  • +
  • Handling group chat errors and basic error handling.
  • +
  • Adding a GroupchatDetails model.
  • +
  • Adding UI elements for group chat, such as title and nickname fields.
  • +
  • Adding documentation to group chat service methods.
  • +
  • Minor code refactoring and naming enhancements.
  • +
  • Enhancing enums for conversation types.
  • +
  • Removing unnecessary translation strings.
  • +
  • Improving UI and formatting.
  • +
+

Outlined below are commits made across both codebases throughout the GSoC period.

+

Moxxmpp

+

There were 2 PRs merged for this codebase.

+
    +
  • XEP-0421 support for occupant ID support.
  • +
+ + + + +
Serial NumberCommit HashDescription
1255d0f88e0feat(xep): Use cascading operation to return state
2fa11a3a384feat(xep): Checked for the occupant-id directly.
3ac5bb9e461feat(xep): Implement XEP 0421 in Moxxmpp.
+
    +
  • XEP-0045 support for MUC support.
  • +
+ + + + + + + + + + + + + + + + + + + + + +
Serial NumberCommit HashDescription
1b2724aba0cMerge branch 'master' into xep_0045
2d3742ea156feat(xep): Small fixes - MUC Example.
38b00e85167feat(xep): Add example for XEP 0045 Moxxmpp.
404dfc6d2acfeat(xep): Replace DiscoError with StanzaError.
59e70e802efMerge branch 'master' into xep_0045
63ebd9b86ecfeat(xep): Fix lint issues and use moxlib for result.
7a873edb9ecfeat(xep): Check for null nick before leaveRoom.
8e6bd6d05cdfeat(xep): Remove NOOP cache access.
9b7d53b8f47feat(xep): Add docstings for the XEP-0045 routines
10217c3ac236feat(xep): Fix cache issue with join/leaveRoom.
1151bca6c25dfeat(xep): XEP-0045 cache fixes.
128728166a4dfeat(xep): Add cache and roomstate to MUC implementation.
131f1321b269feat(xep): Small fixes - review cycle 1.
1466195f66faMerge branch 'master' into xep_0045
1570fdfaf16dfeat(xep): Fix imports for xep_0045 files.
16cd73f89e63feat(xep): Remove duplicate manager string
1705c41d3185feat(xep): Refactor sendMessage to allow groupchat
1864a8de6caafeat(xep): Set base for XEP 0045 implementation
1968809469f6feat(xep): Add joinRoom, leaveRoom routines.
20762cf1c77afeat(xep): Set base for XEP 0045 implementation
+

Moxxy

+
    +
  • Implement MUCs in Moxxy
  • +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Serial NumberCommit HashDescription
1549e61a168feat(all): Fix linter issues.
226bcaccd81Merge branch 'master' into feat/groupchat
3df5810a347feat(all): Formatting change, lock file update
4ef931c566ffeat(all): Send messages/chat state from Moxxy to MUC.
5a3d4883406feat(all): Remove unnecessary buttons/options for MUC.
6532f0b1bb2feat(all): Formatting fix, and navigation fix.
7a98fe0d9f3feat(all): Minor fixes - strings, formatting.
8a7c3bd507fMerge branch 'master' of https://codeberg.org/moxxy/moxxy into feat/groupchat
9fba2cf86aefeat(all): Minor formatting changes.
10af481bf465feat(all): remove unnecessary comparator override.
11e6ae8182c2feat(all): Organize import in main.dart.
12de7b9adfa6feat(all): Fix user flow for joining MUC.
13e4f98bb82ffeat(all): Add label to nick text field.
1456d6f97168feat(all): Minor changes, fixes.
15b0067f055ffeat(all): Move away from exception type design.
16bd094dfc9afeat(all): Remove unnecessary function.
177e9d7d6281feat(all): Check if Groupchat exists before method.
182cf781459dfeat(all): Debug mode and translatable string
194ff9e3c81efeat(all): Remove title from GroupchatDetails.
20e337f1c579feat(all): Minor refactors - naming.
217c840334e1feat(all): Add docs to groupchat service methods.
2206eab1d6f5feat(all): Make ConversationType an enhanced enum.
23008e816d70feat(all): Rename JoinGroupchatResultEvent.
242bbbc164b5feat(all): Remove incorrect translations.
2511f4fd9932feat(all): Add title to GroupchatDetails.
26a1451c6fbffeat(all): Refactor groupchat to new object in db.
27993da40297feat(all): Complete join groupchat flow.
2809684b1268feat(all): Fix fromDatabaseJson for MUC details.
290abb89cf38feat(all): Fix database issues with nick.
307880f51b76feat(all): Add db support for GroupchatDetails.
31f0a79ca0e0feat(all): Add GroupchatDetails model.
3206dcd5491bfeat(all): Basic groupchat error handling set up.
333641be4f56feat(all): Join room functionality complete.
3418e28c3bbffeat(all): Groupchat service/bloc updated.
3562e39bf066feat(all): Set base for groupchat implementation.
+

Accomplishments

+
    +
  • +

    Was able to produce a working model of groupchats in Moxxy.

    +
  • +
  • +

    Started the design approach from scratch and pretty much stuck to it till the end gave me confidence in my design capability.

    +
  • +
  • +

    Fruitful discussions and review cycles were conducted that allowed for a smooth GSoC experience.

    +
  • +
+

Challenges Faced

+
    +
  • +

    Needed to understand 2 different codebases, and the architecture of the project. This was a pretty interesting, albeit challenging task that took me a while to master.

    +
  • +
  • +

    Managing the busy schedule with GSoC work, family, college among other things was difficult. Also, managing a job in the latter parts was also challenging but a rewarding experience.

    +
  • +
  • +

    The complete virtual approach was slightly difficult, and although not practical - it might have been slightly better with inter-GSoC meetings.

    +
  • +
+

Learnings/Takeaways

+
    +
  • Implemented group chat (Multi-User Chat or MUC) support in the Moxxy project.
  • +
  • Successfully added features for joining a group chat room, sending messages to the room, and receiving messages from the room.
  • +
  • Learned to handle various aspects of XMPP communication, including sending and receiving messages, and interacting with group chat services.
  • +
  • Gained insights into implementing complex functionality in a Flutter application, involving UI components, service classes, and database interactions.
  • +
  • Collaborated with experienced developers through code reviews to improve code quality and ensure adherence to best practices.
  • +
  • Acquired knowledge of working with the XMPP protocol, understanding its intricacies and how it relates to group chat interactions.
  • +
  • Learned to manage and address feedback from code reviewers, making necessary adjustments to improve code readability and functionality.
  • +
  • Discovered the importance of proper error handling in real-time communication scenarios, such as handling different types of group chat errors.
  • +
  • Gained experience in integrating new features while maintaining the overall architecture and user experience of the application.
  • +
  • Understood the complexities of XMPP server behavior, including handling discussion history and preventing message loops.
  • +
  • Explored techniques for optimizing communication performance, such as preventing redundant message processing.
  • +
  • Improved skills in project management, including version control practices, managing branches, and resolving merge conflicts.
  • +
  • Gained familiarity with the process of creating, testing, and merging pull requests in a collaborative development environment.
  • +
  • Developed a better understanding of Flutter's state management, navigation, and widget composition for creating feature-rich user interfaces.
  • +
  • Learned to balance feature development with code quality, addressing both functional and non-functional aspects of the implementation.
  • +
  • Explored advanced Flutter topics, such as handling asynchronous operations, managing state, and integrating with external libraries.
  • +
  • Gained a deeper understanding of how group chat and real-time communication play a significant role in modern applications.
  • +
  • Developed the ability to diagnose and troubleshoot issues related to communication and user interface interactions.
  • +
  • Strengthened communication skills by participating in technical discussions and effectively conveying ideas and solutions.
  • +
+

Future Work

+

The future remaining work has been enlisted in this issue by my mentor here.

+

This includes a list of improvements, bug fixes and general future requirements that will be needed to make the groupchat experience pleasurable for the users of Moxxy.

+

Conclusion

+

Participating in GSoC has been an enriching experience. I've learned valuable skills, collaborated with mentors and the open-source community, and contributed to the Moxxy project. I'm grateful to XMPP Standards Foundation for this opportunity and look forward to continuing my journey in the world of open-source software development.

+

Acknowledgments

+

I would like to express my gratitude to my mentor Alexander for their guidance and support throughout this project. His guidance and understanding is what allowed me to pull through and complete the GSoC with a happy mind. I also want to thank the XMPP Standards Foundation community for their encouragement and feedback.

+ +
+
+
+ +
+ + + + diff --git a/blog/moxxy-muc-gsoc-final-report/moxxy-muc-demo.gif b/blog/moxxy-muc-gsoc-final-report/moxxy-muc-demo.gif new file mode 100644 index 0000000..cd6b772 Binary files /dev/null and b/blog/moxxy-muc-gsoc-final-report/moxxy-muc-demo.gif differ diff --git a/blog/moxxys-new-website/index.html b/blog/moxxys-new-website/index.html new file mode 100644 index 0000000..46bb9ca --- /dev/null +++ b/blog/moxxys-new-website/index.html @@ -0,0 +1,66 @@ + + + + + + + + + + + + + Moxxy's New Website + + + +
+
+
+ + + + + + + Moxxy + + + +
+ + Blog + Developers + Source +
+
+ + +
+
+

Moxxy's New Website

+ Posted by PapaTutuWawa on 2023-01-24 +
+

Hello everyone! Welcome on Moxxy's new website. It currently does not contain +much but that may change in the future.

+ +

The page is built using Jekyll and TailwindCSS. You can find the page's +source here.

+ +
+
+
+ +
+ + + + diff --git a/blog/xep-0045-in-moxxmpp/index.html b/blog/xep-0045-in-moxxmpp/index.html new file mode 100644 index 0000000..4a18d74 --- /dev/null +++ b/blog/xep-0045-in-moxxmpp/index.html @@ -0,0 +1,249 @@ + + + + + + + + + + + + + XEP-0045 implementation in Moxxmpp + + + +
+
+
+ + + + + + + Moxxy + + + +
+ + Blog + Developers + Source +
+
+ + +
+
+

XEP-0045 implementation in Moxxmpp

+ Posted by Ikjot Singh Dhody on 2023-06-17 +
+

Hello readers!

+

Welcome back to the GSoC series of blogs. This one is about my implementation of the MUC XEP (XEP-0045) in Moxxmpp.

+

Introduction

+

Well, as you probably know, Moxxy is the frontend app that is being developed as a modern new XMPP client.

+

Moxxmpp is a Dart package that is used by Moxxy for multiple XMPP services. Essentially, the conversation between Moxxy and the XMPP server is handled by Moxxmpp. It is like the middleman that helps ease the communication between the two, keeping Moxxy code clean and free from the intricacies it handles.

+

Since my GSoC project is all about adding MUC support to Moxxy, it was essential to first add the required support in Moxxmpp before proceeding to Moxxy. This blog will give you an idea of what the responsibilities of Moxxmpp are, and why it was important to separate it from Moxxy.

+

What is Moxxmpp?

+

In the words of it's developer, Moxxmpp is "a pure-Dart XMPP library". Moxxmpp could be thought of as the backbone of Moxxy. The entire communication/networking part of Moxxy, i.e. how it (as a client) communicates with the user's XMPP server is outsourced to this Dart library.

+

Not only this, used as per it's rules - Moxxmpp could be used by any client to perform XMPP tasks that are currently supported by it. It is a re-usable and versatile XMPP library.

+

Listed below are some of it's core responsibilities:

+
    +
  1. +

    Establishing the connection between the client and the XMPP server via the user's JID and password.

    +
  2. +
  3. +

    Allowing Moxxy/any front-end client to register managers that provide support for a particular XEP/part of the XMPP flow. For example: the messaging service is handled by a MessageManager. +Similarly here are some other managers with their use:

    +
      +
    1. PresenceManager: Handling the presence related stanzas/use.
    2. +
    3. PubSubManager: Provides support for XEP-0060.
    4. +
    5. DiscoManager: Provides support for the service discovery: XEP-0030.
    6. +
    7. RosterManager: Handling roster related tasks.
    8. +
    9. BlockingManager: For blocking related tasks.
    10. +
    +

    As of June 17 2023, there are 35 such managers and 35 XEPs supported in Moxxmpp.

    +
  4. +
  5. +

    Managing cache: Moxxmpp manages cache of common requests, such as service discovery requests. If a request is duplicated, the result is provided from the cache - saving bandwidth and time.

    +
  6. +
+

As explained below, new XEP support is related to adding new managers to Moxxmpp and I will be doing the same for XEP-0045 support in Moxxy. My design plan is elaborated in the next section.

+

Here is my implementation plan for adding XEP-0045 support to Moxxmpp.

+

GSoC Moxxmpp Implementation Design Plan

+

Directory Structure

+
    +
  • xep_0045 +
      +
    • errors.dart
    • +
    • helpers.dart
    • +
    • types.dart
    • +
    • xep_0045.dart
    • +
    +
  • +
  • Here, the errors.dart file will contain the abstract classes for different errors that one could get whilst going through all the lifecycle use-cases of the MUC feature.
  • +
  • The helpers.dart file will have some helper functions to maintain (DRY code avoiding repetition) and (modularized code).
  • +
  • types.dart will contain model classes for the events and other entities.
  • +
  • The xep_0045.dart is the main file which will contain the exposed routines as shown below, as well as the incoming stanza handlers.
  • +
+

Phase 1 - Query Room Information

+

Future<Result<RoomInformation,MUCError>> queryRoomInformation(JID roomJID)

+

This routine will allow the users to view the features of the room. These will include whether the room is open, moderated, password protected, etc. All this will be stored in a RoomInformation object and sent back as a Result object. It is important to note that the MUC server's address (for the 'to' attribute) will be parsed from the latter half of the room JID (the part post the '@').

+

The parameters of the RoomInformation class will be represented in the following way:

+
    +
  1. JID roomJID
  2. +
  3. List<String> feature_list
  4. +
+

Phase 2 - Join/Leave Room(Handle errors)

+

To join/leave a room we can send an appropriate presence stanza that will handle the same for us. So we will have two simple routines for the same as well.

+

Routines

+

Future<Result>bool, MUCError>> joinRoom(JID roomJID)

+

This routine will send a presence stanza to the MUC server asking it to join the server. It takes the roomJID as a parameter that will essentially contain the bare JID as well as the nickname (prompted from the user) as the resource. This will be preceded by the queryRoomInformation() routine call to obtain necessary information about the room, for example: if the room is password protected (in which case the user will see a not-implemented error dialog till a time it is supported).

+

Important to note is that the user's nickname will be used as the 'resource' in the roomJID sent by the frontend. This is because the 'to' attribute of a presence stanza to join a room looks as such - {local/MUC}@{domain/chat server}/{nickname}.

+

Future<Result<bool, MUCError>> leaveRoom(JID roomJID)

+

Similarly this is a routine to allow for leaving the room with a presence stanza.

+

The boolean return type is just to allow for a simple return object with the Result type. We could move forward with a simple Future as well, but for the sake of consistency - maybe sticking to the former is better.

+

Phase 3 - Refactor sendMessage to handle MUCs

+

To be able to send messages to groupchats/MUCs, the main requirement is to be able to change the type attribute in the message stanzas from chat to groupchat. This can be done in one of two ways. The first way will be to change the sendMessage routine's description to include a type parameter that will simply transfer over to the stanza that will be sent from moxxmpp as a string. Another was is described below, where a new extension called ConversationTypeData will be added to the StanzaHandlerExtension object whilst calling the sendMessage routine. The former solution is simpler and will most probably be implemented. The design for both these possibilities is listed below.

+

Solution 1

+

The sendMessage routine will transform from

+
Future<void> sendMessage(
+  JID to,
+  TypedMap<StanzaHandlerExtension> extensions,
+) async {
+  await getAttributes().sendStanza(
+    StanzaDetails(
+      Stanza.message(
+        to: to.toString(),
+        id: extensions.get<MessageIdData>()?.id,
+        type: 'chat',
+        children: _messageSendingCallbacks
+            .map((c) => c(extensions))
+            .flattened
+            .toList(),
+      ),
+      awaitable: false,
+    ),
+  );
+}
+
+

to

+
Future<void> sendMessage(
+  JID to,
+  TypedMap<StanzaHandlerExtension> extensions,
+  String type,
+) async {
+  await getAttributes().sendStanza(
+    StanzaDetails(
+      Stanza.message(
+        to: to.toString(),
+        id: extensions.get<MessageIdData>()?.id,
+        type: type,
+        children: _messageSendingCallbacks
+            .map((c) => c(extensions))
+            .flattened
+            .toList(),
+      ),
+      awaitable: false,
+    ),
+  );
+}
+
+

Solution 2

+
enum ConversationType { 
+    chat, groupchat, groupchatprivate 
+}
+
+

The ConversationTypeData class essentially will act as a wrapper over the above enum.

+

Hence the new type attribute value will be:

+
extensions.get<ConversationTypeData>()?.conversationType ==
+                  ConversationType.groupchat
+              ? 'groupchat'
+              : 'chat',
+
+

Here, ConversationTypeData is a simple wrapper over ConversationType so that it can be recognized as a subclass of the StanzaHandlerExtensions class.

+

For private MUC messages to a single participant, the type attribute of the message stanza should be set to chat. This can be handled very easily in case of either solution implementation.

+
+

For MUC messages with a stanza reflecting a chat server (type: 'groupchat'), the type in the MessageEvent will be set to 'groupchat' automatically. The rest will be handled similarly to 1:1 chats.

+

Phase 4 - Miscellaneous requirements

+

Some of the miscellaneous requirements from Moxxmpp could include viewing member list, group subject, change availability status, and more. +For now, I have identified the below as the most crucial requirements for the Moxxmpp feature additions for MUC.

+

Below are the use-cases and how they are planned to be handled:

+
    +
  1. Get member list
  2. +
+

After one joins a room, the user receives a presence from all the connected users to the chat. The best way to get the member list is to capture/handle the incoming presence stanzas and send an appropriate MUCPresenceReceived event to the UI.

+

This way, whenever a user joins a room, they can see the current member list, and on subsequent presence updates, also change that list.

+
    +
  1. Handling the room subject
  2. +
+

This is a very simple usecase. When a disco info query about the MUC goes out to the XMPP server, the response contains an identity node containing the chat name. This would be the best way to extract the rom subject. As of now, the queryRoomInformation routine will be triggered from the UI and the response will be sent to the same. This will be encapsulated in a simple RoomInformation class which is now updated as follows:

+
    +
  1. JID roomJID
  2. +
  3. List<String> feature_list
  4. +
  5. String name
  6. +
+

Note: Changing your status seemed like a task that would be slighlty out of scope for the project duration, so that is kept as a stretch goal for now.

+

Errors

+

Frontend checks while joining a room to prevent avoidable errors:

+
    +
  • Nickname must be specified in accordance with the rules of the XEP - to prevent the no nickname specified error.
  • +
  • Validations for JID input field.
  • +
  • Validation for checking empty nickname.
  • +
+

Some of the possible errors that can be faced by the user in an MUC workflow are:

+
    +
  • Invalid/Already in use nickname
  • +
  • Not allowed to register
  • +
  • Invalid stanza format
  • +
  • Invalid Disco Info Response: In case of some rare edge cases (not handled currently) where the response does not contain some information like the room name, or the features of the room.
  • +
+

Challenges noted

+

Some challenges/room for error were noted along the way. They are enumerated below:

+
    +
  1. +

    How will Moxxy/Moxxmpp handle messages from oneself?

    +

    When a user sends a message on the MUC, they receive the message themselves as well. How will moxxmpp/moxxy differentiate between other live messages and this echoed message?

    +

    The solution to this problem is to use the origin-id of the message. If the origin-id of the response matches with the sent origin-id, then the message is to be ignored and not shown in the UI.

    +
  2. +
  3. +

    In anonymous MUCs, one can easily act as someone else by using their nickname once they leave. How will this be handled?

    +

    This is fixed by using the occupant-id property as described in XEP-0421. A user (with their unique JID) when joins the group, is assigned a unique occupant-id, which can be used to actually track which message is from which user.

    +

    This makes the implementation of reactions/retractions simpler.

    +
  4. +
  5. +

    How will discussion history (sent on joining an MUC) be handled when someone rejoins an MUC?

    +

    When a user joins a MUC, they are sent a set of stanzas in the following order:

    +
     1. Errors (if any)
    + 2. Self presence with status code
    + 3. Room history
    + 4. Room subject
    + 5. Live message/presence updates
    +
    +

    Now, when a user gets disconnected from an MUC and joins again, then the room history will be sent again as well. To prevent this history from getting appended to the conversation in the UI, we will need to wait till we receive the room subject and only then start listening for message stanzas (since room subject is sent after room history).

    +
  6. +
+

Conclusion and future work

+

In conclusion, this blog post discussed the implementation plan for adding Multi-User Chat (MUC) support, specifically XEP-0045, to Moxxmpp. Moxxmpp serves as the backbone for the Moxxy XMPP client, handling the communication between the client and XMPP server. The blog outlined the directory structure, design plan, and key routines for implementing the MUC support in Moxxmpp. It also addressed some challenges and considerations related to handling MUC features.

+

Implementation for this has begun, and a PR is already underway. Once this PR is completed, then work will begin on the front-end and the changes will be integrated into Moxxy.

+ +
+
+
+ +
+ + + + diff --git a/css/.gitkeep b/css/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/css/index.css b/css/index.css new file mode 100644 index 0000000..923005a --- /dev/null +++ b/css/index.css @@ -0,0 +1 @@ +/*! tailwindcss v3.4.1 | MIT License | https://tailwindcss.com*/*,:after,:before{box-sizing:border-box;border:0 solid #e5e7eb}:after,:before{--tw-content:""}:host,html{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-family:ui-sans-serif,system-ui,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;font-feature-settings:normal;font-variation-settings:normal;-webkit-tap-highlight-color:transparent}body{margin:0;line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,pre,samp{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-feature-settings:normal;font-variation-settings:normal;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:initial}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,textarea{font-family:inherit;font-feature-settings:inherit;font-variation-settings:inherit;font-size:100%;font-weight:inherit;line-height:inherit;color:inherit;margin:0;padding:0}button,select{text-transform:none}[type=button],[type=reset],[type=submit],button{-webkit-appearance:button;background-color:initial;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:initial}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dd,dl,figure,h1,h2,h3,h4,h5,h6,hr,p,pre{margin:0}fieldset{margin:0}fieldset,legend{padding:0}menu,ol,ul{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{opacity:1;color:#9ca3af}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}[role=button],button{cursor:pointer}:disabled{cursor:default}audio,canvas,embed,iframe,img,object,svg,video{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}[hidden]{display:none}article>p>a{--tw-text-opacity:1!important;color:rgb(56 189 248/var(--tw-text-opacity))!important}*,::backdrop,:after,:before{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:#3b82f680;--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }.prose{color:var(--tw-prose-body);max-width:65ch}.prose :where(p):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.25em;margin-bottom:1.25em}.prose :where([class~=lead]):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-lead);font-size:1.25em;line-height:1.6;margin-top:1.2em;margin-bottom:1.2em}.prose :where(a):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-links);text-decoration:underline;font-weight:500}.prose :where(strong):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-bold);font-weight:600}.prose :where(a strong):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(blockquote strong):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(thead th strong):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(ol):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:decimal;margin-top:1.25em;margin-bottom:1.25em;padding-left:1.625em}.prose :where(ol[type=A]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:upper-alpha}.prose :where(ol[type=a]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:lower-alpha}.prose :where(ol[type=A s]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:upper-alpha}.prose :where(ol[type=a s]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:lower-alpha}.prose :where(ol[type=I]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:upper-roman}.prose :where(ol[type=i]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:lower-roman}.prose :where(ol[type=I s]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:upper-roman}.prose :where(ol[type=i s]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:lower-roman}.prose :where(ol[type="1"]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:decimal}.prose :where(ul):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:disc;margin-top:1.25em;margin-bottom:1.25em;padding-left:1.625em}.prose :where(ol>li):not(:where([class~=not-prose],[class~=not-prose] *))::marker{font-weight:400;color:var(--tw-prose-counters)}.prose :where(ul>li):not(:where([class~=not-prose],[class~=not-prose] *))::marker{color:var(--tw-prose-bullets)}.prose :where(dt):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:600;margin-top:1.25em}.prose :where(hr):not(:where([class~=not-prose],[class~=not-prose] *)){border-color:var(--tw-prose-hr);border-top-width:1px;margin-top:3em;margin-bottom:3em}.prose :where(blockquote):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:500;font-style:italic;color:var(--tw-prose-quotes);border-left-width:.25rem;border-left-color:var(--tw-prose-quote-borders);quotes:"\201C""\201D""\2018""\2019";margin-top:1.6em;margin-bottom:1.6em;padding-left:1em}.prose :where(blockquote p:first-of-type):not(:where([class~=not-prose],[class~=not-prose] *)):before{content:open-quote}.prose :where(blockquote p:last-of-type):not(:where([class~=not-prose],[class~=not-prose] *)):after{content:close-quote}.prose :where(h1):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:800;font-size:2.25em;margin-top:0;margin-bottom:.8888889em;line-height:1.1111111}.prose :where(h1 strong):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:900;color:inherit}.prose :where(h2):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:700;font-size:1.5em;margin-top:2em;margin-bottom:1em;line-height:1.3333333}.prose :where(h2 strong):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:800;color:inherit}.prose :where(h3):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:600;font-size:1.25em;margin-top:1.6em;margin-bottom:.6em;line-height:1.6}.prose :where(h3 strong):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:700;color:inherit}.prose :where(h4):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:600;margin-top:1.5em;margin-bottom:.5em;line-height:1.5}.prose :where(h4 strong):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:700;color:inherit}.prose :where(img):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:2em;margin-bottom:2em}.prose :where(picture):not(:where([class~=not-prose],[class~=not-prose] *)){display:block;margin-top:2em;margin-bottom:2em}.prose :where(kbd):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:500;font-family:inherit;color:var(--tw-prose-kbd);box-shadow:0 0 0 1px rgb(var(--tw-prose-kbd-shadows)/10%),0 3px 0 rgb(var(--tw-prose-kbd-shadows)/10%);font-size:.875em;border-radius:.3125rem;padding:.1875em .375em}.prose :where(code):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-code);font-weight:600;font-size:.875em}.prose :where(code):not(:where([class~=not-prose],[class~=not-prose] *)):before{content:"`"}.prose :where(code):not(:where([class~=not-prose],[class~=not-prose] *)):after{content:"`"}.prose :where(a code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(h1 code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(h2 code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit;font-size:.875em}.prose :where(h3 code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit;font-size:.9em}.prose :where(h4 code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(blockquote code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(thead th code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(pre):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-pre-code);background-color:var(--tw-prose-pre-bg);overflow-x:auto;font-weight:400;font-size:.875em;line-height:1.7142857;margin-top:1.7142857em;margin-bottom:1.7142857em;border-radius:.375rem;padding:.8571429em 1.1428571em}.prose :where(pre code):not(:where([class~=not-prose],[class~=not-prose] *)){background-color:initial;border-width:0;border-radius:0;padding:0;font-weight:inherit;color:inherit;font-size:inherit;font-family:inherit;line-height:inherit}.prose :where(pre code):not(:where([class~=not-prose],[class~=not-prose] *)):before{content:none}.prose :where(pre code):not(:where([class~=not-prose],[class~=not-prose] *)):after{content:none}.prose :where(table):not(:where([class~=not-prose],[class~=not-prose] *)){width:100%;table-layout:auto;text-align:left;margin-top:2em;margin-bottom:2em;font-size:.875em;line-height:1.7142857}.prose :where(thead):not(:where([class~=not-prose],[class~=not-prose] *)){border-bottom-width:1px;border-bottom-color:var(--tw-prose-th-borders)}.prose :where(thead th):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:600;vertical-align:bottom;padding-right:.5714286em;padding-bottom:.5714286em;padding-left:.5714286em}.prose :where(tbody tr):not(:where([class~=not-prose],[class~=not-prose] *)){border-bottom-width:1px;border-bottom-color:var(--tw-prose-td-borders)}.prose :where(tbody tr:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){border-bottom-width:0}.prose :where(tbody td):not(:where([class~=not-prose],[class~=not-prose] *)){vertical-align:initial}.prose :where(tfoot):not(:where([class~=not-prose],[class~=not-prose] *)){border-top-width:1px;border-top-color:var(--tw-prose-th-borders)}.prose :where(tfoot td):not(:where([class~=not-prose],[class~=not-prose] *)){vertical-align:top}.prose :where(figure>*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0;margin-bottom:0}.prose :where(figcaption):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-captions);font-size:.875em;line-height:1.4285714;margin-top:.8571429em}.prose{--tw-prose-body:#374151;--tw-prose-headings:#111827;--tw-prose-lead:#4b5563;--tw-prose-links:#111827;--tw-prose-bold:#111827;--tw-prose-counters:#6b7280;--tw-prose-bullets:#d1d5db;--tw-prose-hr:#e5e7eb;--tw-prose-quotes:#111827;--tw-prose-quote-borders:#e5e7eb;--tw-prose-captions:#6b7280;--tw-prose-kbd:#111827;--tw-prose-kbd-shadows:17 24 39;--tw-prose-code:#111827;--tw-prose-pre-code:#e5e7eb;--tw-prose-pre-bg:#1f2937;--tw-prose-th-borders:#d1d5db;--tw-prose-td-borders:#e5e7eb;--tw-prose-invert-body:#d1d5db;--tw-prose-invert-headings:#fff;--tw-prose-invert-lead:#9ca3af;--tw-prose-invert-links:#fff;--tw-prose-invert-bold:#fff;--tw-prose-invert-counters:#9ca3af;--tw-prose-invert-bullets:#4b5563;--tw-prose-invert-hr:#374151;--tw-prose-invert-quotes:#f3f4f6;--tw-prose-invert-quote-borders:#374151;--tw-prose-invert-captions:#9ca3af;--tw-prose-invert-kbd:#fff;--tw-prose-invert-kbd-shadows:255 255 255;--tw-prose-invert-code:#fff;--tw-prose-invert-pre-code:#d1d5db;--tw-prose-invert-pre-bg:#00000080;--tw-prose-invert-th-borders:#4b5563;--tw-prose-invert-td-borders:#374151;font-size:1rem;line-height:1.75}.prose :where(picture>img):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0;margin-bottom:0}.prose :where(video):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:2em;margin-bottom:2em}.prose :where(li):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.5em;margin-bottom:.5em}.prose :where(ol>li):not(:where([class~=not-prose],[class~=not-prose] *)){padding-left:.375em}.prose :where(ul>li):not(:where([class~=not-prose],[class~=not-prose] *)){padding-left:.375em}.prose :where(.prose>ul>li p):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.75em;margin-bottom:.75em}.prose :where(.prose>ul>li>:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.25em}.prose :where(.prose>ul>li>:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:1.25em}.prose :where(.prose>ol>li>:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.25em}.prose :where(.prose>ol>li>:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:1.25em}.prose :where(ul ul,ul ol,ol ul,ol ol):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.75em;margin-bottom:.75em}.prose :where(dl):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.25em;margin-bottom:1.25em}.prose :where(dd):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.5em;padding-left:1.625em}.prose :where(hr+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose :where(h2+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose :where(h3+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose :where(h4+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose :where(thead th:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-left:0}.prose :where(thead th:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-right:0}.prose :where(tbody td,tfoot td):not(:where([class~=not-prose],[class~=not-prose] *)){padding:.5714286em}.prose :where(tbody td:first-child,tfoot td:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-left:0}.prose :where(tbody td:last-child,tfoot td:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-right:0}.prose :where(figure):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:2em;margin-bottom:2em}.prose :where(.prose>:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose :where(.prose>:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:0}.prose-lg{font-size:1.125rem;line-height:1.7777778}.prose-lg :where(p):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.3333333em;margin-bottom:1.3333333em}.prose-lg :where([class~=lead]):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:1.2222222em;line-height:1.4545455;margin-top:1.0909091em;margin-bottom:1.0909091em}.prose-lg :where(blockquote):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.6666667em;margin-bottom:1.6666667em;padding-left:1em}.prose-lg :where(h1):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:2.6666667em;margin-top:0;margin-bottom:.8333333em;line-height:1}.prose-lg :where(h2):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:1.6666667em;margin-top:1.8666667em;margin-bottom:1.0666667em;line-height:1.3333333}.prose-lg :where(h3):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:1.3333333em;margin-top:1.6666667em;margin-bottom:.6666667em;line-height:1.5}.prose-lg :where(h4):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.7777778em;margin-bottom:.4444444em;line-height:1.5555556}.prose-lg :where(img):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.7777778em;margin-bottom:1.7777778em}.prose-lg :where(picture):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.7777778em;margin-bottom:1.7777778em}.prose-lg :where(picture>img):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0;margin-bottom:0}.prose-lg :where(video):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.7777778em;margin-bottom:1.7777778em}.prose-lg :where(kbd):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8888889em;border-radius:.3125rem;padding:.2222222em .4444444em}.prose-lg :where(code):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8888889em}.prose-lg :where(h2 code):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8666667em}.prose-lg :where(h3 code):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.875em}.prose-lg :where(pre):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8888889em;line-height:1.75;margin-top:2em;margin-bottom:2em;border-radius:.375rem;padding:1em 1.5em}.prose-lg :where(ol):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.3333333em;margin-bottom:1.3333333em;padding-left:1.5555556em}.prose-lg :where(ul):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.3333333em;margin-bottom:1.3333333em;padding-left:1.5555556em}.prose-lg :where(li):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.6666667em;margin-bottom:.6666667em}.prose-lg :where(ol>li):not(:where([class~=not-prose],[class~=not-prose] *)){padding-left:.4444444em}.prose-lg :where(ul>li):not(:where([class~=not-prose],[class~=not-prose] *)){padding-left:.4444444em}.prose-lg :where(.prose-lg>ul>li p):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.8888889em;margin-bottom:.8888889em}.prose-lg :where(.prose-lg>ul>li>:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.3333333em}.prose-lg :where(.prose-lg>ul>li>:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:1.3333333em}.prose-lg :where(.prose-lg>ol>li>:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.3333333em}.prose-lg :where(.prose-lg>ol>li>:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:1.3333333em}.prose-lg :where(ul ul,ul ol,ol ul,ol ol):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.8888889em;margin-bottom:.8888889em}.prose-lg :where(dl):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.3333333em;margin-bottom:1.3333333em}.prose-lg :where(dt):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.3333333em}.prose-lg :where(dd):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.6666667em;padding-left:1.5555556em}.prose-lg :where(hr):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:3.1111111em;margin-bottom:3.1111111em}.prose-lg :where(hr+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose-lg :where(h2+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose-lg :where(h3+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose-lg :where(h4+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose-lg :where(table):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8888889em;line-height:1.5}.prose-lg :where(thead th):not(:where([class~=not-prose],[class~=not-prose] *)){padding-right:.75em;padding-bottom:.75em;padding-left:.75em}.prose-lg :where(thead th:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-left:0}.prose-lg :where(thead th:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-right:0}.prose-lg :where(tbody td,tfoot td):not(:where([class~=not-prose],[class~=not-prose] *)){padding:.75em}.prose-lg :where(tbody td:first-child,tfoot td:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-left:0}.prose-lg :where(tbody td:last-child,tfoot td:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-right:0}.prose-lg :where(figure):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.7777778em;margin-bottom:1.7777778em}.prose-lg :where(figure>*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0;margin-bottom:0}.prose-lg :where(figcaption):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8888889em;line-height:1.5;margin-top:1em}.prose-lg :where(.prose-lg>:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose-lg :where(.prose-lg>:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:0}.relative{position:relative}.inset-x-0{left:0;right:0}.inset-y-0{top:0;bottom:0}.mx-auto{margin-left:auto;margin-right:auto}.mt-2{margin-top:.5rem}.mt-4{margin-top:1rem}.mt-5{margin-top:1.25rem}.block{display:block}.flex{display:flex}.table{display:table}.grid{display:grid}.h-12{height:3rem}.h-16{height:4rem}.h-24{height:6rem}.h-6{height:1.5rem}.h-64{height:16rem}.h-8{height:2rem}.h-96{height:24rem}.h-fit{height:-moz-fit-content;height:fit-content}.w-12{width:3rem}.w-6{width:1.5rem}.w-full{width:100%}.grow{flex-grow:1}.table-fixed{table-layout:fixed}.list-disc{list-style-type:disc}.grid-cols-1{grid-template-columns:repeat(1,minmax(0,1fr))}.grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.grid-rows-1{grid-template-rows:repeat(1,minmax(0,1fr))}.flex-row{flex-direction:row}.flex-col{flex-direction:column}.flex-wrap{flex-wrap:wrap}.flex-nowrap{flex-wrap:nowrap}.place-items-center{place-items:center}.items-start{align-items:flex-start}.items-center{align-items:center}.justify-center{justify-content:center}.gap-4{gap:1rem}.gap-8{gap:2rem}.gap-x-3{-moz-column-gap:.75rem;column-gap:.75rem}.divide-y>:not([hidden])~:not([hidden]){--tw-divide-y-reverse:0;border-top-width:calc(1px*(1 - var(--tw-divide-y-reverse)));border-bottom-width:calc(1px*var(--tw-divide-y-reverse))}.divide-blue-200>:not([hidden])~:not([hidden]){--tw-divide-opacity:1;border-color:rgb(191 219 254/var(--tw-divide-opacity))}.place-self-start{place-self:start}.overflow-scroll{overflow:scroll}.rounded-md{border-radius:.375rem}.bg-gray-100{--tw-bg-opacity:1;background-color:rgb(243 244 246/var(--tw-bg-opacity))}.bg-moxxy-purple{--tw-bg-opacity:1;background-color:rgb(207 74 255/var(--tw-bg-opacity))}.p-2{padding:.5rem}.p-8{padding:2rem}.px-1{padding-left:.25rem;padding-right:.25rem}.px-2{padding-left:.5rem;padding-right:.5rem}.px-4{padding-left:1rem;padding-right:1rem}.px-8{padding-left:2rem;padding-right:2rem}.pb-4{padding-bottom:1rem}.pr-4{padding-right:1rem}.pt-1{padding-top:.25rem}.pt-4{padding-top:1rem}.text-left{text-align:left}.text-center{text-align:center}.text-2xl{font-size:1.5rem;line-height:2rem}.text-3xl{font-size:1.875rem;line-height:2.25rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xl{font-size:1.25rem;line-height:1.75rem}.font-bold{font-weight:700}.italic{font-style:italic}.text-indigo-400{--tw-text-opacity:1;color:rgb(129 140 248/var(--tw-text-opacity))}.text-neutral-100{--tw-text-opacity:1;color:rgb(245 245 245/var(--tw-text-opacity))}.text-sky-400{--tw-text-opacity:1;color:rgb(56 189 248/var(--tw-text-opacity))}.shadow-md{--tw-shadow:0 4px 6px -1px #0000001a,0 2px 4px -2px #0000001a;--tw-shadow-colored:0 4px 6px -1px var(--tw-shadow-color),0 2px 4px -2px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}@media (min-width:1024px){.lg\:prose-lg{font-size:1.125rem;line-height:1.7777778}.lg\:prose-lg :where(p):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.3333333em;margin-bottom:1.3333333em}.lg\:prose-lg :where([class~=lead]):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:1.2222222em;line-height:1.4545455;margin-top:1.0909091em;margin-bottom:1.0909091em}.lg\:prose-lg :where(blockquote):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.6666667em;margin-bottom:1.6666667em;padding-left:1em}.lg\:prose-lg :where(h1):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:2.6666667em;margin-top:0;margin-bottom:.8333333em;line-height:1}.lg\:prose-lg :where(h2):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:1.6666667em;margin-top:1.8666667em;margin-bottom:1.0666667em;line-height:1.3333333}.lg\:prose-lg :where(h3):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:1.3333333em;margin-top:1.6666667em;margin-bottom:.6666667em;line-height:1.5}.lg\:prose-lg :where(h4):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.7777778em;margin-bottom:.4444444em;line-height:1.5555556}.lg\:prose-lg :where(img):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.7777778em;margin-bottom:1.7777778em}.lg\:prose-lg :where(picture):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.7777778em;margin-bottom:1.7777778em}.lg\:prose-lg :where(picture>img):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0;margin-bottom:0}.lg\:prose-lg :where(video):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.7777778em;margin-bottom:1.7777778em}.lg\:prose-lg :where(kbd):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8888889em;border-radius:.3125rem;padding:.2222222em .4444444em}.lg\:prose-lg :where(code):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8888889em}.lg\:prose-lg :where(h2 code):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8666667em}.lg\:prose-lg :where(h3 code):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.875em}.lg\:prose-lg :where(pre):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8888889em;line-height:1.75;margin-top:2em;margin-bottom:2em;border-radius:.375rem;padding:1em 1.5em}.lg\:prose-lg :where(ol):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.3333333em;margin-bottom:1.3333333em;padding-left:1.5555556em}.lg\:prose-lg :where(ul):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.3333333em;margin-bottom:1.3333333em;padding-left:1.5555556em}.lg\:prose-lg :where(li):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.6666667em;margin-bottom:.6666667em}.lg\:prose-lg :where(ol>li):not(:where([class~=not-prose],[class~=not-prose] *)){padding-left:.4444444em}.lg\:prose-lg :where(ul>li):not(:where([class~=not-prose],[class~=not-prose] *)){padding-left:.4444444em}.lg\:prose-lg :where(.lg\:prose-lg>ul>li p):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.8888889em;margin-bottom:.8888889em}.lg\:prose-lg :where(.lg\:prose-lg>ul>li>:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.3333333em}.lg\:prose-lg :where(.lg\:prose-lg>ul>li>:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:1.3333333em}.lg\:prose-lg :where(.lg\:prose-lg>ol>li>:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.3333333em}.lg\:prose-lg :where(.lg\:prose-lg>ol>li>:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:1.3333333em}.lg\:prose-lg :where(ul ul,ul ol,ol ul,ol ol):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.8888889em;margin-bottom:.8888889em}.lg\:prose-lg :where(dl):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.3333333em;margin-bottom:1.3333333em}.lg\:prose-lg :where(dt):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.3333333em}.lg\:prose-lg :where(dd):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.6666667em;padding-left:1.5555556em}.lg\:prose-lg :where(hr):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:3.1111111em;margin-bottom:3.1111111em}.lg\:prose-lg :where(hr+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.lg\:prose-lg :where(h2+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.lg\:prose-lg :where(h3+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.lg\:prose-lg :where(h4+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.lg\:prose-lg :where(table):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8888889em;line-height:1.5}.lg\:prose-lg :where(thead th):not(:where([class~=not-prose],[class~=not-prose] *)){padding-right:.75em;padding-bottom:.75em;padding-left:.75em}.lg\:prose-lg :where(thead th:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-left:0}.lg\:prose-lg :where(thead th:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-right:0}.lg\:prose-lg :where(tbody td,tfoot td):not(:where([class~=not-prose],[class~=not-prose] *)){padding:.75em}.lg\:prose-lg :where(tbody td:first-child,tfoot td:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-left:0}.lg\:prose-lg :where(tbody td:last-child,tfoot td:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-right:0}.lg\:prose-lg :where(figure):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.7777778em;margin-bottom:1.7777778em}.lg\:prose-lg :where(figure>*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0;margin-bottom:0}.lg\:prose-lg :where(figcaption):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8888889em;line-height:1.5;margin-top:1em}.lg\:prose-lg :where(.lg\:prose-lg>:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.lg\:prose-lg :where(.lg\:prose-lg>:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:0}}@media (min-width:768px){.md\:h-16{height:4rem}.md\:max-w-prose{max-width:65ch}}@media (min-width:1024px){.lg\:h-96{height:24rem}.lg\:w-1\/2{width:50%}} \ No newline at end of file diff --git a/developers.html b/developers.html new file mode 100644 index 0000000..38a6d7b --- /dev/null +++ b/developers.html @@ -0,0 +1,6 @@ + + + + +Redirect +

Click here to be redirected.

diff --git a/developers/index.html b/developers/index.html new file mode 100644 index 0000000..881d48a --- /dev/null +++ b/developers/index.html @@ -0,0 +1,161 @@ + + + + + + + + + + + + + Developer Information + + + +
+
+
+ + + + + + + Moxxy + + + +
+ + Blog + Developers + Source +
+
+ + +
+
+ +
+
+

+ Moxxy is fully open source. You can find the source code on Codeberg. Additionally, the code is + mirrored on GitHub. +

+ +

+ Feel free to join the general chat or the developer chat with your favourite XMPP client. +

+
+

Libraries

+ +

+ Moxxy is built from various smaller libraries that are custom-made for this purpose. Some of them are for general usage, some are specific to the use case of building Moxxy. +

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
LibraryDescriptionMoxxy specific
+ moxxmpp + XMPP library written in DartNo
+ moxdns + DNS SRV resolver for FlutterYes
+ moxlib + Shared functions for Moxxy-specific projectsYes
+ moxxy_native + Platform-specific codeYes
+ omemo_dart + Implementation of the cryptography for OMEMO 0.8.3 with a high-level interfaceNo
+
+ +
+

Custom XEPs

+ +

+ Moxxy currently implements some custom XMPP protocols to provide additional functionality. These are experimental and are intended to be upstreamed at some point. +

+ + + + + + + + + + + + + + + + + + + + + +
NameDescription
+ Extensible File Thumbnails + Provide an extensible way of specifying thumbnails that are neccessarily binary data
+ File Upload Notification + Allow communicating that an OOB file upload is currently running to improve the consistency of the conversation
+
+
+
+ +
+ + + + diff --git a/feed.xml b/feed.xml new file mode 100644 index 0000000..438932d --- /dev/null +++ b/feed.xml @@ -0,0 +1,521 @@ + + + + Moxxy | A modern XMPP client + https://moxxy.org + A modern XMPP client + Zola + en + + Sun, 20 Aug 2023 00:00:00 +0000 + + GSoC report - Moxxy MUC implementation + Sun, 20 Aug 2023 00:00:00 +0000 + Unknown + https://moxxy.org/blog/moxxy-muc-gsoc-final-report/ + https://moxxy.org/blog/moxxy-muc-gsoc-final-report/ + <h1 id="gsoc-final-report-xmpp-standards-foundation-moxxy-implement-group-chats">GSoC Final Report: XMPP Standards Foundation - Moxxy: Implement Group Chats</h1> +<p><strong>Project:</strong> Moxxy - Implement Group Chats<br /> +<strong>Organization:</strong> XMPP Standards Foundation<br /> +<strong>Duration:</strong> March 2023 - August 2023<br /> +<strong>Student:</strong> Ikjot Singh Dhody<br /> +<strong>Mentor:</strong> Alexander</p> +<h2 id="introduction">Introduction</h2> +<p>This report presents the culmination of my work on the GSoC project &quot;Moxxy: Implement Group Chats&quot; under the mentorship of Alexander at the XMPP Standards Foundation. Over the course of this project, I have been engaged in implementing a group chat feature for the Moxxy application, aiming to enhance its functionality and user experience.</p> +<h2 id="about-me">About Me</h2> +<h3 id="personal-and-social-contact-details">Personal and Social/Contact Details</h3> +<ul> +<li><strong>Name:</strong> Ikjot Singh Dhody</li> +<li><strong>Jabber ID:</strong> ikjot-2605[at]jabber.fr</li> +<li><strong>Email:</strong> ikjotsd[at]gmail.com</li> +<li><strong>GitHub:</strong> <a href="https://github.com/ikjot-2605">ikjot-2605</a></li> +<li><strong>LinkedIn:</strong> <a href="https://www.linkedin.com/in/ikjotsd/">LinkedIn Profile</a></li> +</ul> +<h3 id="educational-background">Educational Background</h3> +<ul> +<li><strong>University:</strong> National Institute of Technology Karnataka, Surathkal</li> +<li><strong>Major:</strong> Computer Science and Engineering</li> +<li><strong>Year:</strong> Senior Year</li> +<li><strong>Degree:</strong> Bachelor of Technology (B. Tech)</li> +</ul> +<h2 id="the-project">The Project</h2> +<p>Before getting into the details of the actual project - here is a demo screencast for the implementation:</p> +<p><img src="https://moxxy.org/blog/moxxy-muc-gsoc-final-report/moxxy-muc-demo.gif" alt="" /></p> +<p>I have outlined the features I implemented through the GSoC period below.</p> +<h3 id="prs-merged">PRs merged</h3> +<ul> +<li>moxxmpp +<ol> +<li><a href="https://codeberg.org/moxxy/moxxmpp/pulls/45">Add support for XEP-0421</a></li> +<li><a href="https://codeberg.org/moxxy/moxxmpp/pulls/46">Implement XEP-0045 support in moxxmpp</a></li> +</ol> +</li> +<li>Moxxy +<ol> +<li><a href="https://codeberg.org/moxxy/moxxy/pulls/300">Add groupchat support for Moxxy</a></li> +</ol> +</li> +<li>website (blog) +<ol> +<li><a href="https://codeberg.org/moxxy/website/pulls/2">Add blog for GSoC MUC project introduction.</a></li> +<li><a href="https://codeberg.org/moxxy/website/pulls/3">Blog for XEP 0045 support in Moxxmpp</a></li> +<li><a href="https://codeberg.org/moxxy/website/pulls/4"> New blog - Join an MUC with Moxxy!</a></li> +<li><a href="https://codeberg.org/moxxy/website/pulls/5">Final GSoC Report Blog</a></li> +</ol> +</li> +</ul> +<h3 id="feature-use-cases">Feature Use-Cases</h3> +<p>The group chat feature required changes to the Moxxy codebase, as well as the moxxmpp codebase. Moxxmpp is the data worker that sends and maintains all the request requirements of the Moxxy frontend. These are the list of contributions across both projects:</p> +<ul> +<li>Joining rooms and getting disco info for the room.</li> +<li>Sending messages to a group chat and receiving messages from the group chat.</li> +<li>Leaving the group chat.</li> +<li>Displaying a UI for joining a group chat and providing a nickname.</li> +<li>Handling group chat details and database support.</li> +<li>Handling group chat errors and basic error handling.</li> +<li>Adding a GroupchatDetails model.</li> +<li>Adding UI elements for group chat, such as title and nickname fields.</li> +<li>Adding documentation to group chat service methods.</li> +<li>Minor code refactoring and naming enhancements.</li> +<li>Enhancing enums for conversation types.</li> +<li>Removing unnecessary translation strings.</li> +<li>Improving UI and formatting.</li> +</ul> +<p>Outlined below are commits made across both codebases throughout the GSoC period.</p> +<h4 id="moxxmpp">Moxxmpp</h4> +<p>There were 2 PRs merged for this codebase. </p> +<ul> +<li>XEP-0421 support for occupant ID support.</li> +</ul> +<table><thead><tr><th>Serial Number</th><th>Commit Hash</th><th>Description</th></tr></thead><tbody> +<tr><td>1</td><td>255d0f88e0</td><td>feat(xep): Use cascading operation to return state</td></tr> +<tr><td>2</td><td>fa11a3a384</td><td>feat(xep): Checked for the occupant-id directly.</td></tr> +<tr><td>3</td><td>ac5bb9e461</td><td>feat(xep): Implement XEP 0421 in Moxxmpp.</td></tr> +</tbody></table> +<ul> +<li>XEP-0045 support for MUC support. </li> +</ul> +<table><thead><tr><th>Serial Number</th><th>Commit Hash</th><th>Description</th></tr></thead><tbody> +<tr><td>1</td><td>b2724aba0c</td><td>Merge branch 'master' into xep_0045</td></tr> +<tr><td>2</td><td>d3742ea156</td><td>feat(xep): Small fixes - MUC Example.</td></tr> +<tr><td>3</td><td>8b00e85167</td><td>feat(xep): Add example for XEP 0045 Moxxmpp.</td></tr> +<tr><td>4</td><td>04dfc6d2ac</td><td>feat(xep): Replace DiscoError with StanzaError.</td></tr> +<tr><td>5</td><td>9e70e802ef</td><td>Merge branch 'master' into xep_0045</td></tr> +<tr><td>6</td><td>3ebd9b86ec</td><td>feat(xep): Fix lint issues and use moxlib for result.</td></tr> +<tr><td>7</td><td>a873edb9ec</td><td>feat(xep): Check for null nick before leaveRoom.</td></tr> +<tr><td>8</td><td>e6bd6d05cd</td><td>feat(xep): Remove NOOP cache access.</td></tr> +<tr><td>9</td><td>b7d53b8f47</td><td>feat(xep): Add docstings for the XEP-0045 routines</td></tr> +<tr><td>10</td><td>217c3ac236</td><td>feat(xep): Fix cache issue with join/leaveRoom.</td></tr> +<tr><td>11</td><td>51bca6c25d</td><td>feat(xep): XEP-0045 cache fixes.</td></tr> +<tr><td>12</td><td>8728166a4d</td><td>feat(xep): Add cache and roomstate to MUC implementation.</td></tr> +<tr><td>13</td><td>1f1321b269</td><td>feat(xep): Small fixes - review cycle 1.</td></tr> +<tr><td>14</td><td>66195f66fa</td><td>Merge branch 'master' into xep_0045</td></tr> +<tr><td>15</td><td>70fdfaf16d</td><td>feat(xep): Fix imports for xep_0045 files.</td></tr> +<tr><td>16</td><td>cd73f89e63</td><td>feat(xep): Remove duplicate manager string</td></tr> +<tr><td>17</td><td>05c41d3185</td><td>feat(xep): Refactor sendMessage to allow groupchat</td></tr> +<tr><td>18</td><td>64a8de6caa</td><td>feat(xep): Set base for XEP 0045 implementation</td></tr> +<tr><td>19</td><td>68809469f6</td><td>feat(xep): Add joinRoom, leaveRoom routines.</td></tr> +<tr><td>20</td><td>762cf1c77a</td><td>feat(xep): Set base for XEP 0045 implementation</td></tr> +</tbody></table> +<h4 id="moxxy">Moxxy</h4> +<ul> +<li>Implement MUCs in Moxxy</li> +</ul> +<table><thead><tr><th>Serial Number</th><th>Commit Hash</th><th>Description</th></tr></thead><tbody> +<tr><td>1</td><td>549e61a168</td><td>feat(all): Fix linter issues.</td></tr> +<tr><td>2</td><td>26bcaccd81</td><td>Merge branch 'master' into feat/groupchat</td></tr> +<tr><td>3</td><td>df5810a347</td><td>feat(all): Formatting change, lock file update</td></tr> +<tr><td>4</td><td>ef931c566f</td><td>feat(all): Send messages/chat state from Moxxy to MUC.</td></tr> +<tr><td>5</td><td>a3d4883406</td><td>feat(all): Remove unnecessary buttons/options for MUC.</td></tr> +<tr><td>6</td><td>532f0b1bb2</td><td>feat(all): Formatting fix, and navigation fix.</td></tr> +<tr><td>7</td><td>a98fe0d9f3</td><td>feat(all): Minor fixes - strings, formatting.</td></tr> +<tr><td>8</td><td>a7c3bd507f</td><td>Merge branch 'master' of https://codeberg.org/moxxy/moxxy into feat/groupchat</td></tr> +<tr><td>9</td><td>fba2cf86ae</td><td>feat(all): Minor formatting changes.</td></tr> +<tr><td>10</td><td>af481bf465</td><td>feat(all): remove unnecessary comparator override.</td></tr> +<tr><td>11</td><td>e6ae8182c2</td><td>feat(all): Organize import in main.dart.</td></tr> +<tr><td>12</td><td>de7b9adfa6</td><td>feat(all): Fix user flow for joining MUC.</td></tr> +<tr><td>13</td><td>e4f98bb82f</td><td>feat(all): Add label to nick text field.</td></tr> +<tr><td>14</td><td>56d6f97168</td><td>feat(all): Minor changes, fixes.</td></tr> +<tr><td>15</td><td>b0067f055f</td><td>feat(all): Move away from exception type design.</td></tr> +<tr><td>16</td><td>bd094dfc9a</td><td>feat(all): Remove unnecessary function.</td></tr> +<tr><td>17</td><td>7e9d7d6281</td><td>feat(all): Check if Groupchat exists before method.</td></tr> +<tr><td>18</td><td>2cf781459d</td><td>feat(all): Debug mode and translatable string</td></tr> +<tr><td>19</td><td>4ff9e3c81e</td><td>feat(all): Remove title from GroupchatDetails.</td></tr> +<tr><td>20</td><td>e337f1c579</td><td>feat(all): Minor refactors - naming.</td></tr> +<tr><td>21</td><td>7c840334e1</td><td>feat(all): Add docs to groupchat service methods.</td></tr> +<tr><td>22</td><td>06eab1d6f5</td><td>feat(all): Make ConversationType an enhanced enum.</td></tr> +<tr><td>23</td><td>008e816d70</td><td>feat(all): Rename JoinGroupchatResultEvent.</td></tr> +<tr><td>24</td><td>2bbbc164b5</td><td>feat(all): Remove incorrect translations.</td></tr> +<tr><td>25</td><td>11f4fd9932</td><td>feat(all): Add title to GroupchatDetails.</td></tr> +<tr><td>26</td><td>a1451c6fbf</td><td>feat(all): Refactor groupchat to new object in db.</td></tr> +<tr><td>27</td><td>993da40297</td><td>feat(all): Complete join groupchat flow.</td></tr> +<tr><td>28</td><td>09684b1268</td><td>feat(all): Fix fromDatabaseJson for MUC details.</td></tr> +<tr><td>29</td><td>0abb89cf38</td><td>feat(all): Fix database issues with nick.</td></tr> +<tr><td>30</td><td>7880f51b76</td><td>feat(all): Add db support for GroupchatDetails.</td></tr> +<tr><td>31</td><td>f0a79ca0e0</td><td>feat(all): Add GroupchatDetails model.</td></tr> +<tr><td>32</td><td>06dcd5491b</td><td>feat(all): Basic groupchat error handling set up.</td></tr> +<tr><td>33</td><td>3641be4f56</td><td>feat(all): Join room functionality complete.</td></tr> +<tr><td>34</td><td>18e28c3bbf</td><td>feat(all): Groupchat service/bloc updated.</td></tr> +<tr><td>35</td><td>62e39bf066</td><td>feat(all): Set base for groupchat implementation.</td></tr> +</tbody></table> +<h2 id="accomplishments">Accomplishments</h2> +<ul> +<li> +<p>Was able to produce a working model of groupchats in Moxxy.</p> +</li> +<li> +<p>Started the design approach from scratch and pretty much stuck to it till the end gave me confidence in my design capability.</p> +</li> +<li> +<p>Fruitful discussions and review cycles were conducted that allowed for a smooth GSoC experience.</p> +</li> +</ul> +<h2 id="challenges-faced">Challenges Faced</h2> +<ul> +<li> +<p>Needed to understand 2 different codebases, and the architecture of the project. This was a pretty interesting, albeit challenging task that took me a while to master.</p> +</li> +<li> +<p>Managing the busy schedule with GSoC work, family, college among other things was difficult. Also, managing a job in the latter parts was also challenging but a rewarding experience.</p> +</li> +<li> +<p>The complete virtual approach was slightly difficult, and although not practical - it might have been slightly better with inter-GSoC meetings.</p> +</li> +</ul> +<h2 id="learnings-takeaways">Learnings/Takeaways</h2> +<ul> +<li>Implemented group chat (Multi-User Chat or MUC) support in the Moxxy project.</li> +<li>Successfully added features for joining a group chat room, sending messages to the room, and receiving messages from the room.</li> +<li>Learned to handle various aspects of XMPP communication, including sending and receiving messages, and interacting with group chat services.</li> +<li>Gained insights into implementing complex functionality in a Flutter application, involving UI components, service classes, and database interactions.</li> +<li>Collaborated with experienced developers through code reviews to improve code quality and ensure adherence to best practices.</li> +<li>Acquired knowledge of working with the XMPP protocol, understanding its intricacies and how it relates to group chat interactions.</li> +<li>Learned to manage and address feedback from code reviewers, making necessary adjustments to improve code readability and functionality.</li> +<li>Discovered the importance of proper error handling in real-time communication scenarios, such as handling different types of group chat errors.</li> +<li>Gained experience in integrating new features while maintaining the overall architecture and user experience of the application.</li> +<li>Understood the complexities of XMPP server behavior, including handling discussion history and preventing message loops.</li> +<li>Explored techniques for optimizing communication performance, such as preventing redundant message processing.</li> +<li>Improved skills in project management, including version control practices, managing branches, and resolving merge conflicts.</li> +<li>Gained familiarity with the process of creating, testing, and merging pull requests in a collaborative development environment.</li> +<li>Developed a better understanding of Flutter's state management, navigation, and widget composition for creating feature-rich user interfaces.</li> +<li>Learned to balance feature development with code quality, addressing both functional and non-functional aspects of the implementation.</li> +<li>Explored advanced Flutter topics, such as handling asynchronous operations, managing state, and integrating with external libraries.</li> +<li>Gained a deeper understanding of how group chat and real-time communication play a significant role in modern applications.</li> +<li>Developed the ability to diagnose and troubleshoot issues related to communication and user interface interactions.</li> +<li>Strengthened communication skills by participating in technical discussions and effectively conveying ideas and solutions.</li> +</ul> +<h2 id="future-work">Future Work</h2> +<p>The future remaining work has been enlisted in this issue by my mentor <a href="https://codeberg.org/moxxy/moxxy/issues/315">here</a>.</p> +<p>This includes a list of improvements, bug fixes and general future requirements that will be needed to make the groupchat experience pleasurable for the users of Moxxy.</p> +<h2 id="conclusion">Conclusion</h2> +<p>Participating in GSoC has been an enriching experience. I've learned valuable skills, collaborated with mentors and the open-source community, and contributed to the Moxxy project. I'm grateful to XMPP Standards Foundation for this opportunity and look forward to continuing my journey in the world of open-source software development.</p> +<h2 id="acknowledgments">Acknowledgments</h2> +<p>I would like to express my gratitude to my mentor Alexander for their guidance and support throughout this project. His guidance and understanding is what allowed me to pull through and complete the GSoC with a happy mind. I also want to thank the XMPP Standards Foundation community for their encouragement and feedback.</p> + + + + Joining an MUC with Moxxy! + Mon, 24 Jul 2023 00:00:00 +0000 + Unknown + https://moxxy.org/blog/join-muc-with-moxxy/ + https://moxxy.org/blog/join-muc-with-moxxy/ + <p>Greetings, readers!</p> +<p>Welcome back to our series of blogs on the Google Summer of Code (GSoC) project. In this blog post, I'll be sharing the progress made in implementing Multi-User Chat (MUC) support in Moxxy, the frontend counterpart to my GSoC project.</p> +<span id="continue-reading"></span><h2 id="introduction">Introduction</h2> +<p>As you may recall, Moxxy is a frontend application developed as an innovative XMPP client. To enhance its functionality, my GSoC project focuses on adding MUC support. Before diving into the Moxxy implementation, it was crucial to establish the necessary MUC support in Moxxmpp, which is highlighted in <a href="https://moxxy.org/posts/2023-06-17-XEP-0045-In-Moxxmpp.html">this</a> blog.</p> +<p>Currently, the implementation progress is to allow users to join an MUC through Moxxy, and view incoming live messages in the chat. </p> +<h2 id="design-plan-for-muc-support-in-moxxy">Design Plan for MUC Support in Moxxy</h2> +<p>To implement MUC support in Moxxy, we need to extend its functionality and introduce new components. Let's outline the design plan for the MUC feature:</p> +<h3 id="new-page">New Page</h3> +<h4 id="joingroupchatpage">JoinGroupchatPage</h4> +<p>This page will contain just 1 text field - for the nickname that the user wants to join with. It also has a button that allows us to join the MUC with said nickname. It is an additional route to the current StartChat page, if the user selects that they want to join a groupchat.</p> +<h3 id="new-command">New Command</h3> +<h4 id="joingroupchatcommand">JoinGroupchatCommand</h4> +<p>This command is sent to the data layer worker (separate thread) from the UI, when the user clicks on the join groupchat button on the new join groupchat page. It contains information about the JID and the nick that the user tried to join with. This will only be sent to the worker thread if the input validations are cleared.</p> +<h3 id="new-event">New Event</h3> +<h4 id="joingroupchatresult">JoinGroupchatResult</h4> +<p>This event is sent back as a result of the JoinGroupchatCommand. Based on whether the request succeeded or failed, it will return the new Conversation object that has just been created.</p> +<h3 id="database-changes">Database changes</h3> +<h4 id="groupchatdetails-table">GroupchatDetails table</h4> +<p>Add a new GrouchatDetails table to the database containing two data items - the jid and the nick. The main reason to have a separate table for the groupchat details, instead of to just have a new nick item in the Conversation table - was to maintain the single responsibility principle.</p> +<p>When the user fetches a conversation of type groupchat from the database, a separate call will be made that fetches the relevant groupchat details from this new table, and attaches it to the Conversation object.</p> +<h3 id="miscellaneous-changes">Miscellaneous changes</h3> +<ul> +<li> +<p>Changed the external helpers for the ConversationType to an enhanced enum. This allows us to include the functions within the enum.</p> +</li> +<li> +<p>The MUCManager was added to the list of registered managers for Moxxy. Not only this, the OccupantIdManager was also registered which will allow for the unique occupant identification moving forward. This will be required for message reactions/retractions in an MUC. </p> +</li> +</ul> +<h3 id="new-service">New Service</h3> +<h4 id="groupchatservice">GroupchatService</h4> +<p>Added a new GroupchatService that allows for the following functions:</p> +<ul> +<li><strong>getRoomInformation</strong>: Sends a request to moxxmpp to receive disco info about the MUC.</li> +<li><strong>joinRoom</strong>: Sends a request to moxxmpp to join the MUC if it's not password protected.</li> +<li><strong>addGroupchatDetailsFromData</strong>: Adds a new GroupchatDetails object to the database table.</li> +<li><strong>getGroupchatDetailsByJid</strong>: Fetches the GroupchatDetails from the database based on the JID provided. This is required as a separate step while fetching an MUC conversation since the Conversations and GroupchatDetails table are decoupled. </li> +</ul> +<h3 id="handling-errors">Handling Errors</h3> +<p>To prevent avoidable errors, Moxxy performs frontend checks when joining a room. These checks include ensuring to validate the JID input field, and checking for empty nicknames.</p> +<p>Possible errors that users may encounter during the MUC workflow include invalid or already in use nicknames, disallowed registration, invalid stanza format, and invalid disco info response. Moxxy will handle these errors gracefully.</p> +<h2 id="challenges-and-considerations">Challenges and Considerations</h2> +<p>Here is an enumeration of the possible challenges that we could face in the future implementation, and the ones I faced in the current implementation as well:</p> +<ol> +<li> +<p>Differentiating Messages from Oneself: Moxxy/Moxxmpp need to distinguish between messages from other users and self-echoed messages. To address this, Moxxy uses the origin ID of the message. If the origin ID of the response matches the sent origin ID, the message is ignored and not displayed in the UI.</p> +</li> +<li> +<p>Handling Impersonation in Anonymous MUCs: In anonymous MUCs, users can impersonate others by reusing their nicknames after leaving. To tackle this, Moxxmpp leverages the occupant ID, as described in XEP-0421. Each user joining the group receives a unique occupant ID, which helps track message origins accurately.</p> +</li> +<li> +<p>Managing Discussion History on Rejoining: When a user rejoins an MUC, the room history is resent, including errors, self-presence with status code, room history, room subject, and live message/presence updates. To prevent appending duplicate history to the UI, Moxxy/Moxxmpp will have to wait until it receives the room subject before listening for message stanzas.</p> +</li> +</ol> +<h2 id="conclusion-and-future-work">Conclusion and Future Work</h2> +<p>In this blog post, we explored the implementation plan for adding MUC support, specifically XEP-0045, to Moxxy. Moxxmpp serves as the backbone for Moxxy's XMPP functionality, handling communication between the client and XMPP server. We discussed the directory structure, and key routines required for MUC support in Moxxmpp. Additionally, we addressed various challenges and considerations related to MUC features.</p> +<p>The implementation process has already commenced, with a pull request (PR) underway. Once the PR is complete, Moxxy will support joining a groupchat and listening to live messages. In further PRs, sending messages and leaving the MUC will be supported as well. The addition of MUC support will empower Moxxy users to enjoy enhanced collaboration and communication within XMPP group chats.</p> +<p>Stay tuned for future updates on the progress of MUC support in Moxxy. Until then, happy chatting!</p> + + + + XEP-0045 implementation in Moxxmpp + Sat, 17 Jun 2023 00:00:00 +0000 + Unknown + https://moxxy.org/blog/xep-0045-in-moxxmpp/ + https://moxxy.org/blog/xep-0045-in-moxxmpp/ + <p>Hello readers!</p> +<p>Welcome back to the GSoC series of blogs. This one is about my implementation of the MUC XEP (XEP-0045) in Moxxmpp.</p> +<span id="continue-reading"></span><h2 id="introduction">Introduction</h2> +<p>Well, as you probably know, Moxxy is the frontend app that is being developed as a modern new XMPP client.</p> +<p>Moxxmpp is a Dart package that is used by Moxxy for multiple XMPP services. Essentially, the conversation between Moxxy and the XMPP server is handled by Moxxmpp. It is like the middleman that helps ease the communication between the two, keeping Moxxy code clean and free from the intricacies it handles.</p> +<p>Since my GSoC project is all about adding MUC support to Moxxy, it was essential to first add the required support in Moxxmpp before proceeding to Moxxy. This blog will give you an idea of what the responsibilities of Moxxmpp are, and why it was important to separate it from Moxxy.</p> +<h2 id="what-is-moxxmpp">What is Moxxmpp?</h2> +<p>In the words of it's developer, Moxxmpp is &quot;a pure-Dart XMPP library&quot;. Moxxmpp could be thought of as the backbone of Moxxy. The entire communication/networking part of Moxxy, i.e. how it (as a client) communicates with the user's XMPP server is outsourced to this Dart library.</p> +<p>Not only this, used as per it's rules - Moxxmpp could be used by any client to perform XMPP tasks that are currently supported by it. It is a re-usable and versatile XMPP library.</p> +<p>Listed below are some of it's core responsibilities:</p> +<ol> +<li> +<p>Establishing the connection between the client and the XMPP server via the user's JID and password.</p> +</li> +<li> +<p>Allowing Moxxy/any front-end client to register managers that provide support for a particular XEP/part of the XMPP flow. For example: the messaging service is handled by a MessageManager. +Similarly here are some other managers with their use:</p> +<ol> +<li>PresenceManager: Handling the presence related stanzas/use.</li> +<li>PubSubManager: Provides support for XEP-0060.</li> +<li>DiscoManager: Provides support for the service discovery: XEP-0030.</li> +<li>RosterManager: Handling roster related tasks.</li> +<li>BlockingManager: For blocking related tasks.</li> +</ol> +<p>As of June 17 2023, there are 35 such managers and 35 XEPs supported in Moxxmpp.</p> +</li> +<li> +<p>Managing cache: Moxxmpp manages cache of common requests, such as service discovery requests. If a request is duplicated, the result is provided from the cache - saving bandwidth and time.</p> +</li> +</ol> +<p>As explained below, new XEP support is related to adding new managers to Moxxmpp and I will be doing the same for XEP-0045 support in Moxxy. My design plan is elaborated in the next section. </p> +<p>Here is my implementation plan for adding XEP-0045 support to Moxxmpp.</p> +<h2 id="gsoc-moxxmpp-implementation-design-plan">GSoC Moxxmpp Implementation Design Plan</h2> +<h3 id="directory-structure">Directory Structure</h3> +<ul> +<li>xep_0045 +<ul> +<li>errors.dart</li> +<li>helpers.dart</li> +<li>types.dart</li> +<li>xep_0045.dart</li> +</ul> +</li> +<li>Here, the errors.dart file will contain the abstract classes for different errors that one could get whilst going through all the lifecycle use-cases of the MUC feature.</li> +<li>The helpers.dart file will have some helper functions to maintain (DRY code avoiding repetition) and (modularized code).</li> +<li>types.dart will contain model classes for the events and other entities.</li> +<li>The xep_0045.dart is the main file which will contain the exposed routines as shown below, as well as the incoming stanza handlers.</li> +</ul> +<h3 id="phase-1-query-room-information">Phase 1 - Query Room Information</h3> +<h4 id="future-result-roominformation-mucerror-queryroominformation-jid-roomjid"><code>Future&lt;Result&lt;RoomInformation,MUCError&gt;&gt; queryRoomInformation(JID roomJID)</code></h4> +<p>This routine will allow the users to view the features of the room. These will include whether the room is open, moderated, password protected, etc. All this will be stored in a RoomInformation object and sent back as a Result object. It is important to note that the MUC server's address (for the 'to' attribute) will be parsed from the latter half of the room JID (the part post the '@').</p> +<p>The parameters of the RoomInformation class will be represented in the following way:</p> +<ol> +<li><code>JID roomJID</code></li> +<li><code>List&lt;String&gt; feature_list</code></li> +</ol> +<h3 id="phase-2-join-leave-room-handle-errors">Phase 2 - Join/Leave Room(Handle errors)</h3> +<p>To join/leave a room we can send an appropriate presence stanza that will handle the same for us. So we will have two simple routines for the same as well.</p> +<h3 id="routines">Routines</h3> +<h4 id="future-result-bool-mucerror-joinroom-jid-roomjid"><code>Future&lt;Result&gt;bool, MUCError&gt;&gt; joinRoom(JID roomJID)</code></h4> +<p>This routine will send a presence stanza to the MUC server asking it to join the server. It takes the <code>roomJID</code> as a parameter that will essentially contain the bare JID as well as the nickname (prompted from the user) as the resource. This will be preceded by the queryRoomInformation() routine call to obtain necessary information about the room, for example: if the room is password protected (in which case the user will see a not-implemented error dialog till a time it is supported).</p> +<p>Important to note is that the user's nickname will be used as the 'resource' in the roomJID sent by the frontend. This is because the 'to' attribute of a presence stanza to join a room looks as such - <code>{local/MUC}@{domain/chat server}/{nickname}.</code></p> +<h4 id="future-result-bool-mucerror-leaveroom-jid-roomjid"><code>Future&lt;Result&lt;bool, MUCError&gt;&gt; leaveRoom(JID roomJID)</code></h4> +<p>Similarly this is a routine to allow for leaving the room with a presence stanza.</p> +<p>The boolean return type is just to allow for a simple return object with the Result type. We could move forward with a simple Future<bool> as well, but for the sake of consistency - maybe sticking to the former is better. </p> +<h3 id="phase-3-refactor-sendmessage-to-handle-mucs">Phase 3 - Refactor sendMessage to handle MUCs</h3> +<p>To be able to send messages to groupchats/MUCs, the main requirement is to be able to change the <code>type</code> attribute in the message stanzas from <code>chat</code> to <code>groupchat</code>. This can be done in one of two ways. The first way will be to change the <code>sendMessage</code> routine's description to include a <code>type</code> parameter that will simply transfer over to the stanza that will be sent from moxxmpp as a string. Another was is described below, where a new extension called ConversationTypeData will be added to the <code>StanzaHandlerExtension</code> object whilst calling the sendMessage routine. The former solution is simpler and will most probably be implemented. The design for both these possibilities is listed below.</p> +<h4 id="solution-1">Solution 1</h4> +<p>The <code>sendMessage</code> routine will transform from </p> +<pre data-lang="Dart" class="language-Dart "><code class="language-Dart" data-lang="Dart">Future&lt;void&gt; sendMessage( + JID to, + TypedMap&lt;StanzaHandlerExtension&gt; extensions, +) async { + await getAttributes().sendStanza( + StanzaDetails( + Stanza.message( + to: to.toString(), + id: extensions.get&lt;MessageIdData&gt;()?.id, + type: &#x27;chat&#x27;, + children: _messageSendingCallbacks + .map((c) =&gt; c(extensions)) + .flattened + .toList(), + ), + awaitable: false, + ), + ); +} +</code></pre> +<p>to</p> +<pre data-lang="Dart" class="language-Dart "><code class="language-Dart" data-lang="Dart">Future&lt;void&gt; sendMessage( + JID to, + TypedMap&lt;StanzaHandlerExtension&gt; extensions, + String type, +) async { + await getAttributes().sendStanza( + StanzaDetails( + Stanza.message( + to: to.toString(), + id: extensions.get&lt;MessageIdData&gt;()?.id, + type: type, + children: _messageSendingCallbacks + .map((c) =&gt; c(extensions)) + .flattened + .toList(), + ), + awaitable: false, + ), + ); +} +</code></pre> +<h4 id="solution-2">Solution 2</h4> +<pre data-lang="Dart" class="language-Dart "><code class="language-Dart" data-lang="Dart">enum ConversationType { + chat, groupchat, groupchatprivate +} +</code></pre> +<p>The <code>ConversationTypeData</code> class essentially will act as a wrapper over the above enum. </p> +<p>Hence the new type attribute value will be:</p> +<pre data-lang="Dart" class="language-Dart "><code class="language-Dart" data-lang="Dart">extensions.get&lt;ConversationTypeData&gt;()?.conversationType == + ConversationType.groupchat + ? &#x27;groupchat&#x27; + : &#x27;chat&#x27;, +</code></pre> +<p>Here, <code>ConversationTypeData</code> is a simple wrapper over <code>ConversationType</code> so that it can be recognized as a subclass of the <code>StanzaHandlerExtensions</code> class.</p> +<p>For private MUC messages to a single participant, the <code>type</code> attribute of the message stanza should be set to <code>chat</code>. This can be handled very easily in case of either solution implementation. </p> +<hr /> +<p>For MUC messages with a stanza reflecting a chat server (type: 'groupchat'), the type in the MessageEvent will be set to 'groupchat' automatically. The rest will be handled similarly to 1:1 chats.</p> +<h3 id="phase-4-miscellaneous-requirements">Phase 4 - Miscellaneous requirements</h3> +<p>Some of the miscellaneous requirements from Moxxmpp could include viewing member list, group subject, change availability status, and more. +For now, I have identified the below as the most crucial requirements for the Moxxmpp feature additions for MUC. </p> +<p>Below are the use-cases and how they are planned to be handled:</p> +<ol> +<li>Get member list</li> +</ol> +<p>After one joins a room, the user receives a presence from all the connected users to the chat. The best way to get the member list is to capture/handle the incoming presence stanzas and send an appropriate <code>MUCPresenceReceived</code> event to the UI.</p> +<p>This way, whenever a user joins a room, they can see the current member list, and on subsequent presence updates, also change that list.</p> +<ol start="2"> +<li>Handling the room subject</li> +</ol> +<p>This is a very simple usecase. When a disco info query about the MUC goes out to the XMPP server, the response contains an identity node containing the chat name. This would be the best way to extract the rom subject. As of now, the <code>queryRoomInformation</code> routine will be triggered from the UI and the response will be sent to the same. This will be encapsulated in a simple <code>RoomInformation</code> class which is now updated as follows:</p> +<ol> +<li><code>JID roomJID</code></li> +<li><code>List&lt;String&gt; feature_list</code></li> +<li><code>String name</code></li> +</ol> +<p><strong>Note</strong>: Changing your status seemed like a task that would be slighlty out of scope for the project duration, so that is kept as a stretch goal for now.</p> +<h3 id="errors">Errors</h3> +<p>Frontend checks while joining a room to prevent avoidable errors:</p> +<ul> +<li>Nickname must be specified in accordance with the rules of the XEP - to prevent the no nickname specified error.</li> +<li>Validations for JID input field.</li> +<li>Validation for checking empty nickname.</li> +</ul> +<p>Some of the possible errors that can be faced by the user in an MUC workflow are:</p> +<ul> +<li>Invalid/Already in use nickname</li> +<li>Not allowed to register</li> +<li>Invalid stanza format</li> +<li>Invalid Disco Info Response: In case of some rare edge cases (not handled currently) where the response does not contain some information like the room name, or the features of the room. </li> +</ul> +<h2 id="challenges-noted">Challenges noted</h2> +<p>Some challenges/room for error were noted along the way. They are enumerated below:</p> +<ol> +<li> +<p>How will Moxxy/Moxxmpp handle messages from oneself?</p> +<p>When a user sends a message on the MUC, they receive the message themselves as well. How will moxxmpp/moxxy differentiate between other live messages and this echoed message? </p> +<p>The solution to this problem is to use the origin-id of the message. If the origin-id of the response matches with the sent origin-id, then the message is to be ignored and not shown in the UI. </p> +</li> +<li> +<p>In anonymous MUCs, one can easily act as someone else by using their nickname once they leave. How will this be handled?</p> +<p>This is fixed by using the occupant-id property as described in XEP-0421. A user (with their unique JID) when joins the group, is assigned a unique occupant-id, which can be used to actually track which message is from which user. </p> +<p>This makes the implementation of reactions/retractions simpler. </p> +</li> +<li> +<p>How will discussion history (sent on joining an MUC) be handled when someone rejoins an MUC?</p> +<p>When a user joins a MUC, they are sent a set of stanzas in the following order:</p> +<pre><code> 1. Errors (if any) + 2. Self presence with status code + 3. Room history + 4. Room subject + 5. Live message&#x2F;presence updates +</code></pre> +<p>Now, when a user gets disconnected from an MUC and joins again, then the room history will be sent again as well. To prevent this history from getting appended to the conversation in the UI, we will need to wait till we receive the room subject and only then start listening for message stanzas (since room subject is sent after room history).</p> +</li> +</ol> +<h2 id="conclusion-and-future-work">Conclusion and future work</h2> +<p>In conclusion, this blog post discussed the implementation plan for adding Multi-User Chat (MUC) support, specifically XEP-0045, to Moxxmpp. Moxxmpp serves as the backbone for the Moxxy XMPP client, handling the communication between the client and XMPP server. The blog outlined the directory structure, design plan, and key routines for implementing the MUC support in Moxxmpp. It also addressed some challenges and considerations related to handling MUC features.</p> +<p>Implementation for this has begun, and a <a href="https://codeberg.org/moxxy/moxxmpp/pulls/46">PR</a> is already underway. Once this PR is completed, then work will begin on the front-end and the changes will be integrated into Moxxy.</p> + + + + Moxxy's First GSoC Project! + Sat, 06 May 2023 00:00:00 +0000 + Unknown + https://moxxy.org/blog/groupchat-gsoc-project/ + https://moxxy.org/blog/groupchat-gsoc-project/ + <p>Hello readers!</p> +<p>As we know, Moxxy is an experimental IM for XMPP built using Flutter. While it does have a great set of features as described <a href="https://moxxy.org/">here</a>, it currently lacks support for group chats (or Multi-User-Chats). A great piece of news is that Google has accepted my proposal to add support for multi user chats in Moxxy.</p> +<span id="continue-reading"></span> +<p>To implement multi user chats in Moxxy, the <a href="https://xmpp.org/extensions/xep-0045.html">XEP-0045</a> standard will be followed and implemented. The project will run in two phases, since the major changes required will be in the <a href="https://codeberg.org/moxxy/moxxmpp">moxxmpp</a> and <a href="https://codeberg.org/moxxy/moxxy">Moxxy</a> codebases. First, XEP-0045 support will be added to moxxmpp with all the handlers, events and routines required to cleanly integrate the same with Moxxy. The second phase will be the UI changes in the Moxxy Flutter application, that builds upon the existing, reusable infrastructure.</p> +<p>The usecases planned to be implemented are listed below (subject to changes before the coding period begins):</p> +<ul> +<li>Join a room</li> +<li>Leave a room</li> +<li>Change availability status</li> +<li>View member list</li> +<li>Send/receive a message to/from all occupants</li> +<li>Send/receive a private message to/from a specific occupant</li> +</ul> +<p>Some extra usecases are planned in case time permits:</p> +<ul> +<li>Change nickname</li> +<li>Kick an occupant (if user has such a permission)</li> +<li>Ban an occupant (if user has such a permission)</li> +<li>Grant/revoke membership (if user has such a permission)</li> +</ul> +<p>The coding period for this project will begin on May 29. In case of any queries/interest, please join the following - <a href="xmpp:dev@muc.moxxy.org?join">xmpp:dev@muc.moxxy.org?join</a>.</p> + + + + Moxxy's New Website + Tue, 24 Jan 2023 00:00:00 +0000 + Unknown + https://moxxy.org/blog/moxxys-new-website/ + https://moxxy.org/blog/moxxys-new-website/ + <p>Hello everyone! Welcome on Moxxy's new website. It currently does not contain +much but that may change in the future.</p> +<span id="continue-reading"></span> +<p>The page is built using <a href="https://jekyllrb.com/">Jekyll</a> and <a href="https://tailwindcss.com/">TailwindCSS</a>. You can find the page's +source <a href="https://codeberg.org/moxxy/website">here</a>.</p> + + + + \ No newline at end of file diff --git a/img/badges/IzzyOnDroid.png b/img/badges/IzzyOnDroid.png new file mode 100644 index 0000000..5050e65 Binary files /dev/null and b/img/badges/IzzyOnDroid.png differ diff --git a/img/badges/codeberg.png b/img/badges/codeberg.png new file mode 100644 index 0000000..aab6455 Binary files /dev/null and b/img/badges/codeberg.png differ diff --git a/img/favicon.ico b/img/favicon.ico new file mode 100644 index 0000000..1df863b Binary files /dev/null and b/img/favicon.ico differ diff --git a/img/logo.png b/img/logo.png new file mode 100644 index 0000000..9b557af Binary files /dev/null and b/img/logo.png differ diff --git a/img/screenshots/1.png b/img/screenshots/1.png new file mode 100644 index 0000000..83c7dfd Binary files /dev/null and b/img/screenshots/1.png differ diff --git a/img/screenshots/2.png b/img/screenshots/2.png new file mode 100644 index 0000000..d6af8c6 Binary files /dev/null and b/img/screenshots/2.png differ diff --git a/index.html b/index.html new file mode 100644 index 0000000..efaaa38 --- /dev/null +++ b/index.html @@ -0,0 +1,124 @@ + + + + + + + + + + + + + Moxxy | A modern XMPP client + + + +
+
+
+ + + + + + + Moxxy + + + +
+ + Blog + Developers + Source +
+
+ + +
+
+
+ An experimental and modern XMPP client +
+
+ +
+
+
+ +
+
+
+ + + + + + + + + +
+
+
+ +
+
+
+

Features

+ +
    + +
  • End-to-End encryption using OMEMO (0.8.3)
  • + +
  • Stickers
  • + +
  • Reactions
  • + +
  • Retract messages
  • + +
  • Voice messages
  • + +
  • Swipe-to-quote
  • + +
  • Chat background images
  • + +
  • Optional privacy-preserving integration with phone contacts
  • + +
  • Open-Source
  • + +
+
+
+
+ +
+
+
+

Screenshots

+ +
+ + + + + +
+
+
+
+ +
+ + + + diff --git a/posts.html b/posts.html new file mode 100644 index 0000000..fb45611 --- /dev/null +++ b/posts.html @@ -0,0 +1,6 @@ + + + + +Redirect +

Click here to be redirected.

diff --git a/posts/2023-01-24-Moxxys-New-Website.html b/posts/2023-01-24-Moxxys-New-Website.html new file mode 100644 index 0000000..6090853 --- /dev/null +++ b/posts/2023-01-24-Moxxys-New-Website.html @@ -0,0 +1,6 @@ + + + + +Redirect +

Click here to be redirected.

diff --git a/posts/2023-05-06-Groupchat-GSoC-Project.html b/posts/2023-05-06-Groupchat-GSoC-Project.html new file mode 100644 index 0000000..4d41928 --- /dev/null +++ b/posts/2023-05-06-Groupchat-GSoC-Project.html @@ -0,0 +1,6 @@ + + + + +Redirect +

Click here to be redirected.

diff --git a/posts/2023-06-17-XEP-0045-In-Moxxmpp.html b/posts/2023-06-17-XEP-0045-In-Moxxmpp.html new file mode 100644 index 0000000..ac44ae6 --- /dev/null +++ b/posts/2023-06-17-XEP-0045-In-Moxxmpp.html @@ -0,0 +1,6 @@ + + + + +Redirect +

Click here to be redirected.

diff --git a/posts/2023-07-24-Join-MUC-With-Moxxy.html b/posts/2023-07-24-Join-MUC-With-Moxxy.html new file mode 100644 index 0000000..e140f6e --- /dev/null +++ b/posts/2023-07-24-Join-MUC-With-Moxxy.html @@ -0,0 +1,6 @@ + + + + +Redirect +

Click here to be redirected.

diff --git a/posts/2023-08-20-Moxxy-MUC-GSoC-Final-Report.html b/posts/2023-08-20-Moxxy-MUC-GSoC-Final-Report.html new file mode 100644 index 0000000..3240a34 --- /dev/null +++ b/posts/2023-08-20-Moxxy-MUC-GSoC-Final-Report.html @@ -0,0 +1,6 @@ + + + + +Redirect +

Click here to be redirected.

diff --git a/rio.json b/rio.json new file mode 100644 index 0000000..b9ff511 --- /dev/null +++ b/rio.json @@ -0,0 +1,8 @@ +{ + "CNAME": "moxxy.org", + "headers": { + "Content-Security-Policy": "default-src 'self'; script-src 'self'; script-src-elem 'self'; script-src-attr 'none'; style-src * 'self'; img-src 'self' data:; font-src 'self'; connect-src 'none'; media-src 'self'; object-src 'none'; prefetch-src 'none'; child-src 'none'; frame-src 'none'; worker-src 'none'; frame-ancestors 'none'; form-action 'none'; upgrade-insecure-requests; block-all-mixed-content; disown-opener; sandbox; base-uri https://moxxy.org; manifest-src 'none'", + "X-Frame-Options": "DENY", + "Referrer-Policy": "no-referrer, strict-origin-when-cross-origin" + } +} \ No newline at end of file diff --git a/robots.txt b/robots.txt new file mode 100644 index 0000000..ed1d8e0 --- /dev/null +++ b/robots.txt @@ -0,0 +1,4 @@ +User-agent: * +Disallow: +Allow: / +Sitemap: https://moxxy.org/sitemap.xml diff --git a/sitemap.xml b/sitemap.xml new file mode 100644 index 0000000..c390d77 --- /dev/null +++ b/sitemap.xml @@ -0,0 +1,32 @@ + + + + https://moxxy.org/ + + + https://moxxy.org/blog/ + + + https://moxxy.org/blog/groupchat-gsoc-project/ + 2023-05-06 + + + https://moxxy.org/blog/join-muc-with-moxxy/ + 2023-07-24 + + + https://moxxy.org/blog/moxxy-muc-gsoc-final-report/ + 2023-08-20 + + + https://moxxy.org/blog/moxxys-new-website/ + 2023-01-24 + + + https://moxxy.org/blog/xep-0045-in-moxxmpp/ + 2023-06-17 + + + https://moxxy.org/developers/ + +