IDA C++ SDK 9.2
Loading...
Searching...
No Matches
netnode.hpp
Go to the documentation of this file.
1/*
2 * Interactive disassembler (IDA).
3 * Copyright (c) 1990-2025 Hex-Rays
4 * ALL RIGHTS RESERVED.
5 *
6 */
7
8#ifndef _NETNODE_HPP
9#define _NETNODE_HPP
10
11#include <functional>
12
97
98#include <range.hpp>
99
100//--------------------------------------------------------------------------
102const int MAXNAMESIZE = 512;
103
105const int MAX_NODENAME_SIZE = 32*1024;
106
108const int MAXSPECSIZE = 1024;
109
113#ifdef __EA64__
115#else
116typedef nodeidx32_t nodeidx_t;
117#endif
118
120#define BADNODE nodeidx_t(-1)
121
126const uchar atag = 'A';
127const uchar stag = 'S';
128const uchar htag = 'H';
129const uchar vtag = 'V';
130const uchar ntag = 'N';
131const uchar ltag = 'L';
133
134// Internal bit used to request ea2node() mapping of alt and sup indexes
135const int NETMAP_IDX = 0x100;
136// Internal bit used to request ea2node() mapping of alt values.
137// Such values are stored after being incremented by one.
138const int NETMAP_VAL = 0x200;
139// Internal bit used to make sure a string obtained with getblob() is
140// null-terminated.
141const int NETMAP_STR = 0x400;
142// Internal bit: use 8-bit indexes.
143const int NETMAP_X8 = 0x800;
144// Internal bit: use 8-bit values.
145const int NETMAP_V8 = 0x1000;
146// Internal bit: value is a netnode index
147const int NETMAP_VAL_NDX = 0x2000;
148
151{
152 virtual bool should_skip(nodeidx_t ea) = 0;
153};
154
158class netnode;
159class linput_t;
160idaman bool ida_export netnode_check(netnode *, const char *name, size_t namlen, bool create);
161idaman void ida_export netnode_kill(netnode *);
162idaman bool ida_export netnode_start(netnode *);
163idaman bool ida_export netnode_end(netnode *);
164idaman bool ida_export netnode_next(netnode *);
165idaman bool ida_export netnode_prev(netnode *);
166idaman ssize_t ida_export netnode_get_name(nodeidx_t num, qstring *out);
167idaman bool ida_export netnode_rename(nodeidx_t num, const char *newname, size_t namlen);
168idaman ssize_t ida_export netnode_valobj(nodeidx_t num, void *buf, size_t bufsize);
169idaman ssize_t ida_export netnode_valstr(nodeidx_t num, char *buf, size_t bufsize);
170idaman ssize_t ida_export netnode_qvalstr(nodeidx_t num, qstring *buf);
171idaman bool ida_export netnode_set(nodeidx_t num, const void *value, size_t length);
172idaman bool ida_export netnode_delvalue(nodeidx_t num);
173idaman nodeidx_t ida_export netnode_altval(nodeidx_t num, nodeidx_t alt, int tag);
174idaman uchar ida_export netnode_charval(nodeidx_t num, nodeidx_t alt, int tag);
175idaman nodeidx_t ida_export netnode_altval_idx8(nodeidx_t num, uchar alt, int tag);
176idaman uchar ida_export netnode_charval_idx8(nodeidx_t num, uchar alt, int tag);
177idaman ssize_t ida_export netnode_supval(nodeidx_t num, nodeidx_t alt, void *buf, size_t bufsize, int tag);
178idaman ssize_t ida_export netnode_supstr(nodeidx_t num, nodeidx_t alt, char *buf, size_t bufsize, int tag);
179idaman ssize_t ida_export netnode_qsupstr(nodeidx_t num, qstring *buf, nodeidx_t alt, int tag);
180idaman bool ida_export netnode_supset(nodeidx_t num, nodeidx_t alt, const void *value, size_t length, int tag);
181idaman bool ida_export netnode_supdel(nodeidx_t num, nodeidx_t alt, int tag);
182idaman nodeidx_t ida_export netnode_lower_bound(nodeidx_t num, nodeidx_t cur, int tag);
183idaman nodeidx_t ida_export netnode_supfirst(nodeidx_t num, int tag);
184idaman nodeidx_t ida_export netnode_supnext(nodeidx_t num, nodeidx_t cur, int tag);
185idaman nodeidx_t ida_export netnode_suplast(nodeidx_t num, int tag);
186idaman nodeidx_t ida_export netnode_supprev(nodeidx_t num, nodeidx_t cur, int tag);
187idaman ssize_t ida_export netnode_supval_idx8(nodeidx_t num, uchar alt, void *buf, size_t bufsize, int tag);
188idaman ssize_t ida_export netnode_supstr_idx8(nodeidx_t num, uchar alt, char *buf, size_t bufsize, int tag);
189idaman ssize_t ida_export netnode_qsupstr_idx8(nodeidx_t num, qstring *buf, uchar alt, int tag);
190idaman bool ida_export netnode_supset_idx8(nodeidx_t num, uchar alt, const void *value, size_t length, int tag);
191idaman bool ida_export netnode_supdel_idx8(nodeidx_t num, uchar alt, int tag);
192idaman nodeidx_t ida_export netnode_lower_bound_idx8(nodeidx_t num, uchar alt, int tag);
193idaman nodeidx_t ida_export netnode_supfirst_idx8(nodeidx_t num, int tag);
194idaman nodeidx_t ida_export netnode_supnext_idx8(nodeidx_t num, uchar alt, int tag);
195idaman nodeidx_t ida_export netnode_suplast_idx8(nodeidx_t num, int tag);
196idaman nodeidx_t ida_export netnode_supprev_idx8(nodeidx_t num, uchar alt, int tag);
197idaman bool ida_export netnode_supdel_all(nodeidx_t num, int tag);
198idaman int ida_export netnode_supdel_range(nodeidx_t num, nodeidx_t idx1, nodeidx_t idx2, int tag);
199idaman int ida_export netnode_supdel_range_idx8(nodeidx_t num, nodeidx_t idx1, nodeidx_t idx2, int tag);
200idaman ssize_t ida_export netnode_hashval(nodeidx_t num, const char *idx, void *buf, size_t bufsize, int tag);
201idaman ssize_t ida_export netnode_hashstr(nodeidx_t num, const char *idx, char *buf, size_t bufsize, int tag);
202idaman ssize_t ida_export netnode_qhashstr(nodeidx_t num, qstring *buf, const char *idx, int tag);
203idaman nodeidx_t ida_export netnode_hashval_long(nodeidx_t num, const char *idx, int tag);
204idaman bool ida_export netnode_hashset(nodeidx_t num, const char *idx, const void *value, size_t length, int tag);
205idaman bool ida_export netnode_hashdel(nodeidx_t num, const char *idx, int tag);
206idaman ssize_t ida_export netnode_hashfirst(nodeidx_t num, char *buf, size_t bufsize, int tag);
207idaman ssize_t ida_export netnode_qhashfirst(nodeidx_t num, qstring *buf, int tag);
208idaman ssize_t ida_export netnode_hashnext(nodeidx_t num, const char *idx, char *buf, size_t bufsize, int tag);
209idaman ssize_t ida_export netnode_qhashnext(nodeidx_t num, qstring *buf, const char *idx, int tag);
210idaman ssize_t ida_export netnode_hashlast(nodeidx_t num, char *buf, size_t bufsize, int tag);
211idaman ssize_t ida_export netnode_qhashlast(nodeidx_t num, qstring *buf, int tag);
212idaman ssize_t ida_export netnode_hashprev(nodeidx_t num, const char *idx, char *buf, size_t bufsize, int tag);
213idaman ssize_t ida_export netnode_qhashprev(nodeidx_t num, qstring *buf, const char *idx, int tag);
214idaman size_t ida_export netnode_blobsize(nodeidx_t num, nodeidx_t start, int tag);
215idaman void *ida_export netnode_getblob(nodeidx_t num, void *buf, size_t *bufsize, nodeidx_t start, int tag);
216idaman ssize_t ida_export netnode_qgetblob(nodeidx_t num, bytevec_t *buf, size_t elsize, nodeidx_t start, int tag);
217idaman bool ida_export netnode_setblob(nodeidx_t num, const void *buf, size_t size, nodeidx_t start, int tag);
218idaman int ida_export netnode_delblob(nodeidx_t num, nodeidx_t start, int tag);
219idaman bool ida_export netnode_inited(void);
220idaman bool ida_export netnode_is_available(void);
221idaman size_t ida_export netnode_copy(nodeidx_t num, nodeidx_t count, nodeidx_t target, bool move);
222idaman size_t ida_export netnode_altshift(nodeidx_t num, nodeidx_t from, nodeidx_t to, nodeidx_t size, int tag);
223idaman size_t ida_export netnode_charshift(nodeidx_t num, nodeidx_t from, nodeidx_t to, nodeidx_t size, int tag);
224idaman size_t ida_export netnode_supshift(nodeidx_t num, nodeidx_t from, nodeidx_t to, nodeidx_t size, int tag);
225idaman size_t ida_export netnode_blobshift(nodeidx_t num, nodeidx_t from, nodeidx_t to, nodeidx_t size, int tag);
226idaman void ida_export netnode_altadjust(nodeidx_t num, nodeidx_t from, nodeidx_t to, nodeidx_t size, bool (idaapi *should_skip)(nodeidx_t ea));
228idaman bool ida_export netnode_exist(const netnode &n);
230
231//--------------------------------------------------------------------------
232// N E T N O D E
233//--------------------------------------------------------------------------
234
241{
243 friend class netlink;
245public:
246
247 //--------------------------------------------------------------------------
250
253 netnode(nodeidx_t num=BADNODE) { netnodenumber = num; }
254
256 operator nodeidx_t() const { return netnodenumber; }
257
265 netnode(const char *_name, size_t namlen=0, bool do_create=false)
266 {
267 netnode_check(this, _name, namlen, do_create);
268 }
269
271
275 friend bool exist(const netnode &n) { return netnode_exist(n); }
276
278 static bool exist(const char *_name) { return netnode(_name) != BADNODE; }
279
280 //--------------------------------------------------------------------------
284
293 bool create(const char *_name, size_t namlen=0)
294 {
295 return netnode_check(this, _name, namlen, true);
296 }
297
301 bool create(void) { return create(nullptr); }
302
304 void kill(void) { netnode_kill(this); }
305
307
308 //--------------------------------------------------------------------------
311
316 {
317 return netnode_get_name(*this, buf);
318 }
319
328 bool rename(const char *newname, size_t namlen=0)
329 {
330 return netnode_rename(*this, newname, namlen);
331 }
332
334
335 //--------------------------------------------------------------------------
338
343 ssize_t valobj(void *buf, size_t bufsize) const
344 {
345 return netnode_valobj(*this, buf, bufsize);
346 }
347
353 {
354 return netnode_qvalstr(*this, buf);
355 }
356
358 ssize_t valstr(char *buf, size_t bufsize) const
359 {
360 return netnode_valstr(*this, buf, bufsize);
361 }
362
368 bool set(const void *value, size_t length=0)
369 {
370 return netnode_set(*this, value, length);
371 }
372
376 bool delvalue(void)
377 {
378 return netnode_delvalue(*this);
379 }
380
382 bool set_long(nodeidx_t x) { return set(&x, sizeof(x)); }
383 bool value_exists(void) const { return valobj(nullptr, 0) >= 0; }
385 {
386 nodeidx_t v = 0;
387 if ( valobj(&v, sizeof(v)) > 0 )
388 return v;
389 return BADNODE;
390 }
391
393
394 //--------------------------------------------------------------------------
399
406 {
407 return netnode_altval(*this, alt, tag);
408 }
410 {
411 return netnode_altval(*this, ea, tag|NETMAP_IDX);
412 }
413
420 bool altset(nodeidx_t alt, nodeidx_t value, uchar tag=atag)
421 {
422 return netnode_supset(*this, alt, &value, sizeof(value), tag);
423 }
424 bool altset_ea(ea_t ea, nodeidx_t value, uchar tag=atag)
425 {
426 return netnode_supset(*this, ea, &value, sizeof(value), tag|NETMAP_IDX);
427 }
428
434 bool altdel(nodeidx_t alt, uchar tag=atag)
435 {
436 return netnode_supdel(*this, alt, tag);
437 }
438 bool altdel_ea(ea_t ea, uchar tag=atag)
439 {
440 return netnode_supdel(*this, ea, tag|NETMAP_IDX);
441 }
442
445 bool easet(ea_t ea, ea_t addr, uchar tag)
446 {
447 return netnode_supset(*this, ea, &addr, sizeof(addr), tag|NETMAP_IDX|NETMAP_VAL);
448 }
449 ea_t eaget(ea_t ea, uchar tag) const
450 {
451 return netnode_altval(*this, ea, tag|NETMAP_IDX|NETMAP_VAL);
452 }
453 bool eadel(ea_t ea, uchar tag)
454 {
455 return netnode_supdel(*this, ea, tag|NETMAP_IDX);
456 }
457
458 bool easet_idx(nodeidx_t idx, ea_t addr, uchar tag)
459 {
460 return netnode_supset(*this, idx, &addr, sizeof(addr), tag|NETMAP_VAL);
461 }
463 {
464 return netnode_altval(*this, idx, tag|NETMAP_VAL);
465 }
466
467 bool easet_idx8(uchar idx, ea_t addr, uchar tag)
468 {
469 return netnode_supset_idx8(*this, idx, &addr, sizeof(addr), tag|NETMAP_VAL);
470 }
471 ea_t eaget_idx8(uchar idx, uchar tag) const
472 {
473 return netnode_altval_idx8(*this, idx, tag|NETMAP_VAL);
474 }
475 bool eadel_idx8(uchar idx, uchar tag)
476 {
477 return netnode_supdel_idx8(*this, idx, tag);
478 }
479
485 {
486 return supfirst(tag);
487 }
488
495 {
496 return supnext(cur, tag);
497 }
498
504 {
505 return suplast(tag);
506 }
507
514 {
515 return supprev(cur, tag);
516 }
517
522 {
523 return netnode_altshift(*this, from, to, size, tag);
524 }
525
530 void altadjust(nodeidx_t from, nodeidx_t to, nodeidx_t size, bool (idaapi *should_skip)(nodeidx_t ea)=nullptr)
531 {
532 netnode_altadjust(*this, from, to, size, should_skip);
533 }
535 {
536 netnode_altadjust2(*this, from, to, size, av);
537 }
538
539
541
548 uchar charval(nodeidx_t alt, uchar tag) const { return netnode_charval(*this, alt, tag); }
549 bool charset(nodeidx_t alt, uchar val, uchar tag) { return supset(alt, &val, sizeof(val), tag); }
550 bool chardel(nodeidx_t alt, uchar tag) { return supdel(alt, tag); }
551 uchar charval_ea(ea_t ea, uchar tag) const { return netnode_charval(*this, ea, tag|NETMAP_IDX); }
552 bool charset_ea(ea_t ea, uchar val, uchar tag) { return netnode_supset(*this, ea, &val, sizeof(val), tag|NETMAP_IDX); }
553 bool chardel_ea(ea_t ea, uchar tag) { return netnode_supdel(*this, ea, tag|NETMAP_IDX); }
554 nodeidx_t charfirst(uchar tag) const { return supfirst(tag); }
555 nodeidx_t charnext(nodeidx_t cur, uchar tag) const { return supnext(cur, tag); }
556 nodeidx_t charlast(uchar tag) const { return suplast(tag); }
557 nodeidx_t charprev(nodeidx_t cur, uchar tag) const { return supprev(cur, tag); }
559 { return netnode_charshift(*this, from, to, size, tag); }
560
561
569 nodeidx_t altval_idx8(uchar alt, uchar tag) const { return netnode_altval_idx8(*this, alt, tag); }
570 bool altset_idx8(uchar alt, nodeidx_t val, uchar tag) { return supset_idx8(alt, &val, sizeof(val), tag); }
571 bool altdel_idx8(uchar alt, uchar tag) { return supdel_idx8(alt, tag); }
572 nodeidx_t altfirst_idx8(uchar tag) const { return supfirst_idx8(tag); }
573 nodeidx_t altnext_idx8(uchar cur, uchar tag) const { return supnext_idx8(cur, tag); }
574 nodeidx_t altlast_idx8(uchar tag) const { return suplast_idx8(tag); }
575 nodeidx_t altprev_idx8(uchar cur, uchar tag) const { return supprev_idx8(cur, tag); }
577
583 uchar charval_idx8(uchar alt, uchar tag) const { return netnode_charval_idx8(*this, alt, tag); }
584 bool charset_idx8(uchar alt, uchar val, uchar tag) { return supset_idx8(alt, &val, sizeof(val), tag); }
585 bool chardel_idx8(uchar alt, uchar tag) { return supdel_idx8(alt, tag); }
586 nodeidx_t charfirst_idx8(uchar tag) const { return supfirst_idx8(tag); }
587 nodeidx_t charnext_idx8(uchar cur, uchar tag) const { return supnext_idx8(cur, tag); }
588 nodeidx_t charlast_idx8(uchar tag) const { return suplast_idx8(tag); }
589 nodeidx_t charprev_idx8(uchar cur, uchar tag) const { return supprev_idx8(cur, tag); }
591
595
600 bool altdel(void)
601 {
602 return supdel_all(atag);
603 }
604
611 {
612 return supdel_all(tag);
613 }
614
616
617 //--------------------------------------------------------------------------
623
631 ssize_t supval(nodeidx_t alt, void *buf, size_t bufsize, uchar tag=stag) const
632 { return netnode_supval(*this, alt, buf, bufsize, tag); }
633 ssize_t supval_ea(ea_t ea, void *buf, size_t bufsize, uchar tag=stag) const
634 { return netnode_supval(*this, ea, buf, bufsize, tag|NETMAP_IDX); }
635
657 ssize_t supstr(qstring *buf, nodeidx_t alt, uchar tag=stag) const
658 { return netnode_qsupstr(*this, buf, alt, tag); }
659 ssize_t supstr_ea(qstring *buf, ea_t ea, uchar tag=stag) const
660 { return netnode_qsupstr(*this, buf, ea, tag|NETMAP_IDX); }
661
663 ssize_t supstr(nodeidx_t alt, char *buf, size_t bufsize, uchar tag=stag) const
664 { return netnode_supstr(*this, alt, buf, bufsize, tag); }
665 ssize_t supstr_ea(ea_t ea, char *buf, size_t bufsize, uchar tag=stag) const
666 { return netnode_supstr(*this, ea, buf, bufsize, tag|NETMAP_IDX); }
667
676 bool supset(nodeidx_t alt, const void *value, size_t length=0, uchar tag=stag)
677 { return netnode_supset(*this, alt, value, length, tag); }
678 bool supset_ea(ea_t ea, const void *value, size_t length=0, uchar tag=stag)
679 { return netnode_supset(*this, ea, value, length, tag|NETMAP_IDX); }
680
686 bool supdel(nodeidx_t alt, uchar tag=stag)
687 { return netnode_supdel(*this, alt, tag); }
688 bool supdel_ea(ea_t ea, uchar tag=stag)
689 { return netnode_supdel(*this, ea, tag|NETMAP_IDX); }
690
697 { return netnode_lower_bound(*this, cur, tag); }
699 { return netnode_lower_bound(*this, ea, tag|NETMAP_IDX); }
700
706 { return netnode_supfirst(*this, tag); }
707
714 { return netnode_supnext(*this, cur, tag); }
715
721 { return netnode_suplast(*this, tag); }
722
729 { return netnode_supprev(*this, cur, tag); }
730
731
736 { return netnode_supshift(*this, from, to, size, tag); }
737
739
745 ssize_t supval_idx8(uchar alt, void *buf, size_t bufsize, uchar tag) const { return netnode_supval_idx8(*this, alt, buf, bufsize, tag); }
746 ssize_t supstr_idx8(uchar alt, char *buf, size_t bufsize, uchar tag) const { return netnode_supstr_idx8(*this, alt, buf, bufsize, tag); }
747 ssize_t supstr_idx8(qstring *buf, uchar alt, uchar tag) const { return netnode_qsupstr_idx8(*this, buf, alt, tag); }
748 bool supset_idx8(uchar alt, const void *value, size_t length, uchar tag) { return netnode_supset_idx8(*this, alt, value, length, tag); }
749 bool supdel_idx8(uchar alt, uchar tag) { return netnode_supdel_idx8(*this, alt, tag); }
750 nodeidx_t lower_bound_idx8(uchar alt, uchar tag) const { return netnode_lower_bound_idx8(*this, alt, tag); }
751 nodeidx_t supfirst_idx8(uchar tag) const { return netnode_supfirst_idx8(*this, tag); }
752 nodeidx_t supnext_idx8(uchar alt, uchar tag) const { return netnode_supnext_idx8(*this, alt, tag); }
753 nodeidx_t suplast_idx8(uchar tag) const { return netnode_suplast_idx8(*this, tag); }
754 nodeidx_t supprev_idx8(uchar alt, uchar tag) const { return netnode_supprev_idx8(*this, alt, tag); }
756
759
764 bool supdel(void)
765 {
766 return supdel_all(stag);
767 }
768
774 {
775 return netnode_supdel_all(*this, tag);
776 }
777
786 {
787 return netnode_supdel_range(*this, idx1, idx2, tag);
788 }
789
790 int supdel_range_idx8(uchar idx1, uchar idx2, uchar tag)
791 {
792 return netnode_supdel_range_idx8(*this, idx1, idx2, tag);
793 }
794
796
797 //--------------------------------------------------------------------------
803
811 ssize_t hashval(const char *idx, void *buf, size_t bufsize, uchar tag=htag) const
812 { return netnode_hashval(*this, idx, buf, bufsize, tag); }
813
815 ssize_t hashstr(qstring *buf, const char *idx, uchar tag=htag) const
816 { return netnode_qhashstr(*this, buf, idx, tag); }
817
819 ssize_t hashstr(const char *idx, char *buf, size_t bufsize, uchar tag=htag) const
820 { return netnode_hashstr(*this, idx, buf, bufsize, tag); }
821
827 nodeidx_t hashval_long(const char *idx, uchar tag=htag) const
828 { return netnode_hashval_long(*this, idx, tag); }
829
838 bool hashset(const char *idx, const void *value, size_t length=0, uchar tag=htag)
839 { return netnode_hashset(*this, idx, value, length, tag); }
840
847 bool hashset(const char *idx, nodeidx_t value, uchar tag=htag)
848 { return hashset(idx, &value, sizeof(value), tag); }
849
855 bool hashdel(const char *idx, uchar tag=htag)
856 { return netnode_hashdel(*this, idx, tag); }
857
865 { return netnode_qhashfirst(*this, buf, tag); }
866
868 ssize_t hashfirst(char *buf, size_t bufsize, uchar tag=htag) const
869 { return netnode_hashfirst(*this, buf, bufsize, tag); }
870
878 ssize_t hashnext(qstring *buf, const char *idx, uchar tag=htag) const
879 { return netnode_qhashnext(*this, buf, idx, tag); }
880
882 ssize_t hashnext(const char *idx, char *buf, size_t bufsize, uchar tag=htag) const
883 { return netnode_hashnext(*this, idx, buf, bufsize, tag); }
884
892 { return netnode_qhashlast(*this, buf, tag); }
893
895 ssize_t hashlast(char *buf, size_t bufsize, uchar tag=htag) const
896 { return netnode_hashlast(*this, buf, bufsize, tag); }
897
905 ssize_t hashprev(qstring *buf, const char *idx, uchar tag=htag) const
906 { return netnode_qhashprev(*this, buf, idx, tag); }
907
909 ssize_t hashprev(const char *idx, char *buf, size_t bufsize, uchar tag=htag) const
910 { return netnode_hashprev(*this, idx, buf, bufsize, tag); }
911
917 {
918 return supdel_all(tag);
919 }
920
922
923 //--------------------------------------------------------------------------
928
933 size_t blobsize(nodeidx_t _start, uchar tag)
934 {
935 return netnode_blobsize(*this, _start, tag);
936 }
937 size_t blobsize_ea(ea_t ea, uchar tag)
938 {
939 return netnode_blobsize(*this, ea, tag|NETMAP_IDX);
940 }
941
952 void *getblob(
953 void *buf,
954 size_t *bufsize,
955 nodeidx_t _start,
956 uchar tag)
957 {
958 return netnode_getblob(*this, buf, bufsize, _start, tag);
959 }
961 void *buf,
962 size_t *bufsize,
963 ea_t ea,
964 uchar tag)
965 {
966 return netnode_getblob(*this, buf, bufsize, ea, tag|NETMAP_IDX);
967 }
968
974 template <class T>
976 qvector<T> *blob,
977 nodeidx_t _start,
978 uchar tag)
979 {
980 return netnode_qgetblob(*this, (bytevec_t *)blob, sizeof(T), _start, tag);
981 }
982 template <class T>
984 qvector<T> *blob,
985 ea_t ea,
986 uchar tag)
987 {
988 return netnode_qgetblob(*this, (bytevec_t *)blob, sizeof(T), nodeidx_t(ea), tag|NETMAP_IDX);
989 }
990
999 qstring *buf,
1000 nodeidx_t _start,
1001 uchar tag)
1002 {
1003 return netnode_qgetblob(*this, (bytevec_t *)buf, 1, _start, tag|NETMAP_STR);
1004 }
1005
1013 const void *buf,
1014 size_t size,
1015 nodeidx_t _start,
1016 uchar tag)
1017 {
1018 return netnode_setblob(*this, buf, size, _start, tag);
1019 }
1021 const void *buf,
1022 size_t size,
1023 ea_t ea,
1024 uchar tag)
1025 {
1026 return netnode_setblob(*this, buf, size, ea, tag|NETMAP_IDX);
1027 }
1028
1033 int delblob(nodeidx_t _start, uchar tag)
1034 {
1035 return netnode_delblob(*this, _start, tag);
1036 }
1037 int delblob_ea(ea_t ea, uchar tag)
1038 {
1039 return netnode_delblob(*this, ea, tag|NETMAP_IDX);
1040 }
1041
1046 {
1047 return netnode_blobshift(*this, from, to, size, tag);
1048 }
1049
1051
1052 //--------------------------------------------------------------------------
1055
1060 bool start(void)
1061 {
1062 return netnode_start(this);
1063 }
1064
1069 bool end(void)
1070 {
1071 return netnode_end(this);
1072 }
1073
1078 bool next(void)
1079 {
1080 return netnode_next(this);
1081 }
1082
1087 bool prev(void)
1088 {
1089 return netnode_prev(this);
1090 }
1091
1093
1094 //--------------------------------------------------------------------------
1100 size_t copyto(netnode destnode, nodeidx_t count=1) { return netnode_copy(netnodenumber, count, destnode.netnodenumber, false); }
1101 size_t moveto(netnode destnode, nodeidx_t count=1) { return netnode_copy(netnodenumber, count, destnode.netnodenumber, true); }
1103
1104 //--------------------------------------------------------------------------
1107 bool operator==(netnode &n) const { return netnodenumber == n.netnodenumber; }
1108 bool operator!=(netnode &n) const { return netnodenumber != n.netnodenumber; }
1109 bool operator==(nodeidx_t x) const { return netnodenumber == x; }
1110 bool operator!=(nodeidx_t x) const { return netnodenumber != x; }
1112
1113
1114 static bool inited(void) { return netnode_inited(); }
1115 static bool is_available(void) { return netnode_is_available(); }
1116
1117private:
1118 // The netnode number.
1119 // Usually this is the linear address that the netnode keeps information about.
1120 nodeidx_t netnodenumber;
1121};
1122#ifdef __EA64__
1123CASSERT(sizeof(netnode) == 8);
1124#else
1125CASSERT(sizeof(netnode) == 4);
1126#endif
1127
1128
1129#endif // _NETNODE_HPP
Vector of bytes (use for dynamic memory)
Definition pro.h:3773
Definition of the IDA database node.
Definition netnode.hpp:241
bool supdel_ea(ea_t ea, uchar tag=stag)
Definition netnode.hpp:688
friend bool exist(const netnode &n)
Does the specified netnode exist?
Definition netnode.hpp:275
bool hashdel_all(uchar tag=htag)
Delete all elements of hash.
Definition netnode.hpp:916
ssize_t hashfirst(char *buf, size_t bufsize, uchar tag=htag) const
Definition netnode.hpp:868
bool altset_idx8(uchar alt, nodeidx_t val, uchar tag)
Definition netnode.hpp:570
nodeidx_t altnext_idx8(uchar cur, uchar tag) const
Definition netnode.hpp:573
nodeidx_t altprev(nodeidx_t cur, uchar tag=atag) const
Get previous existing element of altval array.
Definition netnode.hpp:513
nodeidx_t altnext(nodeidx_t cur, uchar tag=atag) const
Get next existing element of altval array.
Definition netnode.hpp:494
bool start(void)
Get first netnode in the graph.
Definition netnode.hpp:1060
bool eadel(ea_t ea, uchar tag)
Definition netnode.hpp:453
bool supdel(nodeidx_t alt, uchar tag=stag)
Delete supval element.
Definition netnode.hpp:686
bool charset_ea(ea_t ea, uchar val, uchar tag)
Definition netnode.hpp:552
int delblob_ea(ea_t ea, uchar tag)
Definition netnode.hpp:1037
bool set(const void *value, size_t length=0)
Set value of netnode.
Definition netnode.hpp:368
netnode(const char *_name, size_t namlen=0, bool do_create=false)
Construct an instance of netnode class to access the specified netnode.
Definition netnode.hpp:265
bool chardel_idx8(uchar alt, uchar tag)
Definition netnode.hpp:585
bool hashdel(const char *idx, uchar tag=htag)
Delete hash element.
Definition netnode.hpp:855
bool hashset(const char *idx, nodeidx_t value, uchar tag=htag)
Set value of hash element to long value.
Definition netnode.hpp:847
bool setblob(const void *buf, size_t size, nodeidx_t _start, uchar tag)
Store a blob in a netnode.
Definition netnode.hpp:1012
void * getblob_ea(void *buf, size_t *bufsize, ea_t ea, uchar tag)
Definition netnode.hpp:960
nodeidx_t lower_bound_ea(ea_t ea, uchar tag=stag) const
Definition netnode.hpp:698
nodeidx_t altprev_idx8(uchar cur, uchar tag) const
Definition netnode.hpp:575
nodeidx_t altfirst(uchar tag=atag) const
Get first existing element of altval array.
Definition netnode.hpp:484
ssize_t hashstr(const char *idx, char *buf, size_t bufsize, uchar tag=htag) const
Definition netnode.hpp:819
nodeidx_t altval(nodeidx_t alt, uchar tag=atag) const
Get altval element of the specified array.
Definition netnode.hpp:405
bool hashset(const char *idx, const void *value, size_t length=0, uchar tag=htag)
Set value of hash element.
Definition netnode.hpp:838
ssize_t hashprev(const char *idx, char *buf, size_t bufsize, uchar tag=htag) const
Definition netnode.hpp:909
ea_t eaget_idx8(uchar idx, uchar tag) const
Definition netnode.hpp:471
nodeidx_t lower_bound(nodeidx_t cur, uchar tag=stag) const
Get lower bound of existing elements of supval array.
Definition netnode.hpp:696
size_t moveto(netnode destnode, nodeidx_t count=1)
Definition netnode.hpp:1101
ssize_t supval(nodeidx_t alt, void *buf, size_t bufsize, uchar tag=stag) const
Get value of the specified supval array element.
Definition netnode.hpp:631
bool rename(const char *newname, size_t namlen=0)
Rename a netnode.
Definition netnode.hpp:328
nodeidx_t charnext(nodeidx_t cur, uchar tag) const
Definition netnode.hpp:555
nodeidx_t charnext_idx8(uchar cur, uchar tag) const
Definition netnode.hpp:587
ssize_t hashlast(qstring *buf, uchar tag=htag) const
Get last existing element of hash.
Definition netnode.hpp:891
nodeidx_t suplast(uchar tag=stag) const
Get last existing element of supval array.
Definition netnode.hpp:720
size_t blobshift(nodeidx_t from, nodeidx_t to, nodeidx_t size, uchar tag)
Shift the blob array elements.
Definition netnode.hpp:1045
ssize_t supval_ea(ea_t ea, void *buf, size_t bufsize, uchar tag=stag) const
Definition netnode.hpp:633
ssize_t supstr(qstring *buf, nodeidx_t alt, uchar tag=stag) const
Get string value of the specified supval array element.
Definition netnode.hpp:657
uchar charval(nodeidx_t alt, uchar tag) const
Definition netnode.hpp:548
bool eadel_idx8(uchar idx, uchar tag)
Definition netnode.hpp:475
nodeidx_t charprev_idx8(uchar cur, uchar tag) const
Definition netnode.hpp:589
uchar charval_ea(ea_t ea, uchar tag) const
Definition netnode.hpp:551
nodeidx_t charlast_idx8(uchar tag) const
Definition netnode.hpp:588
size_t copyto(netnode destnode, nodeidx_t count=1)
Definition netnode.hpp:1100
nodeidx_t altval_idx8(uchar alt, uchar tag) const
Definition netnode.hpp:569
nodeidx_t supfirst_idx8(uchar tag) const
Definition netnode.hpp:751
bool altdel_idx8(uchar alt, uchar tag)
Definition netnode.hpp:571
bool prev(void)
Get prev netnode in the graph.
Definition netnode.hpp:1087
nodeidx_t long_value(void) const
Definition netnode.hpp:384
ssize_t hashlast(char *buf, size_t bufsize, uchar tag=htag) const
Definition netnode.hpp:895
ssize_t supval_idx8(uchar alt, void *buf, size_t bufsize, uchar tag) const
Definition netnode.hpp:745
bool supset_ea(ea_t ea, const void *value, size_t length=0, uchar tag=stag)
Definition netnode.hpp:678
ssize_t getblob_ea(qvector< T > *blob, ea_t ea, uchar tag)
Definition netnode.hpp:983
bool set_long(nodeidx_t x)
Value of netnode as a long number:
Definition netnode.hpp:382
nodeidx_t altlast(uchar tag=atag) const
Get last element of altval array.
Definition netnode.hpp:503
int delblob(nodeidx_t _start, uchar tag)
Delete a blob.
Definition netnode.hpp:1033
bool charset_idx8(uchar alt, uchar val, uchar tag)
Definition netnode.hpp:584
bool altset(nodeidx_t alt, nodeidx_t value, uchar tag=atag)
Set value of altval array.
Definition netnode.hpp:420
size_t charshift(nodeidx_t from, nodeidx_t to, nodeidx_t size, uchar tag)
Definition netnode.hpp:558
nodeidx_t altval_ea(ea_t ea, uchar tag=atag) const
Definition netnode.hpp:409
size_t blobsize_ea(ea_t ea, uchar tag)
Definition netnode.hpp:937
bool operator==(netnode &n) const
Definition netnode.hpp:1107
nodeidx_t lower_bound_idx8(uchar alt, uchar tag) const
Definition netnode.hpp:750
bool easet_idx8(uchar idx, ea_t addr, uchar tag)
Definition netnode.hpp:467
ssize_t hashfirst(qstring *buf, uchar tag=htag) const
Get first existing element of hash.
Definition netnode.hpp:864
ssize_t supstr_ea(ea_t ea, char *buf, size_t bufsize, uchar tag=stag) const
Definition netnode.hpp:665
ea_t eaget_idx(nodeidx_t idx, uchar tag)
Definition netnode.hpp:462
bool create(void)
Create unnamed netnode.
Definition netnode.hpp:301
ssize_t supstr_ea(qstring *buf, ea_t ea, uchar tag=stag) const
Definition netnode.hpp:659
nodeidx_t charfirst_idx8(uchar tag) const
Definition netnode.hpp:586
void altadjust2(nodeidx_t from, nodeidx_t to, nodeidx_t size, altadjust_visitor_t &av)
Definition netnode.hpp:534
nodeidx_t supnext_idx8(uchar alt, uchar tag) const
Definition netnode.hpp:752
nodeidx_t supprev(nodeidx_t cur, uchar tag=stag) const
Get previous existing element of supval array.
Definition netnode.hpp:728
ssize_t hashval(const char *idx, void *buf, size_t bufsize, uchar tag=htag) const
Get value of the specified hash element.
Definition netnode.hpp:811
nodeidx_t altlast_idx8(uchar tag) const
Definition netnode.hpp:574
ssize_t valstr(qstring *buf) const
Get string value of netnode.
Definition netnode.hpp:352
ssize_t hashprev(qstring *buf, const char *idx, uchar tag=htag) const
Get previous existing element of supval array.
Definition netnode.hpp:905
uchar charval_idx8(uchar alt, uchar tag) const
Definition netnode.hpp:583
bool next(void)
Get next netnode in the graph.
Definition netnode.hpp:1078
netnode(nodeidx_t num=BADNODE)
Constructor to create a netnode to access information about the specified linear address (possibly mi...
Definition netnode.hpp:253
ssize_t supstr_idx8(qstring *buf, uchar alt, uchar tag) const
Definition netnode.hpp:747
bool operator==(nodeidx_t x) const
Definition netnode.hpp:1109
bool altdel_all(uchar tag=atag)
Delete all elements of the specified altval array.
Definition netnode.hpp:610
bool chardel(nodeidx_t alt, uchar tag)
Definition netnode.hpp:550
ssize_t supstr(nodeidx_t alt, char *buf, size_t bufsize, uchar tag=stag) const
Definition netnode.hpp:663
bool supdel_all(uchar tag)
Delete all elements of the specified supval array.
Definition netnode.hpp:773
void altadjust(nodeidx_t from, nodeidx_t to, nodeidx_t size, bool(idaapi *should_skip)(nodeidx_t ea)=nullptr)
Adjust values of altval arrays elements.
Definition netnode.hpp:530
nodeidx_t suplast_idx8(uchar tag) const
Definition netnode.hpp:753
static bool exist(const char *_name)
Does the netnode with the specified name exist?
Definition netnode.hpp:278
ssize_t get_name(qstring *buf) const
Get the netnode name.
Definition netnode.hpp:315
bool operator!=(netnode &n) const
Definition netnode.hpp:1108
int supdel_range(nodeidx_t idx1, nodeidx_t idx2, uchar tag)
Delete range of elements in the specified supval array.
Definition netnode.hpp:785
nodeidx_t hashval_long(const char *idx, uchar tag=htag) const
Get value of the specified hash element.
Definition netnode.hpp:827
size_t supshift(nodeidx_t from, nodeidx_t to, nodeidx_t size, uchar tag=stag)
Shift the supval array elements.
Definition netnode.hpp:735
bool supdel_idx8(uchar alt, uchar tag)
Definition netnode.hpp:749
nodeidx_t altfirst_idx8(uchar tag) const
Definition netnode.hpp:572
bool delvalue(void)
Delete value of netnode.
Definition netnode.hpp:376
bool altdel(void)
Delete all elements of altval array.
Definition netnode.hpp:600
bool supset_idx8(uchar alt, const void *value, size_t length, uchar tag)
Definition netnode.hpp:748
static bool inited(void)
Definition netnode.hpp:1114
bool operator!=(nodeidx_t x) const
Definition netnode.hpp:1110
bool altdel_ea(ea_t ea, uchar tag=atag)
Definition netnode.hpp:438
bool create(const char *_name, size_t namlen=0)
Create a named netnode.
Definition netnode.hpp:293
int supdel_range_idx8(uchar idx1, uchar idx2, uchar tag)
Same as above, but accepts 8-bit indexes.
Definition netnode.hpp:790
bool easet(ea_t ea, ea_t addr, uchar tag)
Store/retrieve/delete an address value in the netnode that corresponds to an address.
Definition netnode.hpp:445
ssize_t supstr_idx8(uchar alt, char *buf, size_t bufsize, uchar tag) const
Definition netnode.hpp:746
ssize_t getblob(qstring *buf, nodeidx_t _start, uchar tag)
Get blob from a netnode into a qstring* and make sure the string is null-terminated.
Definition netnode.hpp:998
ssize_t valobj(void *buf, size_t bufsize) const
Get value of netnode.
Definition netnode.hpp:343
size_t blobsize(nodeidx_t _start, uchar tag)
Get size of blob.
Definition netnode.hpp:933
ssize_t hashnext(qstring *buf, const char *idx, uchar tag=htag) const
Get next existing element of hash.
Definition netnode.hpp:878
bool chardel_ea(ea_t ea, uchar tag)
Definition netnode.hpp:553
ea_t eaget(ea_t ea, uchar tag) const
Definition netnode.hpp:449
nodeidx_t supprev_idx8(uchar alt, uchar tag) const
Definition netnode.hpp:754
bool supdel(void)
Delete all elements of supval array.
Definition netnode.hpp:764
bool supset(nodeidx_t alt, const void *value, size_t length=0, uchar tag=stag)
Set value of supval array element.
Definition netnode.hpp:676
nodeidx_t charlast(uchar tag) const
Definition netnode.hpp:556
void kill(void)
Delete a netnode with all information attached to it.
Definition netnode.hpp:304
ssize_t getblob(qvector< T > *blob, nodeidx_t _start, uchar tag)
Get blob from a netnode.
Definition netnode.hpp:975
ssize_t hashnext(const char *idx, char *buf, size_t bufsize, uchar tag=htag) const
Definition netnode.hpp:882
nodeidx_t charfirst(uchar tag) const
Definition netnode.hpp:554
bool charset(nodeidx_t alt, uchar val, uchar tag)
Definition netnode.hpp:549
void * getblob(void *buf, size_t *bufsize, nodeidx_t _start, uchar tag)
Get blob from a netnode.
Definition netnode.hpp:952
ssize_t hashstr(qstring *buf, const char *idx, uchar tag=htag) const
Similar to supstr(), but accepts a hash index.
Definition netnode.hpp:815
bool altdel(nodeidx_t alt, uchar tag=atag)
Delete element of altval array.
Definition netnode.hpp:434
bool end(void)
Get last netnode in the graph.
Definition netnode.hpp:1069
size_t altshift(nodeidx_t from, nodeidx_t to, nodeidx_t size, uchar tag=atag)
Shift the altval array elements.
Definition netnode.hpp:521
nodeidx_t supnext(nodeidx_t cur, uchar tag=stag) const
Get next existing element of supval array.
Definition netnode.hpp:713
bool value_exists(void) const
Definition netnode.hpp:383
bool altset_ea(ea_t ea, nodeidx_t value, uchar tag=atag)
Definition netnode.hpp:424
bool easet_idx(nodeidx_t idx, ea_t addr, uchar tag)
Definition netnode.hpp:458
static bool is_available(void)
Definition netnode.hpp:1115
ssize_t valstr(char *buf, size_t bufsize) const
Definition netnode.hpp:358
nodeidx_t supfirst(uchar tag=stag) const
Get first existing element of supval array.
Definition netnode.hpp:705
nodeidx_t charprev(nodeidx_t cur, uchar tag) const
Definition netnode.hpp:557
bool setblob_ea(const void *buf, size_t size, ea_t ea, uchar tag)
Definition netnode.hpp:1020
Reimplementation of vector class from STL.
Definition pro.h:2250
const uchar htag
Array of hashvals.
Definition netnode.hpp:128
const uchar atag
Array of altvals.
Definition netnode.hpp:126
const uchar ltag
Links between netnodes.
Definition netnode.hpp:131
const uchar vtag
Value of netnode.
Definition netnode.hpp:129
const uchar ntag
Name of netnode.
Definition netnode.hpp:130
const uchar stag
Array of supvals.
Definition netnode.hpp:127
idaman size_t n
Definition pro.h:997
idaman int64 size_t count
Definition kernwin.hpp:1366
asize_t size
Definition kernwin.hpp:6339
unsigned __int64 uint64
Definition llong.hpp:13
idaman nodeidx_t ida_export netnode_suplast_idx8(nodeidx_t num, int tag)
const int NETMAP_VAL
Definition netnode.hpp:138
idaman nodeidx_t ida_export netnode_supfirst(nodeidx_t num, int tag)
idaman nodeidx_t ida_export netnode_lower_bound(nodeidx_t num, nodeidx_t cur, int tag)
idaman ssize_t ida_export netnode_qhashnext(nodeidx_t num, qstring *buf, const char *idx, int tag)
idaman bool ida_export netnode_start(netnode *)
idaman ssize_t ida_export netnode_supstr(nodeidx_t num, nodeidx_t alt, char *buf, size_t bufsize, int tag)
idaman nodeidx_t ida_export netnode_altval_idx8(nodeidx_t num, uchar alt, int tag)
idaman ssize_t ida_export netnode_qhashprev(nodeidx_t num, qstring *buf, const char *idx, int tag)
idaman void ida_export netnode_altadjust2(nodeidx_t num, nodeidx_t from, nodeidx_t to, nodeidx_t size, altadjust_visitor_t &av)
idaman nodeidx_t ida_export netnode_supfirst_idx8(nodeidx_t num, int tag)
idaman ssize_t ida_export netnode_hashval(nodeidx_t num, const char *idx, void *buf, size_t bufsize, int tag)
idaman int ida_export netnode_delblob(nodeidx_t num, nodeidx_t start, int tag)
idaman nodeidx_t ida_export netnode_hashval_long(nodeidx_t num, const char *idx, int tag)
idaman bool ida_export netnode_set(nodeidx_t num, const void *value, size_t length)
idaman nodeidx_t ida_export netnode_supprev_idx8(nodeidx_t num, uchar alt, int tag)
idaman ssize_t ida_export netnode_qhashlast(nodeidx_t num, qstring *buf, int tag)
idaman ssize_t ida_export netnode_hashnext(nodeidx_t num, const char *idx, char *buf, size_t bufsize, int tag)
idaman size_t ida_export netnode_copy(nodeidx_t num, nodeidx_t count, nodeidx_t target, bool move)
idaman bool ida_export netnode_rename(nodeidx_t num, const char *newname, size_t namlen)
idaman ssize_t ida_export netnode_get_name(nodeidx_t num, qstring *out)
idaman ssize_t ida_export netnode_qhashstr(nodeidx_t num, qstring *buf, const char *idx, int tag)
idaman size_t ida_export netnode_blobsize(nodeidx_t num, nodeidx_t start, int tag)
const int NETMAP_X8
Definition netnode.hpp:143
idaman bool ida_export netnode_supdel_idx8(nodeidx_t num, uchar alt, int tag)
idaman void *ida_export netnode_getblob(nodeidx_t num, void *buf, size_t *bufsize, nodeidx_t start, int tag)
idaman nodeidx_t ida_export netnode_supprev(nodeidx_t num, nodeidx_t cur, int tag)
idaman ssize_t ida_export netnode_qsupstr(nodeidx_t num, qstring *buf, nodeidx_t alt, int tag)
idaman nodeidx_t ida_export netnode_altval(nodeidx_t num, nodeidx_t alt, int tag)
const int NETMAP_VAL_NDX
Definition netnode.hpp:147
idaman nodeidx_t ida_export netnode_supnext_idx8(nodeidx_t num, uchar alt, int tag)
idaman ssize_t ida_export netnode_supstr_idx8(nodeidx_t num, uchar alt, char *buf, size_t bufsize, int tag)
idaman uchar ida_export netnode_charval_idx8(nodeidx_t num, uchar alt, int tag)
idaman ssize_t ida_export netnode_supval(nodeidx_t num, nodeidx_t alt, void *buf, size_t bufsize, int tag)
idaman bool ida_export netnode_check(netnode *, const char *name, size_t namlen, bool create)
const int MAXNAMESIZE
Maximum length of a netnode name. WILL BE REMOVED IN THE FUTURE.
Definition netnode.hpp:102
idaman int ida_export netnode_supdel_range_idx8(nodeidx_t num, nodeidx_t idx1, nodeidx_t idx2, int tag)
idaman uchar ida_export netnode_charval(nodeidx_t num, nodeidx_t alt, int tag)
const int MAX_NODENAME_SIZE
Maximum length of a name. We permit names up to 32KB-1 bytes.
Definition netnode.hpp:105
idaman ssize_t ida_export netnode_supval_idx8(nodeidx_t num, uchar alt, void *buf, size_t bufsize, int tag)
idaman bool ida_export netnode_is_available(void)
idaman bool ida_export netnode_end(netnode *)
idaman ssize_t ida_export netnode_qhashfirst(nodeidx_t num, qstring *buf, int tag)
uint64 nodeidx64_t
Definition netnode.hpp:111
const int NETMAP_V8
Definition netnode.hpp:145
idaman bool ida_export netnode_delvalue(nodeidx_t num)
idaman ssize_t ida_export netnode_qvalstr(nodeidx_t num, qstring *buf)
idaman bool ida_export netnode_next(netnode *)
idaman bool ida_export netnode_inited(void)
idaman nodeidx_t ida_export netnode_suplast(nodeidx_t num, int tag)
uint32 nodeidx32_t
Definition netnode.hpp:112
idaman ssize_t ida_export netnode_valobj(nodeidx_t num, void *buf, size_t bufsize)
idaman size_t ida_export netnode_charshift(nodeidx_t num, nodeidx_t from, nodeidx_t to, nodeidx_t size, int tag)
idaman ssize_t ida_export netnode_valstr(nodeidx_t num, char *buf, size_t bufsize)
idaman void ida_export netnode_kill(netnode *)
idaman bool ida_export netnode_supset_idx8(nodeidx_t num, uchar alt, const void *value, size_t length, int tag)
idaman ssize_t ida_export netnode_hashfirst(nodeidx_t num, char *buf, size_t bufsize, int tag)
idaman bool ida_export netnode_supdel_all(nodeidx_t num, int tag)
nodeidx64_t nodeidx_t
Definition netnode.hpp:114
idaman ssize_t ida_export netnode_hashlast(nodeidx_t num, char *buf, size_t bufsize, int tag)
idaman int ida_export netnode_supdel_range(nodeidx_t num, nodeidx_t idx1, nodeidx_t idx2, int tag)
idaman void ida_export netnode_altadjust(nodeidx_t num, nodeidx_t from, nodeidx_t to, nodeidx_t size, bool(idaapi *should_skip)(nodeidx_t ea))
idaman size_t ida_export netnode_altshift(nodeidx_t num, nodeidx_t from, nodeidx_t to, nodeidx_t size, int tag)
idaman bool ida_export netnode_supdel(nodeidx_t num, nodeidx_t alt, int tag)
const int NETMAP_IDX
Definition netnode.hpp:135
idaman nodeidx_t ida_export netnode_lower_bound_idx8(nodeidx_t num, uchar alt, int tag)
idaman size_t ida_export netnode_supshift(nodeidx_t num, nodeidx_t from, nodeidx_t to, nodeidx_t size, int tag)
const int NETMAP_STR
Definition netnode.hpp:141
idaman ssize_t ida_export netnode_qsupstr_idx8(nodeidx_t num, qstring *buf, uchar alt, int tag)
idaman bool ida_export netnode_prev(netnode *)
idaman bool ida_export netnode_supset(nodeidx_t num, nodeidx_t alt, const void *value, size_t length, int tag)
idaman size_t ida_export netnode_blobshift(nodeidx_t num, nodeidx_t from, nodeidx_t to, nodeidx_t size, int tag)
idaman nodeidx_t ida_export netnode_supnext(nodeidx_t num, nodeidx_t cur, int tag)
const int MAXSPECSIZE
Maximum length of strings or objects stored in a supval array element.
Definition netnode.hpp:108
idaman ssize_t ida_export netnode_hashstr(nodeidx_t num, const char *idx, char *buf, size_t bufsize, int tag)
idaman bool ida_export netnode_setblob(nodeidx_t num, const void *buf, size_t size, nodeidx_t start, int tag)
idaman bool ida_export netnode_hashdel(nodeidx_t num, const char *idx, int tag)
CASSERT(sizeof(netnode)==8)
idaman ssize_t ida_export netnode_hashprev(nodeidx_t num, const char *idx, char *buf, size_t bufsize, int tag)
idaman bool ida_export netnode_exist(const netnode &n)
idaman bool ida_export netnode_hashset(nodeidx_t num, const char *idx, const void *value, size_t length, int tag)
idaman ssize_t ida_export netnode_qgetblob(nodeidx_t num, bytevec_t *buf, size_t elsize, nodeidx_t start, int tag)
unsigned int uint32
unsigned 32 bit value
Definition pro.h:348
uint64 ea_t
Definition pro.h:421
unsigned char uchar
unsigned 8 bit value
Definition pro.h:337
idaman size_t bufsize
Definition pro.h:600
ptrdiff_t ssize_t
Signed size_t - used to check for size overflows when the counter becomes negative.
Definition pro.h:381
_qstring< char > qstring
regular string
Definition pro.h:3694
Contains the definition of range_t.
visitor to be used by altadjust2 to skip the adjustment of some altvals
Definition netnode.hpp:151
virtual bool should_skip(nodeidx_t ea)=0