int main(int argc, char *argv[]) { void (*mangler)(struct rfc822_msg *msg); plan_tests(3 * 1); foreach_ptr(mangler, mangle_list) { const char *buf; size_t len; struct rfc822_msg *msg, *check; buf = assemble_msg(&test_msg_1, &len, 0); msg = rfc822_start(NULL, buf, len); fprintf(stderr, "msg = %p\n", msg); ok1(msg != NULL); (void) rfc822_next_header(msg, NULL); check = rfc822_check(msg, NULL); fprintf(stderr, "check = %p (1)\n", check); ok1(check == msg); mangler(msg); check = rfc822_check(msg, NULL); fprintf(stderr, "check = %p (2)\n", check); ok1(check == NULL); } exit(exit_status()); }
/*16 round feistel network with 64 bit block length and 56 bit keylength*/ int des(int key, int message){ //split message into left and right halves //for-loop calling sboxes and keyschedule int left = //LEFT OF THE MESSAGE; int right = //RIGHT OF THE MESSAGE; int round; for(round = 0; round < 16; round++){ int oldleft = left; left = right; right = XOR(oldleft, mangler(keyschedule(key,round),right)); //fix this } return left CONCAT right; //fix this; perform concatenation }
void ContiguousSpace::mangle_unused_area_complete() { mangler()->mangle_unused_area_complete(); }
// Mangled only the unused space that has not previously // been mangled and that has not been allocated since being // mangled. void ContiguousSpace::mangle_unused_area() { mangler()->mangle_unused_area(); }
void ContiguousSpace::check_mangled_unused_area_complete() { mangler()->check_mangled_unused_area_complete(); }
void ContiguousSpace::check_mangled_unused_area(HeapWord* limit) { mangler()->check_mangled_unused_area(limit); }
void ContiguousSpace::set_top_for_allocations() { mangler()->set_top_for_allocations(top()); }
void ContiguousSpace::set_top_for_allocations(HeapWord* v) { mangler()->set_top_for_allocations(v); }