Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

newFARMap is adding empty forwardingParameters #5

Closed
ranomine opened this issue Jan 13, 2023 · 2 comments · Fixed by #6
Closed

newFARMap is adding empty forwardingParameters #5

ranomine opened this issue Jan 13, 2023 · 2 comments · Fixed by #6
Labels
bug Something isn't working

Comments

@ranomine
Copy link
Contributor

ranomine commented Jan 13, 2023

Hi,

Creating a FAR as follows:

gtpFAR1 := ie.NewCreateFAR(
		ie.NewFARID(0x00000002),
		ie.NewApplyAction(0x0100))

which is valid.

I notice that NewFARMap is adding an empty forwardingParameters ie to the FAR like:

*github.com/wmnsk/go-pfcp/ie.IE {Type: 4, Length: 0, EnterpriseID: 0, Payload: []uint8 len: 0, cap: 0, [], ChildIEs: []*github.com/wmnsk/go-pfcp/ie.IE len: 0, cap: 0, nil}
@louisroyer
Copy link
Member

Hi, could you test if 1b98989 solves your issue (go get -u github.com/louisroyer/go-pfcp-networking@ForwardingParametersEmpty)?

I generally don't use DROP flag and since my FarMAP implementation is very minimal and focuses on what I needed to create an UPF (with a lots of feature missing), this case was untested.
I have planed to store all of this in a true database (because matching of existing rules is very slow at the moment, and my UPF's bit-rate is limited by it): this will allow to perform SQL requests and also handling of more FAR related IEs… but for the moment, I haven't found enough time to implement it.

@louisroyer louisroyer added the bug Something isn't working label Jan 13, 2023
@ranomine
Copy link
Contributor Author

Hi,

I think that you need also to fix NewCreateFAR which is checking that far.forwardingParameters isn't nil
but far.ForwardingParameters() is actually returning an empty array instead of nil when the IE isn't present.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: Done
2 participants