git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [BULLS**T PATCH] Allow Git to work at Insane Bank Corp
@ 2007-11-15  1:52 Shawn O. Pearce
  2007-11-15  2:13 ` Johannes Schindelin
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Shawn O. Pearce @ 2007-11-15  1:52 UTC (permalink / raw)
  To: git

Oh what a day I've had.  Today Insane Bank Corp (my day-job employer)
upgraded their Windows desktop encryption software.  *Every*
directory on every computer is now blessed with a "Desktop.ini" file.
Git of course loves this concept:

 $ git for-each-ref >/dev/null && echo yes
 error: refs/Desktop.ini points nowhere!
 error: refs/heads/Desktop.ini points nowhere!
 yes

Fortunately for-each-ref allows corrupt refs to exist in the ref
namespace.  So until Git is properly patched we are at least able
to ignore these error messages.

For corporate security reasons it is obviously absolutely vital that
these Desktop.ini files exist in every directory of every system.
Even if application software scans all files in a particular
directory and assumes those files belong to it.  If these files did
not exist it would not be possible for Insane Bank Corp to protect
its customer's data, which of course must be toted around on $1000
laptops in the posession of any employee who asks for one.

Because Insane Bank Corp is one of the largest banks in the world
all 3rd party software vendors must comply and correct their
applications to not fail when they encounter Desktop.ini in an
application's internal data directory.  Or they will lose their
contract with Insane Bank Corp.

This patch must be applied to Git, since Git is a 3rd party software
product and its global assets are much smaller than those of Insane
Bank Corp.  If not applied Git won't be permitted for use.  Git could
lose all of its software licenses and support contracts.  Git shall
do as Insane Bank Corp requests.

Never-Shall-Be-Signed-Off-By: me

---

 </rant off>

 Seriously, this patch shouldn't ever be made to Git.  I'll likely
 have to carry it in my own local build process until the end
 of time.

 Our corporate security goons are unable to fathom why having
 "Desktop.ini" shoved into every directory of every filesystem may
 cause problems for some applications.  Especially those who may
 attempt to read every file in a given directory.

 Just thought folks would like to see what sort of bulls**t patches
 internal developers need to create for systems because they are
 unable to rely upon the operating system they are forced to rely
 upon for "security reasons".  Yes, really, Insane Bank Corp feels
 that Microsoft Windows Xtreme Professional is more trustworthy
 than RedHat Linux.  Especially when toted in someone's backpack.
 Just so long as Desktop.ini is in every directory we're safe.

 Grrrrrrrrrrrrr.

 </rant really is now off>

 git-compat-util.h |   13 +++++++++++++
 1 files changed, 13 insertions(+), 0 deletions(-)

diff --git a/git-compat-util.h b/git-compat-util.h
index ca0a597..ca875c7 100644
--- a/git-compat-util.h
+++ b/git-compat-util.h
@@ -172,6 +172,19 @@ extern uintmax_t gitstrtoumax(const char *, char **, int);
 extern const char *githstrerror(int herror);
 #endif
 
+#ifdef WORK_FOR_INSANE_BANK_CORP
+static inline struct dirent *gitreaddir(DIR *dirp)
+{
+	struct dirent *r;
+	while ((r = readdir(dirp))) {
+		if (!strcasecmp(r->d_name, "Desktop.ini"))
+			continue;
+	}
+	return r;
+}
+#define readdir gitreaddir
+#endif
+
 extern void release_pack_memory(size_t, int);
 
 static inline char* xstrdup(const char *str)
-- 
1.5.3.5.1728.g34b3e

^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [BULLS**T PATCH] Allow Git to work at Insane Bank Corp
  2007-11-15  1:52 [BULLS**T PATCH] Allow Git to work at Insane Bank Corp Shawn O. Pearce
@ 2007-11-15  2:13 ` Johannes Schindelin
  2007-11-15  2:27   ` Shawn O. Pearce
  2007-11-15  2:30 ` Morten Welinder
  2007-11-15  3:36 ` Junio C Hamano
  2 siblings, 1 reply; 5+ messages in thread
From: Johannes Schindelin @ 2007-11-15  2:13 UTC (permalink / raw)
  To: Shawn O. Pearce; +Cc: git

Hi,

On Wed, 14 Nov 2007, Shawn O. Pearce wrote:

> For corporate security reasons it is obviously absolutely vital that
> these Desktop.ini files exist in every directory of every system.

This makes sense, absolutely.

> Never-Shall-Be-Signed-Off-By: me

Never-To-Be-Acked-By: me.

But seriously, some things like these should make it possible for one of 
the fastest SCMs in the world (both in performance and in development) to 
get some serious contracts.

I mean, how does svn cope with something like that?

Ciao,
Dscho

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [BULLS**T PATCH] Allow Git to work at Insane Bank Corp
  2007-11-15  2:13 ` Johannes Schindelin
