I am developing a application which has a Interface list to see all active adapters . The application is like a VPN . So it connect with active adapter and I can browse internet . So I am creating a virtual adapter and using this adapter I am connecting . It works Fine on Ethernet , Wi-Fi .
Now i want to get connect my application on Mobile broadband . I installed HUAWEI Mobile broadband . It has 2 type of connection
- RAS type (3g modem)
- NDIS type (3g adapter card)
I can see 3g modem active on Interface list when i connect with RAS type . But I can’t see 3g adapter card on Interface list when i connect with NDIS type .
So after that I got document from Microsoft for
- MB Miniport driver INF Requirements
- MB Raw IP Packet Processing Support
I think these are the main changes to get support for mobile broadband .
https://msdn.microsoft.com/en-us/library/windows/hardware/ff557185(v=vs.85).aspx
https://msdn.microsoft.com/en-us/library/windows/hardware/ff559110(v=vs.85).aspx
Previously my code contain 2 INF File . One is for virtual miniport adapter INF and other is Multiplexer INF file .
Multiplexer INF File :
[INSTALL.NDI]
HKR, Ndi, FilterClass, , custom
HKR, Ndi, FilterType, 0x00010001, 0x00000002
HKR, Ndi\Interfaces, UpperRange, , “noupper”
HKR, Ndi\Interfaces, LowerRange, , “nolower”
HKR, Ndi\Interfaces, FilterMediaTypes, , “nolower, ethernet, wan”
HKR, Ndi, FilterRunType, 0x00010001, 1
Virtual adapter INF
[MYVNET.ndi]
Characteristics = 0x81 ; NCF_HAS_UI | NCF_VIRTUAL
*IfType = 0x06 ; IF_TYPE_ETHERNET_CSMACD
*MediaType = 0x00 ; NdisMedium802_3
*PhysicalMediaType = 0x0E ; NdisPhysicalMedium802_3
CopyFiles = MYVNET.CopyFiles
AddReg = MYVNET.Reg
[MYVNET.Reg]
HKR, Ndi\Interfaces, UpperRange, 0, “ndis5”
HKR, Ndi\Interfaces, LowerRange, 0, “ethernet”
So my Doubts are :
Q1 : Where I should put INF changes in my application . Is it on Virtual INF or Multiplexer INF File ?
Q2 : I should Add both Ethernet Support and Broadband Support values in INF File ?
like :
HKR, Ndi\Interfaces, UpperRange, 0, “ndis5,flpp4, flpp6”
HKR, Ndi\Interfaces, LowerRange, 0, “Ethernet,ppip”
Is it correct ?
Q3: For adding IfType , MediaType and PhysicalMediaType Should i add both Ethernet and mobile broadband change ?
like this :
*MediaType = 0x00 ,0x07 ; NdisMedium802_3 and NdisWirelssWan
is this Correct ?
After that I should add RAW IP packet . So where should I add these lines ?
NdisSetNblFlag(pNbl, NDIS_NBL_FLAGS_IS_IPV4);
value = ConvertToNetworkByteOrder(0x0800);
NET_BUFFER_LIST_INFO(pNbl, NetBufferListFrameType) = value
Is it in Miniport File or Filter file ? i have
In miniport i have :
void CMiniport::SendPackets ( ) , void CMiniport::ReturnPacket( ) , CMiniport::WanSend ( ) Functions
In Filter File i have :
CFilter::SendNetBufferLists ( ) , CFilter::SendNetBufferListsComplete ( ) , CFilter::ReceiveNetBufferLists ( ) and CFilter::ReturnNetBufferLists ( ) .
Inside which one i should add the RAW IP frame ?
please help me . thanks & reagards