GithubHelp home page GithubHelp logo

heimiricmr / bromelia Goto Github PK

View Code? Open in Web Editor NEW
30.0 3.0 12.0 1.76 MB

A Python micro framework for building Diameter protocol applications.

License: MIT License

Python 100.00%
diameter 3gpp ietf ietf-rfcs cellular-network volte 4g-network

bromelia's People

Contributors

heimiricmr avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

bromelia's Issues

Additional Diameter AVPs are not added & passed.

In the diameter-app1, diameter_mme.py, I tried adding addtional AVPs like AuthApplicationIdAVP, AuthSessionStateAVP. But these AVPs are not getting passed. Please let me know how to get these avp passed.

Ingress stream leftover bytes are considered as an invalid AVP

When a large number of Diameter messages are being exchanged between the client and the server, the incoming stream might be divided into multiple batches, where each batch does not necessarily consist of an integral number of messages. The following 5-message scenario explains the issue.

5 messages are being sent in two batches:

Batch 1:
-----Message1---------|-------Message2---------|------------Message3-------------|--------Message 4 part1

Batch 2

-----Message 4 part 2------|------------------Message5-------|

The current implementation does not take into account this case; it considers data streams as independent of each other.

Bromelia app is stuck in infinite loops and Deadlocks when Diameter server is disconnected

When the TCP connection is terminated either gracefully via DPR/DPA messages or abruptly if the connection is lost, the underlying processes and threads started within the framework will be stuck in infinite loops and Deadlocks. Thus, the client of the Bromelia library will also hang and has no way to proceed or re-initialize the library again.

Also, if the above issues were fixed, there is no way to notify the user of the Bromeilia instance that an interruption in the connection or the flow has occurred

Related Infinite loops:

  1. bromelia.py / Worker.send_handler
  2. bromelia.py / Worker.recv_handler
  3. broemlia.py / Bromelia.main

Deadlock:

  1. setup.py / DiameterAssociation.get_message (self.postprocess_recv_messages_ready.wait()). When the connection is interrupted, this lock will never be freed, and the lock will be kept waiting forever.

Cannot get AVP data in native type

For example, I have an answer object of type CreditControlAnswer, which has an AVP of type ResultCodeAVP.

I need to check what is the value of that AVP. The data attribute of the ResultCodeAVP returns only the serialized (encoded) data, and there are no methods available to deserialize (decode) that data.

The same applies to all AVP classes of all types.

Terminating and Monitoring Bromelia app instances

Currently, there is no way to terminate a Bromelia app instance gracefully, the main loop will be kept executing forever until the parent process is terminated.

Also, if the connection to the peer is lost, no functionality is implemented to restore the connection or terminate the worker process. Thus, this is a reliability issue that limits the usefulness of the library in a production environment.

Not all data sent from Diameter server is read

When a large amount of data is sent from the Diameter server, such as a long message or multiple messages together, the first 256KBs are only read. Any other data beyond this limit will be ignored.

Ref: TcpConnection._read method.

SCTP transport

Are there any plans for implementation SCTP transport for Bromelia?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.