P1sec / pycrate

A Python library to ease the development of encoders and decoders for various protocols and file formats; contains ASN.1 and CSN.1 compilers.
GNU Lesser General Public License v2.1
381 stars 132 forks source link

Need a sample MSISDN initialization example #167

Closed sohel1119 closed 2 years ago

sohel1119 commented 2 years ago

I am perform some activity regarding GTP-V2-C and not getting actual output of MSISDN

p1-bmu commented 2 years ago

https://github.com/P1sec/pycrate#filling-an-issue

sohel1119 commented 2 years ago

`Python 3.8.10 (default, Nov 26 2021, 20:14:08)

In [1]: from pycrate_mobile.TS29274_GTPC import *

In [2]: m = CreateSessionRequest() ...: m[1].init_ies() ...: m[1].add_ie(76,1)

In [3]: print(m[1][4][1].show()) \<MSISDN : >

In [4]: m[1][4][1].set_val({'MSISDN ': 1234567890}) ...: print(m[1][4][1].show()) \<MSISDN : >

`

p1-bmu commented 2 years ago
In [20]: m[1][4][1].set_val('1234567890')                                                                                                                 

In [21]: m[1][4][1]                                                                                                                                       
Out[21]: <MSISDN : 1234567890>