You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@subversion.apache.org by "Dassi, Nasser" <ND...@141xm.com> on 2005/01/26 21:03:50 UTC
Bug? FSFS revision control
I may have found something risky security and integrity-wise.
Issue:
The revision number with file-type FSFS is manually modifyable in any
ol' text editor. The value (in a file within the repository's file
structure) is stored in plain-text and can be edited with extreme ease.
Potential risk:
Whomever has access to the repository's directory (not via interfaces,
but directly at file-system level) can easily modify and alter and
possibly wipe clean the actual revision history.
How to reproduce:
1. Open notepad, and open the file "path-to-repo/db/current"
2a. Edit first number set (this is the revision number) to any desired
number.
2b. Once you save the file, the HEAD revision is whatever value you
input.
3. Update your working copy; expect "conflicts" to exist everywhere
based on whatever differences exist between the "current revision"
(manually input) and "youngest revision" (before modifying the version
number).
4. Mark any/all conflicts as resolved.
5. Commit. Your revision number is now your manually-input revision +
1.
Reproduced using:
Windows XP SP2 Professional
Subversion 1.1.1 (r11581) Server
Subversion 1.1.3 Client
TortoiseSVN 1.1.3 Client
Keep in mind:
The steps taken to reproduce are easily attainable in a command-line
approach with not GUI client.
Possible/suggested bug fix/workaround solutions:
1. Implement integrity checking to cause future modified-repository
commits to fail; or
2. Implement revision-locking at the filesystem level so existing
revprops + revs files are not *overwritten*; or
3. Revert to latest revision based on FSFS-stored revprops and revs file
trails; or
4. Implement encoding/encryption to reduce likelihood of tampering (as
Berkeley DB does)
- nasser
Nasser Dassi
Sr. Technical Programmer
=========================================
E: ndassi@141xm.com
=========================================
Re: Bug? FSFS revision control
Posted by Toby Johnson <to...@etjohnson.us>.
Dassi, Nasser wrote:
> Potential risk:
> Whomever has access to the repository's directory (not via interfaces,
> but directly at file-system level) can easily modify and alter and
> possibly wipe clean the actual revision history.
>
Whoever has write access to the repository's directory can do a whole
lot more damage than modifying the revision number. That's why proper
filesystem security should be applied.
No attempt was made (or desired) to obfuscate the storage format in
FSFS; in fact, many old CVS hackers like being able to read the backend
storage.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: Bug? FSFS revision control
Posted by Garrett Rooney <ro...@electricjellyfish.net>.
Dassi, Nasser wrote:
>
> I may have found something risky security and integrity-wise.
>
> Issue:
> The revision number with file-type FSFS is manually modifyable in any
> ol' text editor. The value (in a file within the repository's file
> structure) is stored in plain-text and can be edited with extreme ease.
>
> Potential risk:
> Whomever has access to the repository's directory (not via interfaces,
> but directly at file-system level) can easily modify and alter and
> possibly wipe clean the actual revision history.
Umm, I hate to break it to you, but they can do the same thing to any
system. It's the same with BDB, the files are binary, but if you know
what you're doing you can still modify them. As for detecting such
modifications, how would you do that? Store a checksum or something?
Where? If the user can modify the revision files they can also modify
the file you store the checksum of the revisions in... Once someone has
write access to the revision files you've already lost the battle, they
can essentially do whatever they want.
-garrett
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: Bug? FSFS revision control
Posted by Marc Haisenko <ha...@webport.de>.
On Friday 28 January 2005 16:33, Roel Harbers wrote:
> Dassi, Nasser wrote:
> > I may have found something risky security and integrity-wise.
>
> No you haven't. You are so wrong it's not even funny.
>
> I hope you are trolling, and if so, congratulations, you have succeeded.
>
> If you are not: I think you are confusing some layers of operation here:
> svn clients do NOT need, nor do they generally have, write or even
> read access to the repository files. So, in a normal situation, a user
> will NOT be able to destroy the repository. Not even with notepad.
>
> Regards,
>
> Roel Harbers
Now, /this/ was just unnecessary and especially unnecessarily rude !
C'ya,
Marc
--
Marc Haisenko
Systemspezialist
Webport IT-Services GmbH
mailto: haisenko@webport.de
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: Bug? FSFS revision control
Posted by Roel Harbers <ro...@roelharbers.nl>.
Dassi, Nasser wrote:
>
> I may have found something risky security and integrity-wise.
No you haven't. You are so wrong it's not even funny.
I hope you are trolling, and if so, congratulations, you have succeeded.
If you are not: I think you are confusing some layers of operation here:
svn clients do NOT need, nor do they generally have, write or even
read access to the repository files. So, in a normal situation, a user
will NOT be able to destroy the repository. Not even with notepad.
Regards,
Roel Harbers
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: Bug? FSFS revision control
Posted by Max Bowsher <ma...@ukf.net>.
Tom Mornini wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> On Jan 26, 2005, at 1:03 PM, Dassi, Nasser wrote:
>
>> Issue:
>> The revision number with file-type FSFS is manually modifyable in any
>> ol' text editor. The value (in a file within the repository's file
>> structure) is stored in plain-text and can be edited with extreme
>> ease.
>
> snip...
>
>> Possible/suggested bug fix/workaround solutions:
>> 1. Implement integrity checking to cause future modified-repository
>> commits to fail; or
>> 2. Implement revision-locking at the filesystem level so existing
>> revprops + revs files are not *overwritten*; or
>> 3. Revert to latest revision based on FSFS-stored revprops and revs
>> file trails; or
>> 4. Implement encoding/encryption to reduce likelihood of tampering
>> (as Berkeley DB does)
>
> 5. Implement OS level file security (per OS, per installation) to
> prevent access to people who should not be able to do this.
>
> You know, I just discovered another bug in both Subversion AND FSFS!
>
> If you manually give OS commands to destroy your repository, your
> repository is destroyed, and Subversion neither prevents,
> nor gives adequate warning, nor automatically ignores the results of
> those commands. Additionally, it gives no method of
> fixing the problem directly.
>
> Now, I'm finding bugs in nearly everything:
>
> 1) Televisions stop working when dropped
> 2) Knives make people bleed when used improperly.
> 3) Guns...don't even get me started!
>
> I'm sort of having a bad day, and might regret this email later, but I
> have to ask:
>
> Was this a serious email (bad) or intended as a joke (funny)?
LOL! :-)
I agree entirely - thanks for making the point so splendidly.
Thanks,
Max.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: Bug? FSFS revision control
Posted by Tom Mornini <tm...@infomania.com>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On Jan 26, 2005, at 1:03 PM, Dassi, Nasser wrote:
> Issue:
> The revision number with file-type FSFS is manually modifyable in any
> ol' text editor. The value (in a file within the repository's file
> structure) is stored in plain-text and can be edited with extreme
> ease.
snip...
> Possible/suggested bug fix/workaround solutions:
> 1. Implement integrity checking to cause future modified-repository
> commits to fail; or
> 2. Implement revision-locking at the filesystem level so existing
> revprops + revs files are not *overwritten*; or
> 3. Revert to latest revision based on FSFS-stored revprops and revs
> file trails; or
> 4. Implement encoding/encryption to reduce likelihood of tampering
> (as Berkeley DB does)
5. Implement OS level file security (per OS, per installation) to
prevent access to people who should not be able to do this.
You know, I just discovered another bug in both Subversion AND FSFS!
If you manually give OS commands to destroy your repository, your
repository is destroyed, and Subversion neither prevents,
nor gives adequate warning, nor automatically ignores the results of
those commands. Additionally, it gives no method of
fixing the problem directly.
Now, I'm finding bugs in nearly everything:
1) Televisions stop working when dropped
2) Knives make people bleed when used improperly.
3) Guns...don't even get me started!
I'm sort of having a bad day, and might regret this email later, but I
have to ask:
Was this a serious email (bad) or intended as a joke (funny)?
- --
- -- Tom Mornini
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (Darwin)
iD8DBQFB+AmszaKkuvKwKvcRAgTHAJ4p7yoWHQOVjCsm8AsZ4RI48uqBMwCfQqO3
c6VuyDPjjSRbHMIc9OqCko8=
=u4YY
-----END PGP SIGNATURE-----
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org