From aba57d84004c878a2d3e8aab0c87127887571464 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Adolfo=20G=C3=B3mez?= Date: Tue, 5 Nov 2013 22:00:12 +0000 Subject: [PATCH] * Added support for Android OS * Updated HTML5 part a bit * Added printing support for guacamole --- server/src/uds/core/util/OsDetector.py | 6 +- server/src/uds/static/css/uds-html5.css | 10 +-- server/src/uds/static/img/login-img.png | Bin 2232 -> 5718 bytes server/src/uds/templates/uds/html5/index.html | 83 ++++++++++-------- server/src/uds/templates/uds/html5/login.html | 4 +- .../src/uds/transports/HTML5RDP/HTML5RDP.py | 4 +- server/src/uds/web/forms/LoginForm.py | 4 +- server/src/uds/web/views.py | 6 +- 8 files changed, 69 insertions(+), 48 deletions(-) diff --git a/server/src/uds/core/util/OsDetector.py b/server/src/uds/core/util/OsDetector.py index 3105a8862..c1983b6c6 100644 --- a/server/src/uds/core/util/OsDetector.py +++ b/server/src/uds/core/util/OsDetector.py @@ -38,9 +38,10 @@ logger = logging.getLogger(__name__) Linux = 'Linux' Windows = 'Windows' Macintosh = 'Macintosh' +Android = 'Android' -knownOss = { 'Linux' : Linux, 'Windows' : Windows, 'Macintosh' : Macintosh } +knownOss = { 'Linux' : Linux, 'Windows' : Windows, 'Macintosh' : Macintosh, 'Android': Android } def getOsFromUA(ua): ''' @@ -54,6 +55,7 @@ def getOsFromUA(ua): break except Exception: pass - logger.debug(res) + logger.debug('User-Agent: {0}'.format(ua)) + logger.debug('Detected OS: {0}'.format(res)) return res \ No newline at end of file diff --git a/server/src/uds/static/css/uds-html5.css b/server/src/uds/static/css/uds-html5.css index 98990ecc9..64e6440d0 100644 --- a/server/src/uds/static/css/uds-html5.css +++ b/server/src/uds/static/css/uds-html5.css @@ -1,9 +1,12 @@ @CHARSET "UTF-8"; +html, body { + height: 100%; +} + body { padding-top: 60px; padding-bottom: 40px; - background-color: #ffffff; } @media (max-width: 979px) { @@ -14,6 +17,7 @@ body { footer { + display: none; padding:1.6% 2%; margin-top:4em; text-align:right; @@ -85,13 +89,9 @@ footer { } .profile-img { - font-size: 96px; width: 96px; height: 96px; margin: 0 auto 10px; display: block; - -moz-border-radius: 50%; - -webkit-border-radius: 50%; - border-radius: 50%; } diff --git a/server/src/uds/static/img/login-img.png b/server/src/uds/static/img/login-img.png index 7de052010e911702252ab23d9dd30e9bcc902e34..f57a7827775db69b109248e75895dc5ba4f7d326 100644 GIT binary patch literal 5718 zcmV-c7OClpP)b03B&m zSad^gZEa<4bN~PV002XBWnpw>WFU8GbZ8()Nlj2>E@cM*02R7PL_t(|+U=cra2(a0 z$3L%+nbB!Uwq;{{0LHKh24S;^%ND^gpb(M}vI&F@A*mdjgHQz_fy80K8!Kd~ut|y> zEF`;N!A69zu&~+4K*V8eune|QY=g0lZ%ZEQ)*L<4-S6!m(~@Q+jjYkxsmiaaEo-LL z{rdNPzw`axuLV;?^^N5kpaa@~Lk#iL5Q1VM$PSBB5}c)RXl- zoXGx^F3{l}tw1{v_P{v;9QD3y1C9g7#v2qdj?69rJ^-8noDMAT7+mTdB_0TQBe|Yw z3gU6a-uG<|9CT@Gm-O^VA`wa4QV5X(rkByZOcvumrJ^45TRcGC0X6}zHPl%hQwBhN zV|fv974Tu;5}+I~fglj@)JN_E5};{<4X;~lecL7;S2&JBsmxhDg(QJE5COIVziOzn zo|{krJbfJiP6e(5KI6^y@zsX{+S(;gJQ=04OQGvSou&HBgG$Z)w8s!x&QJd-y|ZN6 zXJb|d?Z6t~w?I!WYD$biho1$k1pW~?d%}#7fJ28}o_Z#R<*Arn#tB@&AR$h|)@EXh z*(Ag)98rQ4g*b$eB7mY`5K{$lG?M7bLRWE&K$4)DM0YyS+~a5}h9)EEZa13jLU%g> zCk3!b_X|cu$2=gOY^bx2jR}DI#_}tGFMBGcY@+2l9#=f`T$}?39WcTuG5 z9hgHzKc7Q^Td=e_Nb>s_o)amF7Aznz{bY~v*;pXbq{c?bIGT#1yFC=d-=L^x9R<%}ql})ytBB_>L*SBcZT5`zkT&A#Qx_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83wY9PAliNpOwli637c|2(!A~9-nZO2Z#2(t^FUX2$KgOYC zixpWBS8fhJHkfY78hpz%B=7)DF$);Vc|Rai@TWCBJ&W*DOrRLoZZobXrrPbPsF-%r z|K*Zj1ayA{Pi z65TYqAfOcz9?6(|W$k5ZzS=F;PY-_w(Dr7NovjKGtZ`Sa0>s8AmD1driUR`fkiWn) z#bjiMJw-armHS=Q3?RwPqUnGIug{qU^ZV#3>FjR1hIkWGOm|L^B0h zY?=nY_^~_bh4~(IziUd{k51XIZt6G~=7B_fH7ImUk1(|7j+YnqH(^w<>$;(ZUxmdIB5;mUh$&2u~LFv z*9}oQ7kogvcfbd4jC$Ytt-=Rn=#*6NWXZ{^&rn1lYbwRG`9WauYOgm@h#J|}H04I# zR9-wZQ@P7-8A%u-_(Qayvy-O4L}H;vb1O0bK$nP1%yzH{Hshs}hFd>wyM$w7!)x1d zaYN2<8!B4vxDJN`%+vb{aHT8DX<$WN`JVQax|<+x>pSC3GJmaZMwTF%^XVY6(j(kC z!%GXchI2V!_kqhc@?+OKyxI`(j~ca=%z&Gq`2JMwvc@9Osx%nXOeh)5^h)N_{;AKI zWtV-^5q8O|S~o|Trh?Q7QjfR-9;g>@OfcadfLx1hZTQ7>UAb5+o{8W8?GmCe_zpea zlni3vJ#IBnzZ`sil9A!#;RdgrEyrsYX_-AM9!J6QQi_|N*MHZUY<($U@Rx+ETb==4}{$#;lH z;+;dc@Wj)o + .testing { + width: 95px; + height: 95px; + margin-bottom: 16px; + margin-left: 16px; + + background: rgb(255,255,255); /* Old browsers */ + background: -moz-linear-gradient(top, rgba(255,255,255,1) 0%, rgba(229,229,229,1) 100%); /* FF3.6+ */ + background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,rgba(255,255,255,1)), color-stop(100%,rgba(229,229,229,1))); /* Chrome,Safari4+ */ + background: -webkit-linear-gradient(top, rgba(255,255,255,1) 0%,rgba(229,229,229,1) 100%); /* Chrome10+,Safari5.1+ */ + background: -o-linear-gradient(top, rgba(255,255,255,1) 0%,rgba(229,229,229,1) 100%); /* Opera 11.10+ */ + background: -ms-linear-gradient(top, rgba(255,255,255,1) 0%,rgba(229,229,229,1) 100%); /* IE10+ */ + background: linear-gradient(to bottom, rgba(255,255,255,1) 0%,rgba(229,229,229,1) 100%); /* W3C */ + filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#ffffff', endColorstr='#e5e5e5',GradientType=0 ); /* IE6-9 */ + overflow: hidden; + } + +{% endblock %} + {% block js %}