CN102761425B - Charging method and device - Google Patents
Charging method and device Download PDFInfo
- Publication number
- CN102761425B CN102761425B CN201210252186.0A CN201210252186A CN102761425B CN 102761425 B CN102761425 B CN 102761425B CN 201210252186 A CN201210252186 A CN 201210252186A CN 102761425 B CN102761425 B CN 102761425B
- Authority
- CN
- China
- Prior art keywords
- user
- mentioned
- messages
- dad
- ipv6 addresses
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
Abstract
The invention discloses a kind of charging method and devices.Wherein, this method includes:Receive the DAD messages that user sends;Wherein, extension has protocol type field in the field of the DAD messages, and IPv6 addresses are carried in the DAD messages;Detect whether above-mentioned IPv6 addresses can be used;If testing result is available, the access style of above-mentioned user is determined according to above-mentioned protocol type field, corresponding billing operation is performed to above-mentioned user for different above-mentioned access styles.It by the present invention, solves the problems, such as that router device can not distinguish various access styles in the relevant technologies, so as to distinguish different access styles, make billing operation more targeted, improve the accuracy of charging, improves user's impression.
Description
Technical field
The present invention relates to the communications field, in particular to a kind of charging method and device.
Background technology
In today that broadband technology and broadband user shoot up, the crisis of V4 address spaces is long-standing, this is to cause
Internet protocol(Internet Protocol, referred to as IP)The major impetus of technological vision upgrading.China Next Generation Internet
Demonstration project(CNGI projects)It is national strategic project, the main target of the project is with internet protocol version 6
(Internet Protocol Version6, referred to as IPv6)For core, the test platform of Next Generation Internet is built.This
The IPv6 in the active flag of target China enters substantive developing stage.Operators at different levels are also stepping up paces deployment V6
Network, V6 broadband access networks have stepped into examination commercial stage.
The design concept of IPv6 basic agreements, which is desirable to V6 networks, can become the access network of a plug and play, but right
For the operator of part, need to carry out stateful(That is dynamic address allocation)Form carrys out management address, so supporting IPv6's
Dynamic host configuration protocol(Dynamic Host Configuration Protocol for IPv6, referred to as DHCPv6)It should
It transports and gives birth to, cause in the long-range broadband access network topological environmentals of existing IPv6, Neighbor Discovery Protocol(Neighbor
Discovery Protocol, referred to as NDP)Shaftless driving in agreement(Stateless Address
Auto configuration, referred to as SLAAC)Function coexists with DHCPv6 protocol address distribution functions.
Now, popular Broadband Remote Access Server(Broadband Remote Access Server, referred to as
BRAS)Router device, which provides typical IPv6 accessing users type, to be had:IPHOST(Static special line)User, DCHPv6 user
With SLAAC user.For the difference of link mode, DHCPv6 user and SLAAC user can be divided into ether link network link user
With the point-to-point protocol on Ethernet(Point-to-point Protocol Over Ethernet, referred to as PPPoE)Link
User.
Especially in IPv6 networkings, multi-host mainframe becomes the application scenarios to become more and more important.One host has in addition to one
The network connection of line(Such as Ethernet), it is also possible to there are one or more wireless connections, such as bluetooth and 802.11 agreements.
One host with physical link in addition to connecting, it is also possible to be connect with virtual network or tunneled network.For example, a host in addition to
It is connected directly to public the Internet, it is also possible to be connected to the privately owned shared network in a tunnel.IPv6 transitioning scenes are likely to increase
Add a tunnel links, for example, hosts may be with 6to4 tunnels(Remote function calls(Remote Function Call, letter
Referred to as RFC)3056)An or configured tunneling technique(RFC2893)Network is connected.
And in the practical application of BRAS router devices, tri- kinds of IPHOST static state special line, DCHPv6 and SLAAC users
Access style can carry out user network access service for a user respectively or formula coexists.Also, BRAS is route
For device equipment, then need to a user(Each user possesses a unique medium plan(Media Access
Control, referred to as MAC)Address)The multiple IPv6 addresses and prefix of distribution are managed.
Since each user may possess multiple IPv6 addresses and prefix, IPv6 addresses therein and prefix may be application
BRAS router devices provide different access styles and complete network insertion.Such as:One family user(The family gathers around
There is a unique MAC Address), due to the important means of communication of its fixed-line telephone or mobile phone for the family, use IPHOST
User mode access is linked on BRAS router devices(After i.e. by one IPv6 address of static configuration, pass through NDP agreement reports
Text asks to access and be successfully accessed to BRAS router devices);If carrier class operator also provides Interactive Internet TV
(Internet Protocol Television, referred to as IPTV)It services and gives the family, IPTV has used usual DHCPv6
User mode access is linked on same BRAS router devices(Carried out by IPTV client and BRAS router devices
DHCPv6 protocol interactions, and it is IPTV client distribution IPv6 addresses or prefix, and complete user's access);For network
Service provider needs to provide network service again to the family simultaneously, in order to facilitate customer experience, this network services provider
The SLAAC user mode accesses of plug and play are employed on same BRAS router devices, IPv6 prefixes are distributed for the family
(User is completed by the SLAAC functions in NDP agreements to access), and open network service.
In Ethernet, either IPHOST user access types, DHCPv6 user access types or SLAAC user
Access style can all distribute one or more IPv6 address or a prefix or multiple prefixes to user.And for institute
For some IPv6 clients, no matter use which kind of access way, either static configuration address still dynamically distribute address and
Prefix no matter distribution is IPv6 addresses or IPv6 prefixes, can all carry out the duplicate address detection of IPv6 addresses
(Duplicate Address Detection, referred to as DAD).If what it is to the distribution of IPv6 clients is IPv6 prefixes, IPv6
Client can generally generate an IPv6 address according to distribution IPv6 prefixes, and the specific address rule that generates refers to IPv6 communications association
It assesses a bid for tender standard, this will not be detailed here, subsequently carries out DAD detections to the IPv6 addresses of generation.
In short, each network node is want, using that must carry out DAD detections before an IPv6 address, confirming this link model
It encloses interior without that behind repeat to address (RA), this IPv6 address could be used to carry out network service and data service.DAD detections are to pass through DAD
Message can be sent 1 to 6 time the function realized, DAD messages ordinary circumstance(Specific detection number is related to specific equipment), every time
Transmission time interval is 1 second, and after sending the last one DAD the message ends, after waiting for 1 second, DAD reports are replied if do not received
The reply message of text, then it is assumed that above-mentioned IPv6 addresses are available in the range of this link-local, and DAD messages are replied if received
Reply message, then it is assumed that above-mentioned IPv6 addresses are disabled in the range of this link-local.
DAD messages and neighbor advertisement(NeighborAdvertise, referred to as NA)Message is all in NDP protocol massages
One kind, they are the sixth version Internet Control Information Protocol used(Internet Control Message Protocol
Version6, referred to as ICMPv6)Encapsulation format.
Fig. 1 is the neighbor request according to the relevant technologies(Neighbor Solicit, referred to as NS)The encapsulation format of message
Schematic diagram, as shown in Figure 1, the 0-8 positions in 32 of NS messages are Type(Type), generally take the 8-16 positions in 135,32 to be
Code(Code), it is Checksum generally to take the 16-32 positions in 0,32(Verification and), i.e., the verification of ICMP and;In NS messages
Reserved(Reserved field)It is not used by, it is necessary to be initialized as 0, and the person of being received ignores by sender;In NS messages
Target Address(Destination address)It is the target ip address of request, it is necessary to not be multicast address;Option in NS messages
(Optional option)That is source link layer address option.
Fig. 2 is according to the encapsulation format schematic diagram of the NA messages of the relevant technologies, as shown in Fig. 2, in 32 of NA messages
0-8 are Type(Type), it is Code generally to take the 8-16 positions in 136,32(Code), generally take the 16-32 in 0,32
Position is Checksum(Verification and), i.e., the verification of ICMP and;Reserved in NA messages(Reserved field)In R label be road
It is marked by device, S labels are request marks, and O labels are overlay marks, Reserved(Reserved field)It is not used by, it is necessary to be sent out
The person of sending is initialized as 0, and the person of being received ignores;Target Address in NA messages(Destination address)It is the Target IP of request
Address, it is necessary to not be multicast address;Option in NA messages(Optional option)That is target link-layer address option.
If source address is the IPv6 addresses do not formulated in the IP heads of the IPv6 in NS messages(I.e.::, full zero-address)When,
Then NS messages at this time are defined as DAD messages.Destination address in DAD messages and NA messages(Target Address)Field is used
To store the IPv6 address contents for needing to be detected repeatedly.
Regulation is for some network node in IPv6 basic agreements, if it is to be understood that whether the IPv6 addresses are at this
It can be used in the range of ground link, it is necessary to DAD is carried out in the range of link-local(Repeat to address (RA))Detection.It needs to report DAD
Literary multicast is sent on all IPv6 nodes in the range of link-local, wherein, being carried in DAD messages needs what is be detected
IPv6 addresses, all IPv6 nodes are required for receiving and processing this message, if it find that be used for needing on this node by
The IPv6 addresses of detection, then multicast replies NA messages to send DAD messages node, wherein, carried in NA messages detected
IPv6 addresses, when the node of DAD messages receives this NA message, then know the IPv6 addresses in DAD messages in this link range
Inside conflict, it is impossible to be used.Citing introduction is carried out to above-mentioned DAD detection process below.
Fig. 3 is according to the network topology networking schematic diagram of the DAD detection process of the relevant technologies, as shown in figure 3, A nodes are
BRAS router devices, it is assumed that distributed IPv6 addresses to B node, D nodes and E nodes and do not conflicted.When C nodes
(PDA computers)When no matter being assigned to an IPv6 address by any mode, it is required for the multicast in the range of entire link-local
Send a DAD duplicate message.
Assuming that the address of C nodes distribution is 100::4:4:When 4/128, then C nodes can will carry 100::4:4:4/128 ground
The DAD of location is sent respectively to A, B, D and E node.3 DAD messages, the time that each DAD messages are sent are sent under normal circumstances
Between be divided into 1 second.Because the feelings that the IPv6 addresses of A, B, D and E node in the range of link-local do not conflict with C addresss of node
Condition so when A, B, D and E node receive the DAD messages of C nodes transmission, does not reply any message.Until C nodes last
After a DAD messages are sent, C nodes are delayed again after waiting 1 second, confirm the NA messages for not receiving A, B, D and E node reverts back, then
Think that this address can use in the range of link-local.
Assuming that the address of C nodes distribution is 100::1:1:When 1/128, then C nodes can will carry 100::1:1:1/128 ground
The DAD of location is sent respectively to A, B, D and E node.3 DAD messages, the time that each DAD messages are sent are sent under normal circumstances
Between be divided into 1 second.Because after B node receives the DAD messages of C nodes transmission, find the detected IPv6 addresses in DAD messages(I.e.
Destination address in DAD messages)It is repeated with the address of machine, then multicast sends NA messages and gives C nodes.When C nodes are being sent
Have received NA messages in the time of DAD messages, and when the destination address in NA messages is identical with oneself DAD detections address, then C
Node thinks that the IPv6 addresses for having had node in the range of link-local and having used in advance repeat, then C nodes think that this address is saved in C
Point cannot use, and be link repeat to address (RA).
For the domestic consumer referred in above-described embodiment, BRAS router devices receive in possible same amount of time
The DAD messages of multiple IPv6 addresses can then have the IPv6 addresses for being detected in numerous DAD messages, it is impossible to which which kind of differentiation is
The situation of the distribution address of access style, leads to the user management module of BRAS router devices to address administration confusion reigned.
And for a user, the confusion of address administration can lead to the confusion of the charging case for service.Because it provides the user with
Each service is assigned with different IPv6 addresses and employs different access style accesses.For the access style of each service
It needs to trace to the source respectively with the IPv6 addresses of distribution(It reports)To verification, mandate and charging(Authentication、
Authorization, Accounting, referred to as AAA)Server carries out charging respectively.
For example, for one family, telephonic communication business is linked into BRAS roads using IPHOST user access types
By device equipment, the address of static configuration is 100::1:1:1/128, and need to carry out DAD three times and detect;IPTV service uses
DHCPv6 user access types are linked into BRAS router devices, are assigned to an IPv6 prefix 100::/ 32, and generate one
A IPv6 addresses 100::2:2:2/128, this address also carries out DAD detections three times;IPTV service accesses class using SLAAC user
Type is linked into BRAS router devices, is assigned to an IPv6 prefix 100::/ 64, and generate an IPv6 address 100::3:
3:3/128, this address also carries out DAD detections three times;In case of three kinds of services access simultaneously or the time is close or net
Situations such as network postpones, same BRAS router devices may receive many mixed and disorderly DAD messages, and BRAS router devices are simultaneously
It cannot distinguish between 100::1:1:1/128、100::2:2:2/128 and 100::3:3:Which kind of access style 3/128 these three addresses are
The address of distribution and prefix, so as to cause cannot be directed to each service each access style be traceable to aaa server carry out charging,
So as to cause the confusion of the charging case for service.
It the problem of various access styles can not being distinguished for router device in the relevant technologies, not yet proposes at present
Effective solution.
Invention content
The problem of various access styles can not being distinguished for router device in the relevant technologies, the present invention provides
A kind of charging method and device, at least to solve the above problems.
According to an aspect of the invention, there is provided a kind of charging method, this method include:Receive the DAD that user sends
Message;Wherein, extension has protocol type field in the field of the DAD messages, and IPv6 addresses are carried in the DAD messages;Detection
Whether above-mentioned IPv6 addresses can be used;If testing result is available, determine above-mentioned user's according to above-mentioned protocol type field
Access style performs corresponding billing operation for different above-mentioned access styles to above-mentioned user.
Extension has protocol type field that can include in the field of above-mentioned DAD messages:By the reserved field of above-mentioned DAD messages
Front two, be extended to above-mentioned protocol type field.
The access style for determining above-mentioned user according to above-mentioned protocol type field can include:In above-mentioned protocol type field
Value be 0 when, determine above-mentioned user above-mentioned access style be IPHOST types;When the value of above-mentioned protocol type field is 1,
The above-mentioned access style for determining above-mentioned user is SLACC types;When the value of above-mentioned protocol type field is 2 or 3, determine above-mentioned
The above-mentioned access style of user is DCHPv6 types.
It detects above-mentioned IPv6 addresses and whether can be used and can include:Judge the above-mentioned IPv6 addresses carried in above-mentioned DAD messages
It is whether identical with the address of message interface;It is if identical, it is determined that above-mentioned IPv6 addresses are unavailable;If it is not the same, it then determines
Above-mentioned IPv6 addresses can be used.
Detect above-mentioned IPv6 addresses it is whether available after, the above method can also include:If above-mentioned testing result is not
It can use, then send notification packet to above-mentioned user, wherein, above-mentioned IPv6 addresses, above-mentioned notice are carried in above-mentioned notification packet
Message is used to indicate above-mentioned user offline.
Above-mentioned notification packet can be NA messages.
According to another aspect of the present invention, a kind of message accounting is provided, which includes:Message receiving module, is used for
Receive the DAD messages that user sends;Wherein, extension has protocol type field in the field of the DAD messages, is taken in the DAD messages
With IPv6 addresses;Detection module, for detecting whether above-mentioned IPv6 addresses can be used;Determination type module, in above-mentioned inspection
In the case of the testing result of survey module is available, then the access style of above-mentioned user is determined according to above-mentioned protocol type field;
Charging module performs accordingly above-mentioned user for being directed to the different above-mentioned access styles that the above-mentioned type determining module determines
Billing operation.
Above-mentioned message receiving module can include:Expanding element, for by before the reserved field of above-mentioned DAD messages two
Position, is extended to above-mentioned protocol type field.
The above-mentioned type determining module can include:First kind determination unit, in the value of above-mentioned protocol type field
When being 0, the above-mentioned access style for determining above-mentioned user is IPHOST types;Second Type determination unit, in above-mentioned agreement
When the value of type field is 1, the above-mentioned access style for determining above-mentioned user is SLACC types;Third type determining units, are used for
When the value of above-mentioned protocol type field is 2 or 3, the above-mentioned access style for determining above-mentioned user is DCHPv6 types.
Above-mentioned detection module can include:Judging unit, for judging the above-mentioned IPv6 addresses carried in above-mentioned DAD messages
It is whether identical with the address of message interface;First determination unit, for being identical feelings in the judging result of above-mentioned judging unit
Condition determines that above-mentioned IPv6 addresses are unavailable;Second determination unit, for being different in the judging result of above-mentioned judging unit
Situation determines that above-mentioned IPv6 addresses can be used.
Above device can also include:Message sending module, for being unavailable in the testing result of above-mentioned detection module
In the case of, notification packet is sent to above-mentioned user, wherein, above-mentioned IPv6 addresses are carried in above-mentioned notification packet, it is above-mentioned logical
It accuses message and is used to indicate above-mentioned user offline.
Above-mentioned notification packet can be NA messages.
By the present invention, the Extended Protocol type field in the field of DAD messages, after receiving the DAD messages that user sends,
Whether the IPv6 addresses carried in detection DAD messages can be used, if testing result is available, according to above-mentioned protocol type field
It determines the access style of above-mentioned user, corresponding billing operation, solution is performed to above-mentioned user for different above-mentioned access styles
The problem of router device can not distinguish various access styles in the relevant technologies of having determined, so as to distinguish different connect
Enter type, make billing operation more targeted, improve the accuracy of charging, improve user's impression.
Description of the drawings
Attached drawing described herein is used to provide further understanding of the present invention, and forms the part of the application, this hair
Bright illustrative embodiments and their description do not constitute improper limitations of the present invention for explaining the present invention.In the accompanying drawings:
Fig. 1 is the encapsulation format schematic diagram according to the NS messages of the relevant technologies;
Fig. 2 is the encapsulation format schematic diagram according to the NA messages of the relevant technologies;
Fig. 3 is the network topology networking schematic diagram according to the DAD detection process of the relevant technologies;
Fig. 4 is the flow chart of charging method according to embodiments of the present invention;
Fig. 5 is the form schematic diagram for optimizing DAD messages in NDP agreements according to embodiments of the present invention;
The flow chart that Fig. 6 is IPv6 addresses distribution according to embodiments of the present invention and follow-up DAD is detected;
Fig. 7 is the structure diagram of message accounting according to embodiments of the present invention;
Fig. 8 is the concrete structure block diagram of message accounting according to embodiments of the present invention.
Specific embodiment
Come that the present invention will be described in detail below with reference to attached drawing and in conjunction with the embodiments.It should be noted that do not conflicting
In the case of, the feature in embodiment and embodiment in the application can be combined with each other.
DAN in the relevant technologies is detected, same BRAS router devices may receive many mixed and disorderly DAD reports
Text since access style cannot be distinguished, may result in the confusion of charging process.Based on this, an embodiment of the present invention provides one
Kind charging method and device, are described in detail below by embodiment.
A kind of charging method is present embodiments provided, this method is typically employed in router(Such as BRAS equipment)On, Fig. 4
It is the flow chart of charging method according to embodiments of the present invention, as shown in figure 4, this method includes the following steps(Step S402- is walked
Rapid S406):
Step S402, BRAS equipment receive the duplicate address detection DAD messages that user sends;Wherein, the word of the DAD messages
Extension has protocol type field in section, and IPv6 addresses are carried in the DAD messages;
Step S404, BRAS equipment detect whether above-mentioned IPv6 addresses can be used;
Step S406 if testing result is available, determines above-mentioned use if BRAS equipment according to above-mentioned protocol type field
The access style at family performs corresponding billing operation for different above-mentioned access styles to above-mentioned user.
By above-described embodiment, BRAS equipment Extended Protocol type field in the field of DAD messages receives user and sends
DAD messages after, detect whether the IPv6 addresses that carry in DAD messages can be used, if testing result is available, BRAS equipment
The access style of above-mentioned user is determined according to above-mentioned protocol type field, above-mentioned user is held for different above-mentioned access styles
The corresponding billing operation of row, solves the problems, such as that router device can not distinguish various access styles in the relevant technologies,
So as to distinguish different access styles, make billing operation more targeted, improve the accuracy of charging, improve user
Impression.
BRAS equipment Extended Protocol type field in the field of DAD messages can be accomplished in several ways, this implementation
Example provides a kind of preferred embodiment, i.e., by the front two of the reserved field of DAD messages, is extended to protocol type field.Fig. 5
It is the form schematic diagram for optimizing DAD messages in NDP agreements according to embodiments of the present invention, as shown in figure 5, the DAD reports after optimization
Text is on the basis of original NS standard messages form, by 32 reserved fields in original message(Reserved)In preceding 10
Position is extended.The front two of the reserved field of former NS messages is extended to protocol type(Protocol Type), protocol type
Value range is 0-3, and back to back 8 Bits Expandings below are prefix length(Prefix Lenth), the value range of prefix length
For 1-128.Regulation and application for protocol type and prefix length are described as follows:
When protocol type field value is 0, IPHOST user is represented(I.e. static configuration IPv6 addresses when and send out DAD report
Text), prefix length field value is 128.
When protocol type field value is 1, SLACC user is represented(Given birth to by the prefix of SLAAC function distributions in NDP
Into IPv6 addresses and the DAD messages that send out), prefix length field value is 1-128.Its prefix length field value must be with
The IPv6 prefixes of SLAAC distribution are identical.When prefix length field value is 0, invalid value is represented, recipient ignores this field.
When protocol type field value is 2, represent that DCHPv6 user distributes the situation of address(I.e. DHCPv6 agreements are to user point
DAD messages with the triggering of IPv6 addresses), prefix length field value is 128.
When protocol type field value is 3, represent that DCHPv6 user distributes the situation of prefix(Before being distributed by DHCPv6
The IPv6 addresses sewed and generated and the DAD messages sent out), prefix length field value is 1-128.Its prefix length field value must
It must be identical with the IPv6 prefixes that DHCPv6 is distributed.When prefix length field value is 0, invalid value is represented, recipient ignores this word
Section.
The form of optimization DAD messages based on above-mentioned Fig. 5 introductions, present embodiments provides a kind of preferred embodiment, i.e.,
BRAS equipment determines that the access style of user includes according to protocol type field:When the value of protocol type field is 0, BRAS is set
The access style of standby determining user is IPHOST types;When the value of protocol type field is 1, BRAS equipment determines connecing for user
Enter type for SLACC types;When the value of protocol type field is 2 or 3, BRAS equipment determines that the access style of user is
DCHPv6 types.By this way, it provides the foundation subsequently to carry out billing operation according to different access styles.
For the whether available detection process in IPv6 addresses, identical with the detection process in the relevant technologies, the present embodiment carries
A kind of preferred embodiment is supplied, i.e., whether BRAS equipment detection IPv6 addresses are available includes:BRAS equipment is judged in DAD messages
Whether the IPv6 addresses of carrying and the address of message interface are identical;It is if identical, it is determined that IPv6 addresses are unavailable;If not phase
Together, it is determined that IPv6 addresses can be used.It is not available in testing result, BRAS equipment sends notice report to above-mentioned user
Text, wherein, above-mentioned IPv6 addresses are carried in the notification packet, above-mentioned notification packet is used to indicate the address that above-mentioned user reaches the standard grade
There is repetition with the address in the range of link-local, used convenient for user's re-request or applied address.Above-mentioned notice report
Text can be NA messages.
The realization process of above-described embodiment is described in detail with reference to preferred embodiments and drawings.
The flow chart that Fig. 6 is IPv6 addresses distribution according to embodiments of the present invention and follow-up DAD is detected, as shown in fig. 6, should
Flow includes the following steps(Step S602- steps S616):
Step S602, IPv6 domestic consumer use different agreements or different access styles, are set to BRAS routers
Standby request IPv6 network services.
Step S604, when BRAS router devices receive user reach the standard grade request when, according to subscription client apply
Different access protocols or access style distributes multiple IPv6 addresses, and provide different services for user.
Step S606, BRAS router device notifies user to be successfully accessed, and replys IPv6 addresses to user.
After step S608, BRAS router device distributes address or prefix success to IPv6 domestic consumer, domestic customers
The address that end can use the address of distribution or the prefix of distribution and generate, carries out DAD detections.BRAS router devices, which receive, to be used
The DAD messages that family is sent judge that the address that the destination address in the DAD messages of user receives message interface with BRAS routers is
It is no identical, if identical, then it is assumed that above-mentioned IPv6 addresses are unavailable, step S610 performed, if it is not the same, then thinking above-mentioned
IPv6 addresses can be used, and perform step S612.
Step S610, BRAS router device sends NA messages to user, and notifies user offline.
Step S612, BRAS router device is likely to be received the DAD that the users such as DHCPv6, SLAAC and IPHOST send
Message, BRAS equipment need to handle this DAD message, according to the protocol type field in DAD messages, the numerous DAD areas that will be received
Separate which kind of agreement it uses and access style is accessed, and needs to check that DHCPv6 and SLAAC gives user's
Whether whether prefix length equal with the prefix length of DAD messages, if unequal, then it is assumed that non-DHCPv6 and SLAAC give
The address of the prefix generation of user, and do not need to increase to user management module.The ground distributed by DHCPv6 and IPHOST
Location does not need to check the prefix length field in DAD messages, it is only necessary to distinguish protocol type field.If after the completion of DAD detections,
The IPv6 addresses for the IPv6 addresses or generation for distributing the modes such as DHCPv6, SLAAC and IPHOST to user is needed to be added to
User management module.
Step S614, user management module will distribute to the IPv6 addresses of user or the IPv6 of generation according to protocol type
Address is reported to aaa server using different types respectively.Aaa server allow for a certain specific access class
Type carries out charging respectively.
Step S616, after user offline is determined, notice aaa server stops charging.
Corresponding to above-mentioned charging method, a kind of message accounting is present embodiments provided, which generally can be positioned at road
By device(Such as BRAS equipment)On, it is used to implement above-described embodiment.Fig. 7 is the structure of message accounting according to embodiments of the present invention
Block diagram, as shown in fig. 7, the device includes:Message receiving module 10, detection module 20, determination type module 30 and charging module
40.The structure is illustrated below.
Message receiving module 10, for receiving the DAD messages of user's transmission;Wherein, being extended in the field of the DAD messages has
Protocol type field carries IPv6 addresses in the DAD messages;
Detection module 20 is connected to message receiving module 10, for detecting whether above-mentioned IPv6 addresses can be used;
Determination type module 30 is connected to detection module 20, for being available in the testing result of above-mentioned detection module 20
In the case of, then the access style of above-mentioned user is determined according to above-mentioned protocol type field;
Charging module 40 is connected to determination type module 30, for being directed to the determining difference of the above-mentioned type determining module 30
Above-mentioned access style corresponding billing operation is performed to above-mentioned user.
By above-described embodiment, the Extended Protocol type field in the field of DAD messages, message receiving module 10, which receives, to be used
After the DAD messages that family is sent, detection module 20 detects whether the IPv6 addresses carried in DAD messages can be used, if testing result
It is available, then determination type module 30 determines the access style of above-mentioned user, charging module 40 according to above-mentioned protocol type field
Corresponding billing operation is performed to above-mentioned user for different access styles, solving router device in the relevant technologies can not
The problem of being distinguished to various access styles so as to distinguish different access styles, makes billing operation more targeted,
The accuracy of charging is improved, improves user's impression.
Above-mentioned message receiving module 10 further includes:Expanding element, for by before the reserved field of above-mentioned DAD messages two
Position, is extended to above-mentioned protocol type field.It has been carried out introducing before specific extended mode, details are not described herein.
Access style can be determined according to protocol type field, therefore, present embodiments provide a kind of preferred embodiment,
Fig. 8 is the concrete structure block diagram of message accounting according to embodiments of the present invention, as shown in figure 8, the device is in addition to including above-mentioned Fig. 7
In modules except, the above-mentioned type determining module 30 further includes:First kind determination unit 32, Second Type determination unit
34 and third type determining units 36.The structure is illustrated below.
First kind determination unit 32, for when the value of above-mentioned protocol type field is 0, determining that above-mentioned user's is above-mentioned
Access style is static special line IPHOST types;Alternatively,
Second Type determination unit 34, for when the value of above-mentioned protocol type field is 1, determining that above-mentioned user's is above-mentioned
Access style is shaftless driving SLACC types;Alternatively,
Third type determining units 36, for when the value of above-mentioned protocol type field is 2 or 3, determining above-mentioned user's
Above-mentioned access style is the dynamic host configuration protocol DCHPv6 types for supporting IPv6.
Whether detection module 20 detects above-mentioned IPv6 addresses and can be used and can be realized by preferred embodiment below, i.e., above-mentioned inspection
Module 20 is surveyed to include:Judging unit, for judge the address of the IPv6 addresses and message interface carried in DAD messages whether phase
Together;First determination unit for being identical situation in the judging result of above-mentioned judging unit, determines that above-mentioned IPv6 addresses can not
With;Second determination unit for being different situation in the judging result of above-mentioned judging unit, determines that above-mentioned IPv6 addresses can
With.
In the case that above-mentioned detection module 20 testing result to be not available, above device can also include:Message is sent out
Module is sent, for being not available in the testing result of above-mentioned detection module, notification packet is sent to above-mentioned user,
In, carry above-mentioned IPv6 addresses in above-mentioned notification packet, above-mentioned notification packet be used to indicate address that above-mentioned user reaches the standard grade with
There is repetition in address in the range of link-local, is used convenient for user's re-request or applied address.Above-mentioned notification packet
Generally can be NA messages.
As can be seen from the above description, the present invention enables to BRAS equipment effectively to manage IPv6 addresses, and right
For a variety of access styles simultaneously user reach the standard grade distinguish charging propose solution.In a variety of IPv6 access styles and of the same race
In the case that IPv6 access styles distribute numerous addresses, when the address of the numerous generation addresses of user or distribution carries out DAD detections
When, can distinguish it is for being which kind of access protocol or access way.
Obviously, those skilled in the art should be understood that all or part of step in the above method can by program come
Related hardware is instructed to complete, above procedure can be stored in computer readable storage medium, such as read-only memory, disk or light
Disk etc..Optionally, all or part of step of above-described embodiment can also be realized using one or more integrated circuits.Accordingly
Ground, the form that hardware may be used in each module/unit in above-described embodiment are realized, can also use the shape of software function module
Formula is realized.
Each module or each step of the present invention can realize that they can concentrate on single with general computing device
It on computing device or is distributed on the network that multiple computing devices are formed, optionally, they can be held with computing device
Capable program code is realized, is performed it is thus possible to be stored in storage device by computing device, and certain
In the case of, it can be with the steps shown or described are performed in an order that is different from the one herein or is fabricated to them respectively each
Multiple modules in them or step are fabricated to single integrated circuit module to realize by integrated circuit modules.In this way, this
Invention is not limited to any specific hardware and software and combines.
The foregoing is only a preferred embodiment of the present invention, is not intended to restrict the invention, for the skill of this field
For art personnel, the invention may be variously modified and varied.All within the spirits and principles of the present invention, that is made any repaiies
Change, equivalent replacement, improvement etc., should all be included in the protection scope of the present invention.
Claims (10)
1. a kind of charging method, which is characterized in that including:
Receive the duplicate address detection DAD messages that user sends;Wherein, extension has protocol type in the field of the DAD messages
Field carries internet protocol version 6IPv6 addresses in the DAD messages;
Detect whether the IPv6 addresses can be used;
If testing result is available, the access style of the user is determined according to the protocol type field, for difference
The access style corresponding billing operation is performed to the user;
Wherein, the access style for determining the user according to the protocol type field includes:In the protocol type field
It is worth when being 0, the access style for determining the user is static special line IPHOST types;In the value of the protocol type field
When being 1, the access style for determining the user is shaftless driving SLACC types;In the protocol type
When the value of field is 2 or 3, the access style for determining the user is the dynamic host configuration protocol DCHPv6 for supporting IPv6
Type.
2. according to the method described in claim 1, it is characterized in that, being extended in the field of the DAD messages has protocol class type-word
Section includes:
By the front two of the reserved field of the DAD messages, it is extended to the protocol type field.
3. according to the method described in claim 1, it is characterized in that, detect whether the IPv6 addresses are available to include:
Judge whether the address of the IPv6 addresses and message interface carried in the DAD messages is identical;
It is if identical, it is determined that the IPv6 addresses are unavailable;
If it is not the same, then determine that the IPv6 addresses can be used.
4. according to the method described in claim 1, it is characterized in that, detect the IPv6 addresses it is whether available after, the side
Method further includes:
If the testing result is unavailable, notification packet is sent to the user, wherein, it is carried in the notification packet
There are the IPv6 addresses, the notification packet is used to indicate the user offline.
5. according to the method described in claim 4, it is characterized in that, the notification packet is neighbor advertisement NA messages.
6. a kind of message accounting, which is characterized in that including:
Message receiving module, for receiving the duplicate address detection DAD messages of user's transmission;Wherein, the field of the DAD messages
Middle extension has protocol type field, and internet protocol version 6IPv6 addresses are carried in the DAD messages;
Detection module, for detecting whether the IPv6 addresses can be used;
Determination type module, for being available in the testing result of the detection module, then according to the protocol class
Type-word section determines the access style of the user;
Charging module performs phase for being directed to the different access styles that the determination type module determines to the user
The billing operation answered;
Wherein, the determination type module includes:
First kind determination unit, for when the value of the protocol type field is 0, determining the access class of the user
Type is static special line IPHOST types;
Second Type determination unit, for when the value of the protocol type field is 1, determining the access class of the user
Type is shaftless driving SLACC types;
Third type determining units, for when the value of the protocol type field is 2 or 3, determining that the described of the user connects
It is to support the dynamic host configuration protocol DCHPv6 types of IPv6 to enter type.
7. device according to claim 6, which is characterized in that the message receiving module includes:
Expanding element, for by the front two of the reserved field of the DAD messages, being extended to the protocol type field.
8. device according to claim 6, which is characterized in that the detection module includes:
Judging unit, for judging whether the address of the IPv6 addresses and message interface carried in the DAD messages is identical;
First determination unit for being identical situation in the judging result of the judging unit, determines the IPv6 addresses not
It can use;
Second determination unit for being different situation in the judging result of the judging unit, determines the IPv6 addresses
It can use.
9. device according to claim 6, which is characterized in that described device further includes:
Message sending module for being not available in the testing result of the detection module, is sent to the user
Notification packet, wherein, the IPv6 addresses are carried in the notification packet, the notification packet is used to indicate under the user
Line.
10. device according to claim 9, which is characterized in that the notification packet is neighbor advertisement NA messages.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201210252186.0A CN102761425B (en) | 2012-07-20 | 2012-07-20 | Charging method and device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201210252186.0A CN102761425B (en) | 2012-07-20 | 2012-07-20 | Charging method and device |
Publications (2)
Publication Number | Publication Date |
---|---|
CN102761425A CN102761425A (en) | 2012-10-31 |
CN102761425B true CN102761425B (en) | 2018-06-12 |
Family
ID=47055752
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201210252186.0A Active CN102761425B (en) | 2012-07-20 | 2012-07-20 | Charging method and device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN102761425B (en) |
Families Citing this family (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104753793B (en) * | 2013-12-26 | 2018-03-30 | 联芯科技有限公司 | The method of stateful management access terminal under stateless IPv6 configurations |
CN109327634B (en) * | 2017-07-31 | 2020-08-07 | 贵州白山云科技股份有限公司 | Method and device for solving repeated charging |
CN110072073B (en) * | 2019-03-14 | 2021-01-01 | 视联动力信息技术股份有限公司 | Terminal calling service control method and device, electronic equipment and storage medium |
CN112929284A (en) * | 2021-01-29 | 2021-06-08 | 烽火通信科技股份有限公司 | ND message identification method and system under IPv6VXLAN scene |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1692606A (en) * | 2003-01-15 | 2005-11-02 | 三星电子株式会社 | Method of automatically registering an IP address and domain name in IP protocol version 6 |
CN1901551A (en) * | 2005-07-19 | 2007-01-24 | 上海贝尔阿尔卡特股份有限公司 | Repeat address detecting method and its device for supporting IPv6 two layer access net |
WO2007128239A1 (en) * | 2006-04-30 | 2007-11-15 | Huawei Technologies Co., Ltd. | System for implementing mobile ipv6 and method for establishing user link in the system |
CN101547383A (en) * | 2008-03-26 | 2009-09-30 | 华为技术有限公司 | Access authentication method, access authentication system and related equipment |
Family Cites Families (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2005295217A (en) * | 2004-03-31 | 2005-10-20 | Toshiba Corp | Communication apparatus, name resolution method and program |
CN101127629B (en) * | 2006-08-18 | 2012-08-22 | 华为技术有限公司 | Policy and billing execution device, online billing system and method for communication system |
CN101540983B (en) * | 2008-03-19 | 2012-03-07 | 中兴通讯股份有限公司 | Method for charging in mobile network |
-
2012
- 2012-07-20 CN CN201210252186.0A patent/CN102761425B/en active Active
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1692606A (en) * | 2003-01-15 | 2005-11-02 | 三星电子株式会社 | Method of automatically registering an IP address and domain name in IP protocol version 6 |
CN1901551A (en) * | 2005-07-19 | 2007-01-24 | 上海贝尔阿尔卡特股份有限公司 | Repeat address detecting method and its device for supporting IPv6 two layer access net |
WO2007128239A1 (en) * | 2006-04-30 | 2007-11-15 | Huawei Technologies Co., Ltd. | System for implementing mobile ipv6 and method for establishing user link in the system |
CN101547383A (en) * | 2008-03-26 | 2009-09-30 | 华为技术有限公司 | Access authentication method, access authentication system and related equipment |
Also Published As
Publication number | Publication date |
---|---|
CN102761425A (en) | 2012-10-31 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN102984288B (en) | A kind of method and system of automatic management IPv6 address conflicts | |
KR100886433B1 (en) | IPv6 Support Method for Bridge Extension Using Wireless Communications System | |
US8887234B2 (en) | Network service selection and authentication and stateless auto-configuration in an IPv6 access network | |
CN100583904C (en) | Automatic configuration method for host address in IPV6 network | |
CN101753460B (en) | Method and device for processing internet protocol version 6(IPV6) routing prefix | |
CN101729500B (en) | Method, device and system for identifying IP session | |
US7760666B2 (en) | Method of generating and managing connection identifiers for supporting multicast for each group in IPv6-based wireless network and network interface using the method | |
CN101621414A (en) | Method and apparatus for discovering network resource and topology | |
CN101443750A (en) | Techniques for load balancing over a cluster of subscriber-aware application servers | |
US20020178235A1 (en) | Multicast packet distribution method, system, address structure of packet and mobile station | |
CN113595897B (en) | Path detection method and device | |
CN103368949A (en) | A method of configuring a communication device | |
CN101542983A (en) | Methods and arrangements for LAN emulation in mobile networks | |
CN107612809A (en) | A kind of multicast list synchronous method and equipment | |
US8755354B2 (en) | Methods and apparatus for broadcast optimization in mobile IP | |
CN102761425B (en) | Charging method and device | |
CN102546407B (en) | File transmitting method and device | |
CN111246453A (en) | Data transmission method, user plane network element and control plane network element | |
CN102984295A (en) | Mobile terminal and address allocation method thereof | |
CN105227466A (en) | Communication processing method and device | |
CN107547665A (en) | A kind of method, equipment and the system of dhcp address distribution | |
EP2675117A1 (en) | Routing method and device for host in multi-homing site | |
US8311552B1 (en) | Dynamic allocation of host IP addresses | |
CN102651862A (en) | IP (Internet Protocol) address configuration method of WAP (Wireless Application Protocol) gateway and equipment thereof | |
CN103108056A (en) | Device and method capable of achieving subscriber identifier and locator separation network |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |