On Wed, Sep 22, 2010 at 12:21 PM, Peter Eisentraut <peter_e@gmx.net> wrote:
> On ons, 2010-09-22 at 16:03 +0200, Magnus Hagander wrote:
>> That basically means that git-cvsserver is completely useless in a
>> public scenario as it stands. An easier way to DOS our server is hard
>> to find, really.
>>
>> Now, if we can limit this by IP address, that would be ok. I assume we
>> can do this for the NLS stuff - peter?
>
> Well, let's see. If someone can figure out the git equivalent of
>
> if cvs -q update | egrep -q '^(U|P) '; then
> # ... something changed, so run the update ...
> fi
>
> (assuming, for simplicity, that the current directory has the
> appropriate branch checked out already)
>
> then I might be able to get this fixed.
Can you just check whether the commit SHA of HEAD has changed? e.g.
git show-ref --heads -s master
git log --format=format:%H -n 1 master
...and compare with previous results of same?
--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise Postgres Company