Edit: Many people think that hash functions are one-way, so that it is only possible to start from some Initialization Vector, get some data, and reach some Exit Hash as an output. People often don't expect that hash functions could be executed backwards, and that property can sometimes be useful. It is inevitable, because as long as you have a bijective operation, you can always reverse it. The only "irreversibility" is that we cannot generate data, from Initialization Vector and Exit Hash alone, that's the "one-way" we care about, and that's the only part that makes it truly "one-way".
Here is some example, so people can see in practice, how it is possible to execute hash function backwards (again, my example is based on SHA-1, but you can use the same trick on SHA-256, and some other hash functions). First, we start from IV of all zeroes, and use a message of all zeroes. Everything is zero on our input, let's see how it looks like:
1 5a827999 00000000 00000000 00000000 00000000
2 aad1acc4 5a827999 00000000 00000000 00000000
3 b4b8122e aad1acc4 56a09e66 00000000 00000000
4 f4054bb3 b4b8122e 2ab46b31 56a09e66 00000000
5 3ddc7e77 f4054bb3 ad2e048b 2ab46b31 56a09e66
6 1b670769 3ddc7e77 fd0152ec ad2e048b 2ab46b31
7 af3a24d9 1b670769 cf771f9d fd0152ec ad2e048b
8 de5c70e6 af3a24d9 46d9c1da cf771f9d fd0152ec
9 696f053c de5c70e6 6bce8936 46d9c1da cf771f9d
10 a2a7c201 696f053c b7971c39 6bce8936 46d9c1da
11 19dc07e1 a2a7c201 1a5bc14f b7971c39 6bce8936
12 18e5db2b 19dc07e1 68a9f080 1a5bc14f b7971c39
13 3960bbc3 18e5db2b 467701f8 68a9f080 1a5bc14f
14 0162d4f7 3960bbc3 c63976ca 467701f8 68a9f080
15 35be3bf3 0162d4f7 ce582ef0 c63976ca 467701f8
16 1f1a20ef 35be3bf3 c058b53d ce582ef0 c63976ca
17 ce584377 1f1a20ef cd6f8efc c058b53d ce582ef0
18 c12dad7e ce584377 c7c6883b cd6f8efc c058b53d
19 07f86b69 c12dad7e f39610dd c7c6883b cd6f8efc
20 eec57612 07f86b69 b04b6b5f f39610dd c7c6883b
21 53744724 eec57612 41fe1ada b04b6b5f f39610dd
22 f068e89f 53744724 bbb15d84 41fe1ada b04b6b5f
23 d57d6b78 f068e89f 14dd11c9 bbb15d84 41fe1ada
24 bf8a1a67 d57d6b78 fc1a3a27 14dd11c9 bbb15d84
25 5988d6b2 bf8a1a67 355f5ade fc1a3a27 14dd11c9
26 2ba14e53 5988d6b2 efe28699 355f5ade fc1a3a27
27 6252fb22 2ba14e53 966235ac efe28699 355f5ade
28 40baa831 6252fb22 cae85394 966235ac efe28699
29 b4ea157c 40baa831 9894bec8 cae85394 966235ac
30 b5451650 b4ea157c 502eaa0c 9894bec8 cae85394
31 5eb50b03 b5451650 2d3a855f 502eaa0c 9894bec8
32 a66143d7 5eb50b03 2d514594 2d3a855f 502eaa0c
33 ea0fdc69 a66143d7 d7ad42c0 2d514594 2d3a855f
34 3aad42c0 ea0fdc69 e99850f5 d7ad42c0 2d514594
35 c60e5798 3aad42c0 7a83f71a e99850f5 d7ad42c0
36 b20906a8 c60e5798 0eab50b0 7a83f71a e99850f5
37 4bba01de b20906a8 318395e6 0eab50b0 7a83f71a
38 edbfe282 4bba01de 2c8241aa 318395e6 0eab50b0
39 8c3d6240 edbfe282 92ee8077 2c8241aa 318395e6
40 7bdcecf7 8c3d6240 bb6ff8a0 92ee8077 2c8241aa
41 d1ab7dd5 7bdcecf7 230f5890 bb6ff8a0 92ee8077
42 92c9f0bd d1ab7dd5 def73b3d 230f5890 bb6ff8a0
43 777946c3 92c9f0bd 746adf75 def73b3d 230f5890
44 783fe917 777946c3 64b27c2f 746adf75 def73b3d
45 ea8a796f 783fe917 ddde51b0 64b27c2f 746adf75
46 d1944385 ea8a796f de0ffa45 ddde51b0 64b27c2f
47 04e5232a d1944385 faa29e5b de0ffa45 ddde51b0
48 e4254e11 04e5232a 746510e1 faa29e5b de0ffa45
49 66ba8bc8 e4254e11 813948ca 746510e1 faa29e5b
50 45351d04 66ba8bc8 79095384 813948ca 746510e1
51 0b5dba0d 45351d04 19aea2f2 79095384 813948ca
52 d5395acb 0b5dba0d 114d4741 19aea2f2 79095384
53 c89e0c1b d5395acb 42d76e83 114d4741 19aea2f2
54 0de9320a c89e0c1b f54e56b2 42d76e83 114d4741
55 1e6d93f1 0de9320a f2278306 f54e56b2 42d76e83
56 9514bb84 1e6d93f1 837a4c82 f2278306 f54e56b2
57 b97107a2 9514bb84 479b64fc 837a4c82 f2278306
58 367ea0bd b97107a2 25452ee1 479b64fc 837a4c82
59 07bb47e4 367ea0bd ae5c41e8 25452ee1 479b64fc
60 f47c3f41 07bb47e4 4d9fa82f ae5c41e8 25452ee1
61 63a88718 f47c3f41 01eed1f9 4d9fa82f ae5c41e8
62 a5dd2d61 63a88718 7d1f0fd0 01eed1f9 4d9fa82f
63 f3016f6a a5dd2d61 18ea21c6 7d1f0fd0 01eed1f9
64 eca784a4 f3016f6a 69774b58 18ea21c6 7d1f0fd0
65 5f0e6c37 eca784a4 bcc05bda 69774b58 18ea21c6
66 fe2afead 5f0e6c37 3b29e129 bcc05bda 69774b58
67 d221b9b1 fe2afead d7c39b0d 3b29e129 bcc05bda
68 de1ad873 d221b9b1 7f8abfab d7c39b0d 3b29e129
69 43504e91 de1ad873 74886e6c 7f8abfab d7c39b0d
70 e14838bf 43504e91 f786b61c 74886e6c 7f8abfab
71 3353305e e14838bf 50d413a4 f786b61c 74886e6c
72 ef6bd90f 3353305e f8520e2f 50d413a4 f786b61c
73 4b39c7c4 ef6bd90f 8cd4cc17 f8520e2f 50d413a4
74 1e5ce93a 4b39c7c4 fbdaf643 8cd4cc17 f8520e2f
75 ca89f4d8 1e5ce93a 12ce71f1 fbdaf643 8cd4cc17
76 9fbe978e ca89f4d8 87973a4e 12ce71f1 fbdaf643
77 1de16953 9fbe978e 32a27d36 87973a4e 12ce71f1
78 c3ea2f20 1de16953 a7efa5e3 32a27d36 87973a4e
79 57ec91c2 c3ea2f20 c7785a54 a7efa5e3 32a27d36
80 9e1547ed 57ec91c2 30fa8bc8 c7785a54 a7efa5e3
81 9e1547ed 57ec91c2 30fa8bc8 c7785a54 a7efa5e3
79 00000000 00000000 00000000 00000000 359d3e2a
78 00000000 00000000 00000000 359d3e2a 00000000
77 00000000 00000000 359d3e2a 00000000 00000000
76 00000000 d674f8a8 00000000 00000000 5f284582
75 d674f8a8 00000000 00000000 5f284582 07d5e38e
74 00000000 00000000 5f284582 07d5e38e b31490c6
73 00000000 7ca11609 07d5e38e b31490c6 6d3cd8e9
72 7ca11609 1f578e38 b31490c6 6d3cd8e9 dffab6e4
71 1f578e38 cc52431a 6d3cd8e9 dffab6e4 48b86019
70 cc52431a b4f363a5 dffab6e4 48b86019 a6fab3b1
69 b4f363a5 7feadb93 48b86019 a6fab3b1 d1db0453
68 7feadb93 22e18065 a6fab3b1 d1db0453 9774f7d9
67 22e18065 9beacec6 d1db0453 9774f7d9 7c12cfcd
66 9beacec6 476c114f 9774f7d9 7c12cfcd 2f1abc61
65 476c114f 5dd3df66 7c12cfcd 2f1abc61 d52a363e
64 5dd3df66 f04b3f35 2f1abc61 d52a363e b811ad44
63 f04b3f35 bc6af184 d52a363e b811ad44 b8b7cbd4
62 bc6af184 54a8d8fb b811ad44 b8b7cbd4 447b8e5d
61 54a8d8fb e046b512 b8b7cbd4 447b8e5d 40621fa9
60 e046b512 e2df2f52 447b8e5d 40621fa9 9aa8b623
59 e2df2f52 11ee3975 40621fa9 9aa8b623 e45aceb9
58 11ee3975 01887ea5 9aa8b623 e45aceb9 95734533
57 01887ea5 6aa2d88e e45aceb9 95734533 6d4fdb3e
56 6aa2d88e 916b3ae7 95734533 6d4fdb3e 88a654c5
55 916b3ae7 55cd14ce 6d4fdb3e 88a654c5 605069f2
54 55cd14ce b53f6cf9 88a654c5 605069f2 a8767750
53 b53f6cf9 22995316 605069f2 a8767750 fe73456a
52 22995316 8141a7c9 a8767750 fe73456a 2a85e611
51 8141a7c9 a1d9dd42 fe73456a 2a85e611 c076d7c8
50 a1d9dd42 f9cd15ab 2a85e611 c076d7c8 ce246b10
49 f9cd15ab aa179844 c076d7c8 ce246b10 0ee48fa7
48 aa179844 01db5f23 ce246b10 0ee48fa7 18da0117
47 01db5f23 3891ac43 0ee48fa7 18da0117 c6bf6a01
46 3891ac43 3b923e9c 18da0117 c6bf6a01 45efefcb
45 3b923e9c 6368045c c6bf6a01 45efefcb ef3ead97
44 6368045c 1afda807 45efefcb ef3ead97 ef7648ad
43 1afda807 17bfbf2d ef3ead97 ef7648ad 855898f0
42 17bfbf2d bcfab65f ef7648ad 855898f0 e66f6c8c
41 bcfab65f bdd922b7 855898f0 e66f6c8c 43f40da6
40 bdd922b7 156263c2 e66f6c8c 43f40da6 2b543506
39 156263c2 99bdb233 43f40da6 2b543506 b1953441
38 99bdb233 0fd03699 2b543506 b1953441 d9c0f9d0
37 0fd03699 ad50d418 b1953441 d9c0f9d0 6bd7d9e8
36 ad50d418 c654d106 d9c0f9d0 6bd7d9e8 8297d6a5
35 c654d106 6703e743 6bd7d9e8 8297d6a5 e598df91
34 6703e743 af5f67a1 8297d6a5 e598df91 aead8e64
33 af5f67a1 0a5f5a96 e598df91 aead8e64 cad2fc0a
32 0a5f5a96 96637e47 aead8e64 cad2fc0a 027e1d16
31 96637e47 bab63992 cad2fc0a 027e1d16 5cfacd75
30 bab63992 2b4bf02b 027e1d16 5cfacd75 5af34007
29 2b4bf02b 09f87458 5cfacd75 5af34007 d26c4f62
28 09f87458 73eb35d5 5af34007 d26c4f62 81ef3ed9
27 73eb35d5 6bcd001d d26c4f62 81ef3ed9 e5695c63
26 6bcd001d 49b13d8b 81ef3ed9 e5695c63 5e39e756
25 49b13d8b 07bcfb66 e5695c63 5e39e756 09df22c0
24 07bcfb66 95a5718f 5e39e756 09df22c0 20f43111
23 95a5718f 78e79d59 09df22c0 20f43111 92684f4b
22 78e79d59 277c8b00 20f43111 92684f4b 73f6e565
21 277c8b00 83d0c444 92684f4b 73f6e565 b82de34a
20 83d0c444 49a13d2e 73f6e565 b82de34a bc0fdbce
19 49a13d2e cfdb9595 b82de34a bc0fdbce 3d18d998
18 cfdb9595 e0b78d2a bc0fdbce 3d18d998 369c3742
17 e0b78d2a f03f6f3a 3d18d998 369c3742 27cf1d48
16 f03f6f3a f4636660 369c3742 27cf1d48 46baeceb
15 f4636660 da70dd08 27cf1d48 46baeceb 0285eb98
14 da70dd08 9f3c7520 46baeceb 0285eb98 450b5cf4
13 9f3c7520 1aebb3ad 0285eb98 450b5cf4 50ddcf84
12 1aebb3ad 0a17ae60 450b5cf4 50ddcf84 96783800
11 0a17ae60 142d73d1 50ddcf84 96783800 eb162293
10 142d73d1 43773e11 96783800 eb162293 7f768223
9 43773e11 59e0e002 eb162293 7f768223 dbad15ed
8 59e0e002 ac588a4f 7f768223 dbad15ed 2ce32c8a
7 ac588a4f fdda088d dbad15ed 2ce32c8a 9aa3f7e5
6 fdda088d 6eb457b7 2ce32c8a 9aa3f7e5 d9f15a35
5 6eb457b7 b38cb228 9aa3f7e5 d9f15a35 f1da9dd2
4 b38cb228 6a8fdf96 d9f15a35 f1da9dd2 c8ca3eb4
3 6a8fdf96 67c568d7 f1da9dd2 c8ca3eb4 1d4426d0
2 67c568d7 c76a774b c8ca3eb4 1d4426d0 3f121481
1 c76a774b 2328fad3 1d4426d0 3f121481 02e1def6
0 2328fad3 75109b40 3f121481 02e1def6 cfd74e98
1 c76a774b 2328fad3 1d4426d0 3f121481 02e1def6
2 67c568d7 c76a774b c8ca3eb4 1d4426d0 3f121481
3 6a8fdf96 67c568d7 f1da9dd2 c8ca3eb4 1d4426d0
4 b38cb228 6a8fdf96 d9f15a35 f1da9dd2 c8ca3eb4
5 6eb457b7 b38cb228 9aa3f7e5 d9f15a35 f1da9dd2
6 fdda088d 6eb457b7 2ce32c8a 9aa3f7e5 d9f15a35
7 ac588a4f fdda088d dbad15ed 2ce32c8a 9aa3f7e5
8 59e0e002 ac588a4f 7f768223 dbad15ed 2ce32c8a
9 43773e11 59e0e002 eb162293 7f768223 dbad15ed
10 142d73d1 43773e11 96783800 eb162293 7f768223
11 0a17ae60 142d73d1 50ddcf84 96783800 eb162293
12 1aebb3ad 0a17ae60 450b5cf4 50ddcf84 96783800
13 9f3c7520 1aebb3ad 0285eb98 450b5cf4 50ddcf84
14 da70dd08 9f3c7520 46baeceb 0285eb98 450b5cf4
15 f4636660 da70dd08 27cf1d48 46baeceb 0285eb98
16 f03f6f3a f4636660 369c3742 27cf1d48 46baeceb
17 e0b78d2a f03f6f3a 3d18d998 369c3742 27cf1d48
18 cfdb9595 e0b78d2a bc0fdbce 3d18d998 369c3742
19 49a13d2e cfdb9595 b82de34a bc0fdbce 3d18d998
20 83d0c444 49a13d2e 73f6e565 b82de34a bc0fdbce
21 277c8b00 83d0c444 92684f4b 73f6e565 b82de34a
22 78e79d59 277c8b00 20f43111 92684f4b 73f6e565
23 95a5718f 78e79d59 09df22c0 20f43111 92684f4b
24 07bcfb66 95a5718f 5e39e756 09df22c0 20f43111
25 49b13d8b 07bcfb66 e5695c63 5e39e756 09df22c0
26 6bcd001d 49b13d8b 81ef3ed9 e5695c63 5e39e756
27 73eb35d5 6bcd001d d26c4f62 81ef3ed9 e5695c63
28 09f87458 73eb35d5 5af34007 d26c4f62 81ef3ed9
29 2b4bf02b 09f87458 5cfacd75 5af34007 d26c4f62
30 bab63992 2b4bf02b 027e1d16 5cfacd75 5af34007
31 96637e47 bab63992 cad2fc0a 027e1d16 5cfacd75
32 0a5f5a96 96637e47 aead8e64 cad2fc0a 027e1d16
33 af5f67a1 0a5f5a96 e598df91 aead8e64 cad2fc0a
34 6703e743 af5f67a1 8297d6a5 e598df91 aead8e64
35 c654d106 6703e743 6bd7d9e8 8297d6a5 e598df91
36 ad50d418 c654d106 d9c0f9d0 6bd7d9e8 8297d6a5
37 0fd03699 ad50d418 b1953441 d9c0f9d0 6bd7d9e8
38 99bdb233 0fd03699 2b543506 b1953441 d9c0f9d0
39 156263c2 99bdb233 43f40da6 2b543506 b1953441
40 bdd922b7 156263c2 e66f6c8c 43f40da6 2b543506
41 bcfab65f bdd922b7 855898f0 e66f6c8c 43f40da6
42 17bfbf2d bcfab65f ef7648ad 855898f0 e66f6c8c
43 1afda807 17bfbf2d ef3ead97 ef7648ad 855898f0
44 6368045c 1afda807 45efefcb ef3ead97 ef7648ad
45 3b923e9c 6368045c c6bf6a01 45efefcb ef3ead97
46 3891ac43 3b923e9c 18da0117 c6bf6a01 45efefcb
47 01db5f23 3891ac43 0ee48fa7 18da0117 c6bf6a01
48 aa179844 01db5f23 ce246b10 0ee48fa7 18da0117
49 f9cd15ab aa179844 c076d7c8 ce246b10 0ee48fa7
50 a1d9dd42 f9cd15ab 2a85e611 c076d7c8 ce246b10
51 8141a7c9 a1d9dd42 fe73456a 2a85e611 c076d7c8
52 22995316 8141a7c9 a8767750 fe73456a 2a85e611
53 b53f6cf9 22995316 605069f2 a8767750 fe73456a
54 55cd14ce b53f6cf9 88a654c5 605069f2 a8767750
55 916b3ae7 55cd14ce 6d4fdb3e 88a654c5 605069f2
56 6aa2d88e 916b3ae7 95734533 6d4fdb3e 88a654c5
57 01887ea5 6aa2d88e e45aceb9 95734533 6d4fdb3e
58 11ee3975 01887ea5 9aa8b623 e45aceb9 95734533
59 e2df2f52 11ee3975 40621fa9 9aa8b623 e45aceb9
60 e046b512 e2df2f52 447b8e5d 40621fa9 9aa8b623
61 54a8d8fb e046b512 b8b7cbd4 447b8e5d 40621fa9
62 bc6af184 54a8d8fb b811ad44 b8b7cbd4 447b8e5d
63 f04b3f35 bc6af184 d52a363e b811ad44 b8b7cbd4
64 5dd3df66 f04b3f35 2f1abc61 d52a363e b811ad44
65 476c114f 5dd3df66 7c12cfcd 2f1abc61 d52a363e
66 9beacec6 476c114f 9774f7d9 7c12cfcd 2f1abc61
67 22e18065 9beacec6 d1db0453 9774f7d9 7c12cfcd
68 7feadb93 22e18065 a6fab3b1 d1db0453 9774f7d9
69 b4f363a5 7feadb93 48b86019 a6fab3b1 d1db0453
70 cc52431a b4f363a5 dffab6e4 48b86019 a6fab3b1
71 1f578e38 cc52431a 6d3cd8e9 dffab6e4 48b86019
72 7ca11609 1f578e38 b31490c6 6d3cd8e9 dffab6e4
73 00000000 7ca11609 07d5e38e b31490c6 6d3cd8e9
74 00000000 00000000 5f284582 07d5e38e b31490c6
75 d674f8a8 00000000 00000000 5f284582 07d5e38e
76 00000000 d674f8a8 00000000 00000000 5f284582
77 00000000 00000000 359d3e2a 00000000 00000000
78 00000000 00000000 00000000 359d3e2a 00000000
79 00000000 00000000 00000000 00000000 359d3e2a
80 00000000 00000000 00000000 00000000 00000000
81 2328fad3 75109b40 3f121481 02e1def6 cfd74e98