| 770 | if ( (bool == 1) && (isMplsFlow == 0) ){ |
| 771 | /* Update the information db (aka RenetcolMIB) */ |
| 772 | myPtrs->currentMIB->ipv4Bytes += agCache.bytes; |
| 773 | myPtrs->currentMIB->ipv4Pckts += agCache.pkts; |
| 774 | myPtrs->currentMIB->ipv4Flow += 1; |
| 775 | switch (agCache.tProt){ |
| 776 | case 1: |
| 777 | myPtrs->currentMIB->ipv4IcmpFlowNb += 1; |
| 778 | myPtrs->currentMIB->ipv4IcmpBytesNb += agCache.bytes; |
| 779 | myPtrs->currentMIB->ipv4IcmpPktsNb += agCache.pkts; |
| 780 | break; |
| 781 | case 6: |
| 782 | myPtrs->currentMIB->ipv4TCPFlowNb += 1; |
| 783 | myPtrs->currentMIB->ipv4TCPBytesNb += agCache.bytes; |
| 784 | myPtrs->currentMIB->ipv4TCPPktsNb += agCache.pkts; |
| 785 | break; |
| 786 | case 17: |
| 787 | myPtrs->currentMIB->ipv4UDPFlowNb += 1; |
| 788 | myPtrs->currentMIB->ipv4UDPBytesNb += agCache.bytes; |
| 789 | myPtrs->currentMIB->ipv4UDPPktsNb += agCache.pkts; |
| 790 | break; |
| 791 | default: |
| 792 | myPtrs->currentMIB->ipv4OthersFlowNb += 1; |
| 793 | myPtrs->currentMIB->ipv4OthersBytesNb += agCache.bytes; |
| 794 | myPtrs->currentMIB->ipv4OthersPktsNb += agCache.pkts; |
| 795 | break; |
| 796 | } |
| 797 | if (agCache.pkts==1){ |
| 798 | myPtrs->currentMIB->ipv4FlowSizePcktsE1 += 1; |
| 799 | } else if (agCache.pkts<10) { |
| 800 | myPtrs->currentMIB->ipv4FlowSizePcktsLT10 += 1; |
| 801 | } else if (agCache.pkts<100) { |
| 802 | myPtrs->currentMIB->ipv4FlowSizePcktsLT100 += 1; |
| 803 | } else if (agCache.pkts<1000) { |
| 804 | myPtrs->currentMIB->ipv4FlowSizePcktsLT1k += 1; |
| 805 | } else if (agCache.pkts<10000) { |
| 806 | myPtrs->currentMIB->ipv4FlowSizePcktsLT10k += 1; |
| 807 | } else if (agCache.pkts>=10000) { |
| 808 | myPtrs->currentMIB->ipv4FlowSizePcktsMT10k += 1; |
| 809 | } |
| 810 | if (agCache.bytes<50){ |
| 811 | myPtrs->currentMIB->ipv4FlowSizeBytesLT50 += 1; |
| 812 | } else if (agCache.bytes<100) { |
| 813 | myPtrs->currentMIB->ipv4FlowSizeBytesLT100 += 1; |
| 814 | } else if (agCache.bytes<1000) { |
| 815 | myPtrs->currentMIB->ipv4FlowSizeBytesLT1k += 1; |
| 816 | } else if (agCache.bytes<10000) { |
| 817 | myPtrs->currentMIB->ipv4FlowSizeBytesLT10k += 1; |
| 818 | } else if (agCache.bytes<100000) { |
| 819 | myPtrs->currentMIB->ipv4FlowSizeBytesLT100k += 1; |
| 820 | } else if (agCache.bytes<1000000) { |
| 821 | myPtrs->currentMIB->ipv4FlowSizeBytesLT1M += 1; |
| 822 | } else if (agCache.bytes<10000000) { |
| 823 | myPtrs->currentMIB->ipv4FlowSizeBytesLT10M += 1; |
| 824 | } else if (agCache.bytes<100000000) { |
| 825 | myPtrs->currentMIB->ipv4FlowSizeBytesLT100M += 1; |
| 826 | } else if (agCache.bytes>=100000000) { |
| 827 | myPtrs->currentMIB->ipv4FlowSizeBytesMT100M += 1; |
| 828 | } |
| 829 | switch (agCache.dPort){ |
| 830 | case 53: |
| 831 | myPtrs->currentMIB->ipv4DNSFlowNb += 1; |
| 832 | myPtrs->currentMIB->ipv4DNSBytesNb += agCache.bytes; |
| 833 | myPtrs->currentMIB->ipv4DNSPcktsNb += agCache.pkts; |
| 834 | break; |
| 835 | case 80: |
| 836 | myPtrs->currentMIB->ipv4WebFlowNb += 1; |
| 837 | myPtrs->currentMIB->ipv4WebBytesNb += agCache.bytes; |
| 838 | myPtrs->currentMIB->ipv4WebPcktsNb += agCache.pkts; |
| 839 | break; |
| 840 | default: |
| 841 | myPtrs->currentMIB->ipv4OthersApFlowNb += 1; |
| 842 | myPtrs->currentMIB->ipv4OthersApBytesNb += agCache.bytes; |
| 843 | myPtrs->currentMIB->ipv4OthersApPcktsNb += agCache.pkts; |
| 844 | break; |
| 845 | } |
| 846 | /* end of mib update */ |
| 847 | } |
| 1240 | #endif /* IPV6LINKAGG */ |
| 1241 | /* Update the information db (aka RenetcolMIB) */ |
| 1242 | myPtrs->currentMIB->ipv6Bytes += agCache.bytes; |
| 1243 | myPtrs->currentMIB->ipv6Pckts += agCache.pkts; |
| 1244 | myPtrs->currentMIB->ipv6Flow += 1; |
| 1245 | switch (agCache.tProt){ |
| 1246 | case 1: |
| 1247 | myPtrs->currentMIB->ipv6IcmpFlowNb += 1; |
| 1248 | myPtrs->currentMIB->ipv6IcmpBytesNb += agCache.bytes; |
| 1249 | myPtrs->currentMIB->ipv6IcmpPktsNb += agCache.pkts; |
| 1250 | break; |
| 1251 | case 6: |
| 1252 | myPtrs->currentMIB->ipv6TCPFlowNb += 1; |
| 1253 | myPtrs->currentMIB->ipv6TCPBytesNb += agCache.bytes; |
| 1254 | myPtrs->currentMIB->ipv6TCPPktsNb += agCache.pkts; |
| 1255 | break; |
| 1256 | case 17: |
| 1257 | myPtrs->currentMIB->ipv6UDPFlowNb += 1; |
| 1258 | myPtrs->currentMIB->ipv6UDPBytesNb += agCache.bytes; |
| 1259 | myPtrs->currentMIB->ipv6UDPPktsNb += agCache.pkts; |
| 1260 | break; |
| 1261 | default: |
| 1262 | myPtrs->currentMIB->ipv6OthersFlowNb += 1; |
| 1263 | myPtrs->currentMIB->ipv6OthersBytesNb += agCache.bytes; |
| 1264 | myPtrs->currentMIB->ipv6OthersPktsNb += agCache.pkts; |
| 1265 | break; |
| 1266 | } |
| 1267 | if (agCache.pkts==1){ |
| 1268 | myPtrs->currentMIB->ipv6FlowSizePcktsE1 += 1; |
| 1269 | } else if (agCache.pkts<10) { |
| 1270 | myPtrs->currentMIB->ipv6FlowSizePcktsLT10 += 1; |
| 1271 | } else if (agCache.pkts<100) { |
| 1272 | myPtrs->currentMIB->ipv6FlowSizePcktsLT100 += 1; |
| 1273 | } else if (agCache.pkts<1000) { |
| 1274 | myPtrs->currentMIB->ipv6FlowSizePcktsLT1k += 1; |
| 1275 | } else if (agCache.pkts<10000) { |
| 1276 | myPtrs->currentMIB->ipv6FlowSizePcktsLT10k += 1; |
| 1277 | } else if (agCache.pkts>=10000) { |
| 1278 | myPtrs->currentMIB->ipv6FlowSizePcktsMT10k += 1; |
| 1279 | } |
| 1280 | if (agCache.bytes<50){ |
| 1281 | myPtrs->currentMIB->ipv6FlowSizeBytesLT50 += 1; |
| 1282 | } else if (agCache.bytes<100) { |
| 1283 | myPtrs->currentMIB->ipv6FlowSizeBytesLT100 += 1; |
| 1284 | } else if (agCache.bytes<1000) { |
| 1285 | myPtrs->currentMIB->ipv6FlowSizeBytesLT1k += 1; |
| 1286 | } else if (agCache.bytes<10000) { |
| 1287 | myPtrs->currentMIB->ipv6FlowSizeBytesLT10k += 1; |
| 1288 | } else if (agCache.bytes<100000) { |
| 1289 | myPtrs->currentMIB->ipv6FlowSizeBytesLT100k += 1; |
| 1290 | } else if (agCache.bytes<1000000) { |
| 1291 | myPtrs->currentMIB->ipv6FlowSizeBytesLT1M += 1; |
| 1292 | } else if (agCache.bytes<10000000) { |
| 1293 | myPtrs->currentMIB->ipv6FlowSizeBytesLT10M += 1; |
| 1294 | } else if (agCache.bytes<100000000) { |
| 1295 | myPtrs->currentMIB->ipv6FlowSizeBytesLT100M += 1; |
| 1296 | } else if (agCache.bytes>=100000000) { |
| 1297 | myPtrs->currentMIB->ipv6FlowSizeBytesMT100M += 1; |
| 1298 | } |
| 1299 | switch (agCache.dPort){ |
| 1300 | case 53: |
| 1301 | myPtrs->currentMIB->ipv6DNSFlowNb += 1; |
| 1302 | myPtrs->currentMIB->ipv6DNSBytesNb += agCache.bytes; |
| 1303 | myPtrs->currentMIB->ipv6DNSPcktsNb += agCache.pkts; |
| 1304 | break; |
| 1305 | case 80: |
| 1306 | myPtrs->currentMIB->ipv6WebFlowNb += 1; |
| 1307 | myPtrs->currentMIB->ipv6WebBytesNb += agCache.bytes; |
| 1308 | myPtrs->currentMIB->ipv6WebPcktsNb += agCache.pkts; |
| 1309 | break; |
| 1310 | default: |
| 1311 | myPtrs->currentMIB->ipv6OthersApFlowNb += 1; |
| 1312 | myPtrs->currentMIB->ipv6OthersApBytesNb += agCache.bytes; |
| 1313 | myPtrs->currentMIB->ipv6OthersApPcktsNb += agCache.pkts; |
| 1314 | break; |
| 1315 | } |
| 1316 | /* end of mib update */ |
| 1317 | isIPv6 = 0; |