Hi,
Is it safe to query with object.get without escaping or validation user submitted value?
For example:
some_var = request.POST.get('some_key')
obj = MyModel.objects.get(name=some_var)
Can the user submit malicious data?
Thanks
Hi
I want to delete the unused drupal modules like ( blog, Forum, taxonomy ...) but I'm worried if I delete the modules from the modules directory I might cause an error (now or in the future) .
is it safe? and if I deleted the corresponding tables what will happen?
the reason for this is because I want to deliver the site to my client, and teach him how to use the admin page, but I want to make as easy as possible for him..
Can this code help to sanitize malicious code in user submit form?
function rex($string) {
$patterns = array();
$patterns[0] = '/=/i';
$patterns[1] = '/javascript:/i';
$replacements = array();
$replacements[0] = '';
$replacements[1] = '';
return preg_replace($patterns, $replacements, $string);
I have included htmlentities() to prevent XSS on client side, is all the code shown is safe enough to prevent attack?
I want to create a method sum that I can call on different types, specifically sum(1,2).
def sum[A](a1: A, a2: A) = a1 + a2
This fails because the compiler can't tell if A has a method '+'
I tried to define a structural type:
type Addable = {def +(a: Addable)}
This fails because of an illegal cyclic reference
How can I achieve this in a type safe way without requiring A to extend a specific trait?
I have to sanitize a part of sql query. I can do something like this:
class << ActiveRecord::Base
public :sanitize_sql
end
str = ActiveRecord::Base.sanitize_sql(["AND column1 = ?", "two's"], '')
But it is not safe because I expose protected method. What is a better way to do it?
should i after i have created a svn repo, import one project folder into it with "svn import" and then DELETE my original local folder thus only having it in the svn repo in the remote ubuntu server?
is this safe or should i still have a local copy for some reason (cause i wont work in that one)?
I know containers of auto pointers should not be used and can cause problem. What is the actual reason for that? Is that any other kind of "smart" pointer which is safe to use in a container?
Hello,
Word is giving me alot of issues with UT8 content, it usually comes out garbled and is alot of hassle converting.
What editor would you advise content staff to use that is web safe?
Regards
Aaron
I was wondering is it safe to do so?
wchar_t wide = /* something */;
assert(wide >= 0 && wide < 256 &&);
char myChar = static_cast<char>(wide);
If I am pretty sure the wide char will fall within ASCII range.
When building gtk2hs-buildtools with ghc 7.4.2, I get the following warning:
c2hs/toplevel/C2HSConfig.hs:110:1:
Warning: newtype `CInt' is used in an FFI declaration,
but its constructor is not in scope.
This will become an error in GHC 7.6.1.
When checking declaration:
foreign import ccall safe "static bitfield_direction" bitfield_direction
:: CInt
I get similar warnings with FFI calls, even though I have import Foreign.C.Types(CInt).
What is the correct way of getting rid of this warning?
Hello,
I am having issues correcting an encoding type issue on a site. Unfortunately the site is non work safe (gay porn).
For the brave: http://www.alphamalemedia.com/index/news
Ive tried setting the meta content from utf8 to iso-8859-1.
Ive switched tables over to utf8 from latin1_swedish_ci but no luck.
I'm doing a Pyjamas example and get this error:
TodoApp InternalError: too much recursion
Has anyone else encountered this?
Some articles around the web recommend adjusting the C++ code of your
browser to fix it, but that doesn't seem safe to me.
Does Asp.Net require ActiveX to make Ajax calls? I suspect it does because without setting "initialize and script activeX controls not marked as safe" in IE options ASP.NET UpdatePanels don't work. Am I correct?
I am currently html encoding all user entered text before inserting/updating a db table record. The problem is that on any subsequent updates, the previously encoded string is reencoded. This endless loop is starting to eat up alot of column space in my tables. I am using parameterized queries for all sql statements but am wondering would it be safe to just let the .NET Framework handle this part without the HTML Encoding?
I notice that the character/symbol '`' and '@' is not used as an operator in C/C++,
does anyone know the reason or historically why its so?
if its really not used, is it safe to define those symbols as another operator/statement using #define?
Is it safe to assume that
java.util.concurrent.CompletionService.take().isDone()
will always return true? If so, why does take() return a Future, rather than the value directly? If not, what does "completed task" as used in the documentation mean?
My Application Database Without Project and without Source safe, i planned to make my DB to be as project and add it to TFS, but I have no idea how to script the stored procedures, Triggers, Views, Functions, and what is the best practice to Make Update Script for All My stored procedures, Triggers, Views, and Functions to My customers DB.
Is it safe to store information such as usernames and passwords within comments in your source code? I am not worried about some getting access to my source but I am concerned in regards to someone decompiling my compiled silverlight XAP file. Is anybody 100% sure if the compiler strips off commented code. I would assume it does but I want to be sure.
Thanks!
I am trying to encode a string into a safe url for generic purposes, and neither rawurlencode() nor urlencode() work when using CodeIgniter. I have used them and they work pefectly fine with straight PHP, but for whatever reason, it doesn't work. I haven't been able to find any others with this problem and thus no solution.
Code:
<a href="/search/degree/<?=rawurlencode($row->degree)?>" class="element_link"><?=$row->degree?></a>
Hello. I have this :
std::map<int,int> mapy;
++mapy[5];
Is it safe to assume that mapy[5] will always be 1? I mean, will mapy[5] always get the default value of 0 before '++', even if not explicitly declared, as in my code?
Cheers
What is the best place in servlet for Hibernate code that returns HibernateSessionFactory ?
I saw many examples: ones put db connection in service methods. Others - use smth like HibernateUtil (Singleton) that returns HibernateSessionFactory.
I don't know is it safe to use HibernateUtil in multithreaded Servlets ?
What is the safest communication method between two applications on the same machine, both Java and C/C++ clients with a Java server.
Are SSL sockets safe enough or they can be broken by "man in the middle" attacks?
As i saw in the documentation and code samples, JSSE retrieves private/public keys and certificates from keystore files which a malicious user can see. The only thing that you can hide in the code is the password used to unlock the keystores.
Can hackers retrieve that password?
I have configured the wildcard DNS of *.mydomain.com and it's all working properly. My question is which of these should I rely on identifying client subdomain requests?
$_SERVER["HTTP_HOST"]
$_SERVER["SERVER_NAME"]
$_SERVER["SCRIPT_URI"]
They all seem to contain the subdomain part I want but after reading this article by Chris: http://shiflett.org/blog/2005/feb/more-on-filtering-input-and-escaping-output, I'm lost at see and there appears to be no safe way to do this?
Any idea on accomplishing this task securely?