Pen Drive Permission

S.E.R.E.N.A

Well-known member
  • Jun 27, 2018
    1,370
    1
    885
    113
    Pen drive එකක් write protected විදියට හදාගන්න ක්‍රමයක් නැද්ද?
    ඒ කියන්නේ වෙන්න ඕනේ, මට ඕනේ වෙලාවට එහෙම හදාගත්තම ඒකට කිසිම file එකක් copy කරන්න බැරි වෙන්න ඕනේ වෙන PC එකකට plug කළත්.
    ඒකේ තියන ඒවා copy කරගන්න පුළුවන් වෙන්න ඕනේ.
    ආයේ ඕනේ වුනාම pen drive එකට file copy කරන්න පුළුවන් විදියට හදාගන්නත් පුළුවන් වෙන්න ඕනේ.
    (virus වලින් බේරෙන්න ඕනේ නිසා)

    මේ ක්‍රම වලට try කළා. හරියන්නේ නෑ.
    Linux Mint වලින්, sudo hdparm -r1 /dev/sdd1
    ඔතන -r1 වෙනුවට -r0 දැම්මම write protected අයින් වෙනවා. Linux Mint වලදී වැඩ.
    ඒත් Windows PC එකකදී files copy කරන්න පුළුවන්.

    ඊළඟට Windows (7 SP1) වලින්,
    CMD > diskpart > select disk 1 > attributes disk set readonly
    හරිගියෙත් නෑ.

    veracrypt එකෙන් pendrive එක encrypt කරලා read only කරලා open කළහැකි.
    නමුත් ප්‍රශ්නේ veracrypt හැම pc එකකම නෑ. එහෙම install කරන්නත් බැහැනේ pendrive එකක් plug නොකර.

    හදිසියට එක එක computer වලට pen drive plug කරලා pen drive එකේ files copy කරන්න ඕනේ, ඒ pc වල virus pendrive එකට එන්නේ නැති වෙන්න.
    කොහොමද කරන්නේ? පුළුවන් නම් දීපල්ලකො උත්තර! :baffled:
     

    S.E.R.E.N.A

    Well-known member
  • Jun 27, 2018
    1,370
    1
    885
    113
    does it work on linux ?
    නැහැ, linux වල read only වෙන්නේ නැහැ.
    මෙහෙම හදලා linux වලදී files copy කරන්න පුළුවන්. හැබැයි linux වලින් files copy කළොත් windows වල pen එක format නොකර open කරන්න බැරි වෙනවා සමහර වෙලාවට.
    ඒ නිසා windows වලින්ම permission ආයේ හදලා ඕනේ files copy කරනවා නම් කරන්න ඕනේ.
    (වීඩියෝ එකේ වගේ write permission දීලා folder එකක් හැදුවොත් ඒකට copy කළාට ප්‍රශ්නයක් නෑ linux / windows දෙකෙන්ම)

    මට නම් මේ ක්‍රමේ සාර්ථකයි. මොකද මගේ pc එක linux නිසා ඒකෙන් ඕනේ දේවල් ටික කොපි කරගෙන ගිහින්
    windows තියන pc වලට copy කරන්න විතරයි ඕනේ නිසා.
    නැත්නම් කලින් virus තියන එක windows pc එකකට pen එක ගැහුව ගමන් pen එකට virus ඇවිත් අනිත් ඔක්කොම windows pc ටිකට virus ටික යනවා.
    (windows වලින් permission හදාගන්නේ virtualbox එකක win 7 දාගෙන)
     

    imhotep

    Well-known member
  • Mar 29, 2017
    14,824
    8
    35,333
    113
    If you need OS Independent write protection here are some ideas.

    1. Purchase a USB with a write protect switch and make sure that it's always set ON.

    2. There are devices that connects between the computer and your USB. THese devices allows data to be copied from the USB to the computer. However, if you write to the USB, the computer will believe that that data is copied (the hardware in between fakes the write operation), but no data is ever copied to the USB.
    These are not cheap as they are not targeted to the home user.
    Note: There are cheap ones in eBay but I believe they disconnected the data signal wires and allows only power to pass through. So probably these will not 'read' or mount either.

    3. The other easy method. Just fill up the free space of the USB so that there isn't any space to write anything. There are so many utilities that will dummy fill your device. Else you can write a small bash script to do the same.