Saturday, March 7, 2015

Designing an Automatic Laundry System

Why It’s Almost Impossible To Teach a Robot To Do Your Laundry?

It's not impossible. We just need to simplify the tasks to make it tractable for machines. Here are the steps outlined in the pessimistic post, and how to simplify them.
  1. Find the pile of dirty laundry, distinguishing it from other clutter that might be in the room.
    • Instead of tasking the robot to tell apart garments from clutter in the room, the robot should receive the garments from a designated drop-off point.
  2. Pick up each item in the pile. (Uncertainty: it’s unclear how many objects the robot will have to pick up.)
    • The drop-off will contain bins or bags classified by garment type, so the robot will never have to pick up garments and put them in the basket.
  3. Put each item in a laundry basket.
    • As far as the robot is concerned, the garments are already sorted.
  4. Navigate to the washing machine. (Because of where the robot has to hold the laundry basket, it can obstruct some of the its sensors which means it receives less information and cannot adjust its movements as precisely.)
    • In some homes, it is possible to build laundry chute to solve the transportation problem.
  5. Depending on the type of machine, pull or lift the door to open it.
    • The machine could be designed with a standardized and easy to open door.
  6. Transfer clothes into the machine.
    • We can design the laundry bins to be the canister that fits into the washer and dryer as part of the driver, so we don't need to transport clothes between containers. In the case of laundry bags, the bags themselves will go into the washer and dryer, so they will be made of meshed design.
  7. Add detergent and/or fabric softener.
    • The detergent and fabric softener should already be in a container that feeds into the machine. Human operator only needs to check the liquid levels periodically or receive an automated alert when they run low.
  8. Close the washing machine door.
    • Again, design the door to be easily operable.
  9. Choose the appropriate wash cycle (Delicate, Permanent Press, Heavy Duty) and start the wash.
    • Each bin or bag at the drop-off will select the wash cycle. This eliminates the selection process. In the future, we might design a sorter based on an RFID tag sewed onto the clothing, and have the sorter put clothes in the bin or bag automatically.
  10. Remove the clothes from the washing machine and transfer to the dryer. (Uncertainty: the robot doesn’t know beforehand how many times it will need to reach in, grab the clothes, and remove them in order to get them all.)
    • Again the bin or bag will facilitate transport from the washer to the dryer in batch.
  11. Choose the type of drying cycle and start it.
    • The bin or bag type will determine the drying cycle.
  12. Remove clothing from the dryer. (Uncertainty: how many times will it have to grab the clothes to get them out? Is there a sock still clinging to the inside of the machine?)
    • At the end of the cycle, the bin or bag will be transported either to a person to fold the clothing, or in the future, to a folding machine.
  13. Fold items depending on the type of apparel.
  14. Puts garments away in a dresser or closet.
    • Instead of retrieving clean clothes from a closet, perhaps the machine will just put the folded clothes packed in a box. It saves space too.
The idea is that let humans do what we do best, and let the robots do the rest. Most of the steps are already solvable using today's technology without sophisticated artificial intelligence. Some of the steps involving human can use a designated machine in the future, such as sorting and folding.

Sunday, March 1, 2015

Why Perfect Forward Secrecy won't work over PGP?

Repeat the title here: Why Perfect Forward Secrecy won't work over PGP?

tl;dr because it's a logistic nightmare.

Perfect forward secrecy uses a one-time session key to secure a cryptographic communication channel using a long term key. The session key is negotiated in such a way that gaining access to the long term key will not recover the session key, so if the long term key is compromised, it cannot be used to decrypt a previously eavesdropped communication.

Of course, the compromised long term key could be used by a malicious third-party to impersonate as the victim in negotiating the cryptographic communication channel in the future.

An example of perfect forward secrecy is Diffie-Hellman key exchange. Such key exchanges are typically implemented over TLS where two computers automatically negotiate the cryptographic channel transparently to the users.

PGP, on the other hand, involves the user heavily as part of the negotiation. First you need to decide whom you include in your Web of Trust, by verifying in person their public key fingerprint. Without this step, you could be encrypting an important message for the wrong party. Then when you encrypt, you need to pick a cipher algorithm that your recipient's software knows how to decrypt. Back then it was a confusing boatload of 3DES, IDEA, TwoFish, BlowFish which sound like something from Dr. Suess. Nowadays you could count on AES. PGP then creates a random symmetric key, encrypts it with the recipient's public key, and produces the cipher text for you to deliver. This process is already onerous in itself. Only the most determined individual would put up with this effort.

For Perfect Forward Secrecy to work, both the sender and the recipient have to contribute to the creation of the one-time session key. You need to first complete the key negotiation, send the negotiation to the recipient and hear back, before you can encrypt the actual message. You can't have Perfect Forward Secrecy without participation from the recipient. This is a logistic nightmare.

This is not to say that even more determined pair of individuals could pull this off.