@ 2007-11-15  2:27   ` Shawn O. Pearce
  0 siblings, 0 replies; 5+ messages in thread
From: Shawn O. Pearce @ 2007-11-15  2:27 UTC (permalink / raw)
  To: Johannes Schindelin; +Cc: git

Johannes Schindelin <Johannes.Schindelin@gmx.de> wrote:
> On Wed, 14 Nov 2007, Shawn O. Pearce wrote:
> 
> > For corporate security reasons it is obviously absolutely vital that
> > these Desktop.ini files exist in every directory of every system.
> 
> But seriously, some things like these should make it possible for one of 
> the fastest SCMs in the world (both in performance and in development) to 
> get some serious contracts.

Well, see, you can't actually use Git at Insane Bank Corp because it
wasn't put on the approved list of software.  Furthermore if it was
put on that list it would probably only ever be approved for use on
RedHat Linux, as on Windows there is Microsoft Visual Source Suck
and on Solaris there is Rational ConfusingCase.  All provide the
same function and therefore are exactly suitable for those platforms.

Any deviants get Desktop.ini files where they don't want them.

Keep in mind that Insane Bank Corp has approved the following OS
and database combinations, as they are all the same thing.  Any
mixing/matching is not permitted:

  OS         Database
  ------------------------------
  Windows    Microsoft SQL Server
  Solaris    Oracle
  AIX        IBM DB2
  Linux      MySQL

Because you can do anything that Oracle does with MySQL if Linux
is your OS.  Didn't you know that MySQL understands all of Oracle's
extended SQL syntax?  Silly developers.  :-)
 
> I mean, how does svn cope with something like that?

SVN probably doesn't care.  As in SVN probably only scans the working
directory, which you can tell it to ignore Desktop.ini files in.
When it looks at the SVN/ metadata directory in a checkout it
probably knows exactly what files its going after.  Extra files
don't matter to it.

In the fsfs and bdb backends SVN is probably again only going after
known filenames.  So it probably isn't impacted by extra crap shoved
into the directory.


I'm waiting for the next release of the desktop security software,
the one that adds an extra 1M binary header to the front of every one
of Java source files, because that's the only way they can protect
the data that never should have been on a portable computing device
in the first place.

I can't wait for Java 6 update 4 Special Edition for Insane Bank
Corp version to be rolled out to ignore those headers.  Or for the
Eclipse 3.3.1.1.1 release which will also ignore those headers.

-- 
Shawn.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [BULLS**T PATCH] Allow Git to work at Insane Bank Corp
  2007-11-15  1:52 [BULLS**T PATCH] Allow Git to work at Insane Bank Corp Shawn O. Pearce
  2007-11-15  2:13 ` Johannes Schindelin
@ 2007-11-15  2:30 ` Morten Welinder
  2007-11-15  3:36 ` Junio C Hamano
  2 siblings, 0 replies; 5+ messages in thread
From: Morten Welinder @ 2007-11-15  2:30 UTC (permalink / raw)
  To: Shawn O. Pearce; +Cc: git

Can't you just load a root kit^w^wsystem extension that hides such
files from any
and all application?

Morten

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [BULLS**T PATCH] Allow Git to work at Insane Bank Corp
  2007-11-15  1:52 [BULLS**T PATCH] Allow Git to work at Insane Bank Corp Shawn O. Pearce
  2007-11-15  2:13 ` Johannes Schindelin
  2007-11-15  2:30 ` Morten Welinder
@ 2007-11-15  3:36 ` Junio C Hamano
  2 siblings, 0 replies; 5+ messages in thread
From: Junio C Hamano @ 2007-11-15  3:36 UTC (permalink / raw)
  To: Shawn O. Pearce; +Cc: git

"Shawn O. Pearce" <spearce@spearce.org> writes:

> Because Insane Bank Corp is one of the largest banks in the world
> all 3rd party software vendors must comply and correct their
> applications to not fail when they encounter Desktop.ini in an
> application's internal data directory.  Or they will lose their
> contract with Insane Bank Corp.
>
> This patch must be applied to Git, since Git is a 3rd party software
> product and its global assets are much smaller than those of Insane
> Bank Corp.  If not applied Git won't be permitted for use.  Git could
> lose all of its software licenses and support contracts.  Git shall
> do as Insane Bank Corp requests.

.gitignore?	... ducks ... then comes back.

> +#ifdef WORK_FOR_INSANE_BANK_CORP
> +static inline struct dirent *gitreaddir(DIR *dirp)
> +{
> +	struct dirent *r;
> +	while ((r = readdir(dirp))) {
> +		if (!strcasecmp(r->d_name, "Desktop.ini"))
> +			continue;
> +	}
> +	return r;
> +}
> +#define readdir gitreaddir
> +#endif

Something like this could be used as an emulation layer for
case-corrupting filesystems ;-)

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2007-11-15  3:36 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-11-15  1:52 [BULLS**T PATCH] Allow Git to work at Insane Bank Corp Shawn O. Pearce
2007-11-15  2:13 ` Johannes Schindelin
2007-11-15  2:27   ` Shawn O. Pearce
2007-11-15  2:30 ` Morten Welinder
2007-11-15  3:36 ` Junio C Hamano

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).